From 63d2aa4eb645e32ea3d5aea453a45aa6a3412e15 Mon Sep 17 00:00:00 2001 From: Kenneth Graunke Date: Tue, 27 Feb 2024 02:02:24 -0800 Subject: [PATCH] intel/brw: Mark FIND[_LAST]_LIVE_CHANNEL as not writing the flag brw_lower_find_live_channel doesn't actually write a flag register, but elk_find_live_channel notes that the flag was used on Gfx7. This allows more CSE on FIND[_LAST]_LIVE_CHANNEL. shader-db and fossil-db on Alchemist show minor reductions in cycles and instruction count, a few minor increases, but it doesn't seem to be a large effect in either direction. Reviewed-by: Ian Romanick Part-of: --- src/intel/compiler/brw_fs.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/intel/compiler/brw_fs.cpp b/src/intel/compiler/brw_fs.cpp index fe59c246954..23fe5ffcfe2 100644 --- a/src/intel/compiler/brw_fs.cpp +++ b/src/intel/compiler/brw_fs.cpp @@ -994,9 +994,7 @@ fs_inst::flags_written(const intel_device_info *devinfo) const opcode != BRW_OPCODE_IF && opcode != BRW_OPCODE_WHILE)) { return brw_fs_flag_mask(this, 1); - } else if (opcode == SHADER_OPCODE_FIND_LIVE_CHANNEL || - opcode == SHADER_OPCODE_FIND_LAST_LIVE_CHANNEL || - opcode == FS_OPCODE_LOAD_LIVE_CHANNELS) { + } else if (opcode == FS_OPCODE_LOAD_LIVE_CHANNELS) { return brw_fs_flag_mask(this, 32); } else { return brw_fs_flag_mask(dst, size_written);