From 45b7f1701e4c4d0e3c5a2863fe90686daa6524ce Mon Sep 17 00:00:00 2001 From: Ilia Mirkin Date: Fri, 10 Jan 2014 22:17:04 -0500 Subject: [PATCH] nv50/ir: disallow shader input + cbuf in same instruction in gp Signed-off-by: Ilia Mirkin --- .../drivers/nouveau/codegen/nv50_ir_target_nv50.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp index c27d4532e5a..ecf5d1c70a2 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp @@ -300,11 +300,16 @@ TargetNV50::insnCanLoad(const Instruction *i, int s, case 0x01: case 0x03: case 0x08: - case 0x09: case 0x0c: case 0x20: case 0x21: break; + case 0x09: + // Shader inputs get transformed to p[] in geometry shaders, and those + // aren't allowed to be used at the same time as c[]. + if (ld->bb->getProgram()->getType() == Program::TYPE_GEOMETRY) + return false; + break; case 0x0d: if (ld->bb->getProgram()->getType() != Program::TYPE_GEOMETRY) return false; -- 2.30.2