radeonsi: add workaround for issue 2647
authorPierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Fri, 24 Apr 2020 09:58:12 +0000 (11:58 +0200)
committerMarge Bot <eric+marge@anholt.net>
Tue, 5 May 2020 09:41:14 +0000 (09:41 +0000)
commit64662dd5baeec19a618156b52df7a7e7adba94cf
tree0b5a37062667688298a5dbe0032b4f43a05a586e
parent7983d97174de10670fce5a422ce6c1cb5e783b88
radeonsi: add workaround for issue 2647

For unknown reasons pixel shaders in KSP game get executed with
infinite interpolation coefficients and this causes an infinite
loop in the shader.

This commit adds a hacky workaround that kills pixel shaders if
invalid interp coeffs are detected and enables it for KSP.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2174
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2647
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4700>
src/amd/llvm/ac_nir_to_llvm.c
src/amd/llvm/ac_shader_abi.h
src/gallium/drivers/radeonsi/si_debug_options.h
src/gallium/drivers/radeonsi/si_pipe.c
src/gallium/drivers/radeonsi/si_pipe.h
src/gallium/drivers/radeonsi/si_shader_llvm.c
src/util/00-mesa-defaults.conf