[Mesa-dev] [PATCH 01/47] nir: rewrite nir_foreach_block and friends

Connor Abbott cwabbott0 at gmail.com
Wed Apr 13 19:07:04 UTC 2016


On Wed, Apr 13, 2016 at 11:15 AM, Jason Ekstrand <jason at jlekstrand.net> wrote:
>
> On Apr 13, 2016 4:57 AM, "Rob Clark" <robdclark at gmail.com> wrote:
>>
[...]
>>
>> so, I like the new iterator macros, but this is one giant massive
>> unbisectable flag-day change :-(
>>
>> I'd prefer an approach that kept the old fxns implemented in terms of
>> the new macros at the beginning of the patchset, then removed them
>> once everyone else was converted.  Which is slightly annoying since
>> you'd kinda want to use the same names.  But less of a pita wrt new
>> nir passes that haven't been pushed yet (I've got a bunch.. I'm not
>> sure if all of Jason's vulkan stuff has landed yet either)
>
> I think enough Vulkan stuff has landed to make this not terrible but you're
> right about the scope of things.  How about starting with a patch that
> renames nir_foreach_block to something else, say nir_foreach_block_call.
> Then patch 1 then a patch to implement nir_foreach_block_call in terms of
> the macro and then the switchover patches.  The rename will have to touch
> everything but it will be trivially correct. The rest can be incremental.
>
> That said, I'm still going to look through the patches to see what I think
> of the end result.
>

I think I like Jason's approach a little more. I'm concerned that if
we leave this hanging and don't do any of the flag-day renames until
all the in-flight patches have landed that use the old function, then
people will continue to write patches using the old function by
accident and we'll never actually do it. In other words, there has to
be some amount of pain in the immediate future. And after all, it's
not like it's a lot of work to rebase on top of this series anyways --
each patch of this series took me ~5 mins or less to write.


More information about the mesa-dev mailing list