[Mesa-dev] [PATCH] gm107/ir: add a missing assertion in emitISCADD()

Samuel Pitoiset samuel.pitoiset at gmail.com
Sat Apr 29 15:40:26 UTC 2017


For consistency, similar to the other emitters.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
---
 src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp
index 8b58df49c2..b1e9f941fe 100644
--- a/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp
+++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_emit_gm107.cpp
@@ -1858,6 +1858,8 @@ CodeEmitterGM107::emitIMAD()
 void
 CodeEmitterGM107::emitISCADD()
 {
+   assert(insn->src(1).get()->asImm());
+
    switch (insn->src(2).getFile()) {
    case FILE_GPR:
       emitInsn(0x5c180000);
-- 
2.12.2



More information about the mesa-dev mailing list