intel/fs: Use shuffle_for_32bit_write for 16-bits store_ssbo
authorJose Maria Casanova Crespo <jmcasanova@igalia.com>
Sat, 9 Jun 2018 09:45:50 +0000 (11:45 +0200)
committerJose Maria Casanova Crespo <jmcasanova@igalia.com>
Sat, 16 Jun 2018 20:39:08 +0000 (22:39 +0200)
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/intel/compiler/brw_fs_nir.cpp

index 5cad31b32d9254dfc813c8aabc0117ae80a3de76..96ebb236a4022b5285ae176e53560dfe85d8363b 100644 (file)
@@ -4297,11 +4297,8 @@ fs_visitor::nir_emit_intrinsic(const fs_builder &bld, nir_intrinsic_instr *instr
              * aligned. Shuffling only one component would be the same as
              * striding it.
              */
-            fs_reg tmp = bld.vgrf(BRW_REGISTER_TYPE_D,
-                                  DIV_ROUND_UP(num_components, 2));
-            shuffle_16bit_data_for_32bit_write(bld, tmp, write_src,
-                                               num_components);
-            write_src = tmp;
+            write_src = shuffle_for_32bit_write(bld, write_src, 0,
+                                                num_components);
          }
 
          fs_reg offset_reg;