summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Turner <mattst88@gmail.com>2016-03-31 11:36:07 -0700
committerMatt Turner <mattst88@gmail.com>2016-08-01 12:15:34 -0700
commit52d45260592c33b51431e1eeddd28a4255cf4164 (patch)
tree0f2eada9105889d04e12453f7ba1e8ca1cc1a4cb
parent88ad8c7dedb87d92a5bed0868f108076185ec089 (diff)
-rw-r--r--src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp b/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp
index 8afdc25c2c59..cc42a3346bac 100644
--- a/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp
+++ b/src/mesa/drivers/dri/i965/brw_schedule_instructions.cpp
@@ -1657,10 +1657,28 @@ fs_visitor::schedule_instructions(instruction_scheduler_mode mode)
else
grf_count = alloc.count;
+ bblock_t *block = cfg->blocks[cfg->num_blocks - 1];
+ fs_inst *fb_write = (fs_inst *)block->end();
+ bool last_was_fb_write = false;
+ if (fb_write->opcode == FS_OPCODE_FB_WRITE) {
+ last_was_fb_write = true;
+
+ assert(fb_write->eot);
+ fb_write->eot = false;
+ }
+
fs_instruction_scheduler sched(this, grf_count, first_non_payload_grf,
cfg->num_blocks, mode);
sched.run(cfg);
+ fb_write = (fs_inst *)block->end();
+ if (last_was_fb_write) {
+ assert(fb_write->opcode == FS_OPCODE_FB_WRITE);
+ fb_write->eot = true;
+ } else {
+ assert(fb_write->opcode != FS_OPCODE_FB_WRITE);
+ }
+
invalidate_live_intervals();
}