spirv: replace discard with demote for incorrect HLSL->SPIR-V translations
authorRhys Perry <pendingchaos02@gmail.com>
Wed, 7 Oct 2020 19:07:42 +0000 (20:07 +0100)
committerMarge Bot <eric+marge@anholt.net>
Mon, 12 Oct 2020 11:07:38 +0000 (11:07 +0000)
commit037d9fb278c44bf5bd8fea6c6c78af321555d141
tree51092305d57364504d225548e77ce189a3b1358b
parent18f9fc919e1b5e7511cc3085dd990b7ca037f38e
spirv: replace discard with demote for incorrect HLSL->SPIR-V translations

Fixes artifacts on decals in Path of Exile.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3610
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7062>
src/compiler/spirv/spirv_to_nir.c
src/compiler/spirv/vtn_cfg.c
src/compiler/spirv/vtn_private.h