st/glsl_to_tgsi: simplify translate_tex_offset
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Sun, 9 Oct 2016 20:28:30 +0000 (22:28 +0200)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Thu, 13 Oct 2016 13:41:11 +0000 (15:41 +0200)
commitb234e377650c8280d56060ff38c55af9d7772ee4
tree91218a72d00b2c0ca0b0f3ec3f88b408ea70f88e
parent76a940893de634a50b9149a5f3f37c33fbf4f484
st/glsl_to_tgsi: simplify translate_tex_offset

This fixes a bug with offsets from uniforms which seems to have only been
noticed as a crash in piglit's
arb_gpu_shader5/compiler/builtin-functions/fs-gatherOffset-uniform-offset.frag
on radeonsi.

Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
src/mesa/state_tracker/st_glsl_to_tgsi.cpp