summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_defines.h
diff options
context:
space:
mode:
authorFrancisco Jerez <currojerez@riseup.net>2015-04-23 14:42:53 +0300
committerFrancisco Jerez <currojerez@riseup.net>2015-05-04 17:44:17 +0300
commit715bc6d8b16a0bbdc17fe1e1e46b88a679bf312b (patch)
tree442dd3d1523c4eb84b1e01e89b1e43aab3f5789d /src/mesa/drivers/dri/i965/brw_defines.h
parentf2fad0dc80627e853eea558498f18a9fa769992e (diff)
downloadexternal_mesa3d-715bc6d8b16a0bbdc17fe1e1e46b88a679bf312b.zip
external_mesa3d-715bc6d8b16a0bbdc17fe1e1e46b88a679bf312b.tar.gz
external_mesa3d-715bc6d8b16a0bbdc17fe1e1e46b88a679bf312b.tar.bz2
i965: Introduce the FIND_LIVE_CHANNEL pseudo-opcode.
This instruction calculates the index of an arbitrary channel enabled in the current execution mask. It's expected to be used as input for the BROADCAST opcode, but it's implemented as a separate instruction rather than being baked into BROADCAST because FIND_LIVE_CHANNEL has no dependencies so it can always be CSE'ed with other instances of the same instruction within a basic block. v2: Whitespace fixes. Reviewed-by: Matt Turner <mattst88@gmail.com>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_defines.h')
-rw-r--r--src/mesa/drivers/dri/i965/brw_defines.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h
index 5072e68..7b5dd45 100644
--- a/src/mesa/drivers/dri/i965/brw_defines.h
+++ b/src/mesa/drivers/dri/i965/brw_defines.h
@@ -919,6 +919,14 @@ enum opcode {
SHADER_OPCODE_URB_WRITE_SIMD8,
/**
+ * Return the index of an arbitrary live channel (i.e. one of the channels
+ * enabled in the current execution mask) and assign it to the first
+ * component of the destination. Expected to be used as input for the
+ * BROADCAST pseudo-opcode.
+ */
+ SHADER_OPCODE_FIND_LIVE_CHANNEL,
+
+ /**
* Pick the channel from its first source register given by the index
* specified as second source. Useful for variable indexing of surfaces.
*/