Module: Mesa Branch: main Commit: 2692a5f8db6918c5084bd634aedd087723a66f14 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=2692a5f8db6918c5084bd634aedd087723a66f14
Author: Dave Airlie <[email protected]> Date: Wed Dec 15 10:22:50 2021 +1000 intel/compiler: don't lower swizzles in backend. These are lowered by crocus in the frontend, the key entries are still used. Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Lionel Landwerlin <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14202> --- src/intel/compiler/brw_nir.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/intel/compiler/brw_nir.c b/src/intel/compiler/brw_nir.c index ec0a6901d0d..89cadc242f5 100644 --- a/src/intel/compiler/brw_nir.c +++ b/src/intel/compiler/brw_nir.c @@ -1255,16 +1255,6 @@ brw_nir_apply_sampler_key(nir_shader *nir, tex_options.saturate_r = key_tex->gl_clamp_mask[2]; } - /* Prior to Haswell, we have to fake texture swizzle */ - for (unsigned s = 0; s < MAX_SAMPLERS; s++) { - if (key_tex->swizzles[s] == SWIZZLE_NOOP) - continue; - - tex_options.swizzle_result |= BITFIELD_BIT(s); - for (unsigned c = 0; c < 4; c++) - tex_options.swizzles[s][c] = GET_SWZ(key_tex->swizzles[s], c); - } - /* Prior to Haswell, we have to lower gradients on shadow samplers */ tex_options.lower_txd_shadow = devinfo->verx10 <= 70;
