mesa/st: add special casing for pointsize constant updating during validate
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Fri, 25 Mar 2022 01:45:32 +0000 (21:45 -0400)
committerMarge Bot <emma+marge@anholt.net>
Fri, 25 Mar 2022 04:03:23 +0000 (04:03 +0000)
commiteaf3c72a8371a0a83261b1b1e1b0d68147314a99
tree51eb247e888d34db009a530cb5feb1da04b71879
parent6fb0bf51a30ca1cfffb389258b68eb322a620015
mesa/st: add special casing for pointsize constant updating during validate

the previous method of using affected_states to trigger constant updates
was ineffectual in the scenario where a ubo pointsize was needed on
the first time a non-precompiled shader was used after being the not-last
vertex stage:

* have vs+gs -> gs precompiles with pointsize lowering -> gs constants get updated
* remove gs -> vs was precompiled without pointsize lowering -> vs constants broken

now just do a quick check as in st_atom_shader.c and set the flag manually to
ensure the update is done correctly every time

cc: mesa-stable

fixes #6207

fixes (radv):
KHR-GL46.texture_cube_map_array.image_op_fragment_sh
KHR-GL46.texture_cube_map_array.sampling
KHR-GL46.texture_cube_map_array.texture_size_fragment_sh
KHR-GL46.constant_expressions*

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15570>
src/gallium/drivers/zink/ci/zink-radv-fails.txt
src/mesa/state_tracker/st_atom.c
src/mesa/state_tracker/st_program.c