Commit 7ad6df1a authored by Alyssa Rosenzweig's avatar Alyssa Rosenzweig 💜

Set sources

parent 5cd3365d
......@@ -133,6 +133,22 @@ emit_load_const(compiler_context *ctx, nir_load_const_instr *instr)
ins.vector_alu.dest_override = midgard_dest_override_none;
ins.vector_alu.outmod = midgard_outmod_none;
ins.vector_alu.mask = 0xFF;
midgard_vector_alu_src_t src;
src.abs = 0;
src.negate = 0;
src.rep_low = 0;
src.rep_high = 0;
src.half = 0;
src.swizzle = SWIZZLE(COMPONENT_X, COMPONENT_Y, COMPONENT_Z, COMPONENT_W);
unsigned src1;
memcpy(&src1, &src, sizeof(src));
ins.vector_alu.src1 = src1;
ins.vector_alu.src2 = src1;
util_dynarray_append(&ctx->current_block, midgard_instruction, ins);
} else {
printf("Unknown configuration in load_const %d x %d\n", def.num_components, def.bit_size);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment