glsl_to_tgsi: v2 Invalidate and revalidate uniform backing storage
authorVadim Girlin <vadimgirlin@gmail.com>
Thu, 22 Dec 2011 14:35:35 +0000 (18:35 +0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 3 Jan 2012 14:28:58 +0000 (09:28 -0500)
commitd4bf5cefb0943a196c603360187493e270a66442
treef41f391e5663b1cf44ca76d11b17bef764fa03f6
parentf433fe015e903424d25673ebfe5dcb115381d753
glsl_to_tgsi: v2 Invalidate and revalidate uniform backing storage

If glUniform1i and friends are going to dump data directly in
driver-allocated, the pointers have to be updated when the storage
moves.  This should fix the regressions seen with commit 7199096.

I'm not sure if this is the only place that needs this treatment.  I'm
a little uncertain about the various functions in st_glsl_to_tgsi that
modify the TGSI IR and try to propagate changes about that up to the
gl_program.  That seems sketchy to me.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
v2:

Revalidate when shader_program is not NULL.
Update the pointers for all _LinkedShaders.
Init glsl_to_tgsi_visitor::shader_program to NULL in the
get_pixel_transfer_visitor & get_bitmap_visitor.

Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com>
src/mesa/state_tracker/st_glsl_to_tgsi.cpp