[Mesa-dev] [PATCH 3/3] nir: Rewrite lower_regs_to_ssa to use the phi builder
Eric Anholt
eric at anholt.net
Thu Dec 15 23:07:59 UTC 2016
Jason Ekstrand <jason at jlekstrand.net> writes:
> This keeps some of Connor's original code. However, while I was at it,
> I updated this very old pass to a bit more modern NIR.
I love how much smaller this code is. Assuming that the phi builder
does that job correctly, this is pretty trivial to read and understand.
The only things I saw were:
- It doesn't call nir_metadata_preserve() like the old pass did, while
it adds new SSA values. Seems like it should.
- It asserts that reg->num_array_elems == 0, while the old pass would
just skip those. It looks like the only source of arrays would be
nir_lower_locals_to_regs(), which only i965 is calling. Is that
something we should be using? Should we be handling the array reg
case in this pass and in our drivers?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20161215/8e117269/attachment.sig>
More information about the mesa-dev
mailing list