radeonsi: fix compilation of monolithic PS
authorMarek Olšák <marek.olsak@amd.com>
Wed, 6 May 2020 13:42:55 +0000 (09:42 -0400)
committerMarge Bot <eric+marge@anholt.net>
Wed, 6 May 2020 17:02:23 +0000 (17:02 +0000)
commit29da52128090a1ef8ef782188c0f67c7f5ec8d19
tree98d3ff7de689eb905fa48877c1e6f26bd0d0f2f3
parentd5109741f372173d6e13bdb6fff06c75def19439
radeonsi: fix compilation of monolithic PS

This was totally broken. Monolithic PS is only used if FBFETCH or
interpolateAtSample are used.

When the PS prolog was built, it overwrote ctx->main_fn.

Discovered by @eefano.

Fixes: 8832a884345686e6a8b2c0c8aa7515ad3f775b9e "radeonsi: move PS LLVM code into si_shader_llvm_ps.c"
Closes: #2814
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4918>
src/gallium/drivers/radeonsi/si_shader_llvm_ps.c