st/mesa: remove the switch from st_validate_state by passing state mask directly
authorMarek Olšák <marek.olsak@amd.com>
Mon, 21 Nov 2022 12:47:59 +0000 (07:47 -0500)
committerMarge Bot <emma+marge@anholt.net>
Mon, 12 Dec 2022 19:15:34 +0000 (19:15 +0000)
commiteb97f624c73200a7fd844ce765fb74b5ad6da173
treeb40259e265b8f311d0388067c806c9956ff6a8e3
parentae8147dd5a99b16d8bad4b724c0da357d9d09b5f
st/mesa: remove the switch from st_validate_state by passing state mask directly

Instead of passing the enum that represents which states should be updated
to st_validate_state, pass the state bitmask to st_validate_state directly.
This removes the switch statement over the enums.

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19953>
14 files changed:
src/mesa/main/buffers.c
src/mesa/main/compute.c
src/mesa/main/fbobject.c
src/mesa/main/multisample.c
src/mesa/state_tracker/st_atom.c
src/mesa/state_tracker/st_atom.h
src/mesa/state_tracker/st_cb_bitmap.c
src/mesa/state_tracker/st_cb_clear.c
src/mesa/state_tracker/st_cb_drawpixels.c
src/mesa/state_tracker/st_cb_drawtex.c
src/mesa/state_tracker/st_cb_rasterpos.c
src/mesa/state_tracker/st_cb_readpixels.c
src/mesa/state_tracker/st_draw.c
src/mesa/state_tracker/st_draw_feedback.c