summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Ekstrand <jason@jlekstrand.net>2020-10-28 16:28:46 -0500
committerMarge Bot <eric+marge@anholt.net>2021-02-17 03:59:25 +0000
commit3ce6ca7214d022d04414dd9618d2c8146dc1da4f (patch)
treeb10376456d9678b6fd3762bca50c62e7c3c4cbd3
parent12fa219768c56cf7744a1adc3d9f63e3e686176a (diff)
intel/fs: Shuffle can't handle source modifiers
On Gen7, we have to split shuffles into two MOVs for 64-bit types so we can't handle source modifiers. On Gen12.5, we have to use integer types all the time so we can't use them there either. Fixing that will be a different commit but it interacts with this one. Fixes: 90c9f29518d "i965/fs: Add support for nir_intrinsic_shuffle" Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9068>
-rw-r--r--src/intel/compiler/brw_fs_generator.cpp3
-rw-r--r--src/intel/compiler/brw_shader.cpp1
2 files changed, 4 insertions, 0 deletions
diff --git a/src/intel/compiler/brw_fs_generator.cpp b/src/intel/compiler/brw_fs_generator.cpp
index 0a9bd482427..8f5052be01c 100644
--- a/src/intel/compiler/brw_fs_generator.cpp
+++ b/src/intel/compiler/brw_fs_generator.cpp
@@ -600,6 +600,9 @@ fs_generator::generate_shuffle(fs_inst *inst,
struct brw_reg src,
struct brw_reg idx)
{
+ assert(src.file == BRW_GENERAL_REGISTER_FILE);
+ assert(!src.abs && !src.negate);
+
/* Ivy bridge has some strange behavior that makes this a real pain to
* implement for 64-bit values so we just don't bother.
*/
diff --git a/src/intel/compiler/brw_shader.cpp b/src/intel/compiler/brw_shader.cpp
index a50559a245d..f52295fa310 100644
--- a/src/intel/compiler/brw_shader.cpp
+++ b/src/intel/compiler/brw_shader.cpp
@@ -949,6 +949,7 @@ backend_instruction::can_do_source_mods() const
case SHADER_OPCODE_BROADCAST:
case SHADER_OPCODE_CLUSTER_BROADCAST:
case SHADER_OPCODE_MOV_INDIRECT:
+ case SHADER_OPCODE_SHUFFLE:
return false;
default:
return true;