nvc0: remove bad assert and emit TEMP movs instead
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sat, 22 Jan 2011 12:59:47 +0000 (13:59 +0100)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sun, 23 Jan 2011 12:07:30 +0000 (13:07 +0100)
src/gallium/drivers/nvc0/nvc0_tgsi_to_nc.c

index 3709369ca2fdfa51216e10cfe7f64f3090f77c6e..be1bb44931d131ff0f561f90c5cdf804b530fa78 100644 (file)
@@ -878,11 +878,10 @@ emit_store(struct bld_context *bld, const struct tgsi_full_instruction *inst,
       break;
    case TGSI_FILE_TEMPORARY:
       assert(idx < BLD_MAX_TEMPS);
-      if (!res->insn)
+      if (!res->insn || res->insn->bb != bld->pc->current_block)
          res = bld_insn_1(bld, NV_OP_MOV, res);
 
       assert(res->reg.file == NV_FILE_GPR);
-      assert(res->insn->bb = bld->pc->current_block);
 
       if (bld->ti->require_stores)
          bld_lmem_store(bld, ptr, idx * 4 + chan, res);