nvc0/ir: insn can never be null
authorIlia Mirkin <imirkin@alum.mit.edu>
Sat, 6 Sep 2014 15:30:57 +0000 (11:30 -0400)
committerIlia Mirkin <imirkin@alum.mit.edu>
Tue, 9 Sep 2014 00:06:11 +0000 (20:06 -0400)
Reported by Coverity.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
src/gallium/drivers/nouveau/codegen/nv50_ir_lowering_nvc0.cpp

index b3e1e69b016bfc18f5cbd75e1a750ee67f2d524c..f13bab1735fbc05d5ae7b1499df907ad7f26b624 100644 (file)
@@ -150,7 +150,7 @@ NVC0LegalizePostRA::findOverwritingDefs(const Instruction *texi,
    while (insn->op == OP_MOV && insn->getDef(0)->equals(insn->getSrc(0)))
       insn = insn->getSrc(0)->getUniqueInsn();
 
-   if (!insn || !insn->bb->reachableBy(texi->bb, term))
+   if (!insn->bb->reachableBy(texi->bb, term))
       return;
 
    switch (insn->op) {