OSDN Git Service

nv50/ir: make use of auxCBSlot instead of magic numbers
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Tue, 15 Mar 2016 12:06:44 +0000 (13:06 +0100)
committerSamuel Pitoiset <samuel.pitoiset@gmail.com>
Sat, 19 Mar 2016 17:01:04 +0000 (18:01 +0100)
commit26cc411db87f924003f227874d7a047dd8b5e5a4
tree33a9ced3ff82adf96bbabfcbd0b1cba1c1063384
parentd86933e6f42b9c2f5bb617c66c91795c560a9abd
nv50/ir: make use of auxCBSlot instead of magic numbers

This avoids using magic numbers for the driver constbuf slot which
is always 15 except for compute shaders on gk104+ where the slot 0
is used.

For gk104+, some special compute-related values like the thread
index are uploaded to screen->parm which is currently bound on c0.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
Acked-by: Pierre Moreau <pierre.morrow@free.fr>
src/gallium/drivers/nouveau/codegen/nv50_ir_from_tgsi.cpp
src/gallium/drivers/nouveau/codegen/nv50_ir_lowering_nvc0.cpp