summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJason Ekstrand <jason.ekstrand@intel.com>2016-04-18 18:52:36 -0700
committerJason Ekstrand <jason.ekstrand@intel.com>2016-04-20 09:15:01 -0700
commitb3f43822c72301c904fd2824ae3edcd20ea93a29 (patch)
tree4a8c5372a3f19cd2b41bd910b555db3465acfa11 /src
parent9f16e170fed09821bb1b18a9dbe548f3d26b7977 (diff)
downloadexternal_mesa3d-b3f43822c72301c904fd2824ae3edcd20ea93a29.zip
external_mesa3d-b3f43822c72301c904fd2824ae3edcd20ea93a29.tar.gz
external_mesa3d-b3f43822c72301c904fd2824ae3edcd20ea93a29.tar.bz2
i965/vec4: Use the correct offset for the swizzle shift in push constants
This was actually caught by Ken in review the first time around but somehow didn't get fixed before the patches were pushed. :-( Reviewed-by: Iago Toral Quiroga <itoral@igalia.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94998 Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=95001
Diffstat (limited to 'src')
-rw-r--r--src/mesa/drivers/dri/i965/brw_vec4_nir.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp
index b5c23c9..aa3965a 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp
@@ -712,7 +712,7 @@ vec4_visitor::nir_emit_intrinsic(nir_intrinsic_instr *instr)
unsigned offset = const_offset->u32[0] + shift * 4;
src.reg_offset = offset / 16;
- shift = (nir_intrinsic_base(instr) % 16) / 4;
+ shift = (offset % 16) / 4;
src.swizzle += BRW_SWIZZLE4(shift, shift, shift, shift);
emit(MOV(dest, src));