aco/isel: Fix out-of-bounds write in visit_load_input
authorTony Wasserka <tony.wasserka@gmx.de>
Mon, 14 Sep 2020 17:39:43 +0000 (19:39 +0200)
committerMarge Bot <eric+marge@anholt.net>
Wed, 7 Oct 2020 19:50:01 +0000 (19:50 +0000)
commit5f7810dcb2b1eed0a1920e5f3a0339a09031a895
tree4a636bf2cfbd667d5214b958c073e7b300a8e980
parentd38094bb33bab1804919cac5a8ed97da7925e9df
aco/isel: Fix out-of-bounds write in visit_load_input

Shaders may read out components past the attributes provided by the
application, so the read mask can indicate a larger component count than
were actually reserved in the array.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6728>
src/amd/compiler/aco_instruction_selection.cpp