*/
struct hash_table *addr_ht;
+ /* last dst array, for indirect we need to insert a var-store.
+ */
+ struct ir3_instruction **last_dst;
+
/* maps nir_block to ir3_block, mostly for the purposes of
* figuring out the blocks successors
*/
struct ir3_instruction **value =
ralloc_array(ctx->def_ht, struct ir3_instruction *, n);
_mesa_hash_table_insert(ctx->def_ht, key, value);
+ compile_assert(ctx, !ctx->last_dst);
+ ctx->last_dst = value;
return value;
}
}
}
+static void
+put_dst(struct ir3_compile *ctx, nir_dest *dst)
+{
+ ctx->last_dst = NULL;
+}
+
static struct ir3_instruction **
get_dst_ssa(struct ir3_compile *ctx, nir_ssa_def *dst, unsigned n)
{
dst[i] = ir3_MOV(b, src[i], TYPE_U32);
}
+ put_dst(ctx, &alu->dest.dest);
return;
}
nir_op_infos[alu->op].name);
break;
}
+
+ put_dst(ctx, &alu->dest.dest);
}
/* handles direct/indirect UBO reads: */
nir_intrinsic_infos[intr->intrinsic].name);
break;
}
+
+ if (info->has_dest)
+ put_dst(ctx, &intr->dest);
}
static void
factor, 0);
}
}
+
+ put_dst(ctx, &tex->dest);
}
static void
*/
if (ctx->levels_add_one)
dst[0] = ir3_ADD_U(b, dst[0], 0, create_immed(b, 1), 0);
+
+ put_dst(ctx, &tex->dest);
}
static void
phi->phi.nphi = nphi;
dst[0] = phi;
+
+ put_dst(ctx, &nphi->dest);
}
/* phi instructions are left partially constructed. We don't resolve