nv50/ir: Fix up insertion of PHI instructions using bb->insertHead().
authorFrancisco Jerez <currojerez@riseup.net>
Tue, 15 Nov 2011 14:58:04 +0000 (15:58 +0100)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sat, 14 Apr 2012 19:54:00 +0000 (21:54 +0200)
src/gallium/drivers/nv50/codegen/nv50_ir_bb.cpp

index fb41888..aafc7cb 100644 (file)
@@ -91,7 +91,7 @@ BasicBlock::insertHead(Instruction *inst)
          insertBefore(phi, inst);
       } else {
          if (entry) {
-            insertBefore(entry, phi);
+            insertBefore(entry, inst);
          } else {
             assert(!exit);
             phi = exit = inst;