vc4: Stop trying to reuse temporaries that store uniform values.
authorEric Anholt <eric@anholt.net>
Mon, 29 Sep 2014 16:39:46 +0000 (09:39 -0700)
committerEric Anholt <eric@anholt.net>
Mon, 29 Sep 2014 17:07:24 +0000 (10:07 -0700)
commit7a85ebf6e211423c98bb045ad21026c5ffeaa9bb
tree5fec8f15cf8446ab6a98833e9d185c9e3c25670b
parent3386e95994ec77248f71dedf49f996e2078f8cea
vc4: Stop trying to reuse temporaries that store uniform values.

Almost always, the MOV will get copy propagated out.  Even if it doesn't,
it's probably better to just reload the uniform at next use (to reduce
register pressure) rather than try to save instruction count.

I was looking at this because in the presence of texturing (which calls
add_uniform() directly to get the uniform load forced into the
instruction) the c->uniform_contents indices don't match 1:1 with the
temporary qregs.
src/gallium/drivers/vc4/vc4_program.c
src/gallium/drivers/vc4/vc4_qir.h