brw_dump_compile(&func, stderr, 0, func.next_insn_offset);
fprintf(stderr, "\n");
}
+
+ brw_compact_instructions(&func);
return brw_get_program(&func, program_size);
}
const unsigned *brw_get_program( struct brw_compile *p,
unsigned *sz )
{
- brw_compact_instructions(p);
-
*sz = p->next_insn_offset;
return (const unsigned *)p->store;
}
if (simd8_instructions) {
dispatch_width = 8;
generate_code(simd8_instructions, dump_file);
+ brw_compact_instructions(p);
}
if (simd16_instructions) {
- /* We have to do a compaction pass now, or the one at the end of
- * execution will squash down where our prog_offset start needs
- * to be.
- */
- brw_compact_instructions(p);
-
/* align to 64 byte boundary. */
while ((p->nr_insn * sizeof(struct brw_instruction)) % 64) {
brw_NOP(p);
dispatch_width = 16;
generate_code(simd16_instructions, dump_file);
+ brw_compact_instructions(p);
}
return brw_get_program(p, assembly_size);
{
brw_set_access_mode(p, BRW_ALIGN_16);
generate_code(instructions);
+ brw_compact_instructions(p);
return brw_get_program(p, assembly_size);
}