From 8865fe309da2597398071f5171808c27aac787b4 Mon Sep 17 00:00:00 2001 From: Francisco Jerez Date: Thu, 26 Feb 2015 17:41:46 +0200 Subject: i965: Don't request untyped atomic writeback message if the destination is null. Reviewed-by: Topi Pohjolainen Acked-by: Kenneth Graunke --- src/mesa/drivers/dri/i965/brw_fs_generator.cpp | 2 +- src/mesa/drivers/dri/i965/brw_vec4_generator.cpp | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp index ff7e85fbb71..5b6633a7fa1 100644 --- a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp +++ b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp @@ -2018,7 +2018,7 @@ fs_generator::generate_code(const cfg_t *cfg, int dispatch_width) assert(src[1].file == BRW_IMMEDIATE_VALUE && src[2].file == BRW_IMMEDIATE_VALUE); brw_untyped_atomic(p, dst, src[0], src[2], src[1].dw1.ud, - inst->mlen, true); + inst->mlen, !inst->dst.is_null()); brw_mark_surface_used(prog_data, src[2].dw1.ud); break; diff --git a/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp b/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp index de7e06c7617..b847254f3dc 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp @@ -1472,7 +1472,8 @@ vec4_generator::generate_code(const cfg_t *cfg) assert(src[0].file == BRW_IMMEDIATE_VALUE && src[1].file == BRW_IMMEDIATE_VALUE); brw_untyped_atomic(p, dst, brw_message_reg(inst->base_mrf), - src[1], src[0].dw1.ud, inst->mlen, true); + src[1], src[0].dw1.ud, inst->mlen, + !inst->dst.is_null()); brw_mark_surface_used(&prog_data->base, src[1].dw1.ud); break; -- cgit v1.2.3