Mesa (10.1): nvc0/ir/emit: hardcode vertex output stream to 0 for now

Ian Romanick idr at kemper.freedesktop.org
Sat Feb 8 01:10:20 UTC 2014


Module: Mesa
Branch: 10.1
Commit: 17aeb3fdc9e453f7994ea31f7715e069e169a819
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=17aeb3fdc9e453f7994ea31f7715e069e169a819

Author: Christoph Bumiller <e0425955 at student.tuwien.ac.at>
Date:   Fri Feb  7 22:39:44 2014 +0100

nvc0/ir/emit: hardcode vertex output stream to 0 for now
(cherry picked from commit b7233acf782a39c7e5643cb303022360664b6046)

---

 src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp |    9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp
index 96a4af4..f15ca1b 100644
--- a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp
+++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_nvc0.cpp
@@ -1488,8 +1488,13 @@ CodeEmitterNVC0::emitOUT(const Instruction *i)
 
    // vertex stream
    if (i->src(1).getFile() == FILE_IMMEDIATE) {
-      code[1] |= 0xc000;
-      code[0] |= SDATA(i->src(1)).u32 << 26;
+      // Using immediate encoding here triggers an invalid opcode error
+      // or random results when error reporting is disabled.
+      // TODO: figure this out when we get multiple vertex streams
+      assert(SDATA(i->src(1)).u32 == 0);
+      srcId(NULL, 26);
+      // code[1] |= 0xc000;
+      // code[0] |= SDATA(i->src(1)).u32 << 26;
    } else {
       srcId(i->src(1), 26);
    }




More information about the mesa-commit mailing list