vc4: Fix register pressure cost estimates when a src appears twice.
authorEric Anholt <eric@anholt.net>
Sat, 4 Mar 2017 01:03:44 +0000 (17:03 -0800)
committerEric Anholt <eric@anholt.net>
Wed, 8 Mar 2017 21:44:17 +0000 (13:44 -0800)
commit615f6653b02829187bb8ddb38b12c34cb2976ef3
tree5d5656171803a3f06052db59daaaf64ff94b4867
parent0fca01d0279c5794ae2aceee27668c974b586f87
vc4: Fix register pressure cost estimates when a src appears twice.

This ended up confusing the scheduler for things like fabs (implemented as
fmaxabs x, x) or squaring a number, and it would try to avoid scheduling
them because it appeared more expensive than other instructions.

Fixes failure to register allocate in
dEQP-GLES2.functional.uniform_api.random.3 with almost no shader-db
effects (+.35% max temps)
src/gallium/drivers/vc4/vc4_qir_schedule.c