i965/fs: Fix Broadwell texture header setup to be uncompressed.
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 23 Jan 2014 18:55:16 +0000 (10:55 -0800)
committerKenneth Graunke <kenneth@whitecape.org>
Tue, 11 Feb 2014 23:21:10 +0000 (15:21 -0800)
MOV_RAW disables masking, but doesn't force the instruction to be
uncompressed.  That needs to be done by hand.

Fixes textureGather and texture offset tests.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
src/mesa/drivers/dri/i965/gen8_fs_generator.cpp

index e0b52126705cdcad30bcad9acc6533329fe56d02..f9026912b1f737ffbbf2ac48bd5a4bb05c02d744 100644 (file)
@@ -241,6 +241,9 @@ gen8_fs_generator::generate_tex(fs_inst *ir,
       if (dispatch_width == 16)
          src.nr++;
 
+      unsigned save_exec_size = default_state.exec_size;
+      default_state.exec_size = BRW_EXECUTE_8;
+
       MOV_RAW(src, brw_vec8_grf(0, 0));
 
       if (ir->texture_offset) {
@@ -248,6 +251,8 @@ gen8_fs_generator::generate_tex(fs_inst *ir,
          MOV_RAW(retype(brw_vec1_grf(src.nr, 2), BRW_REGISTER_TYPE_UD),
                  brw_imm_ud(ir->texture_offset));
       }
+
+      default_state.exec_size = save_exec_size;
    }
 
    uint32_t surf_index =