ir3: Use stp/ldp base offset for {load,store}_scratch
authorConnor Abbott <cwabbott0@gmail.com>
Mon, 11 Oct 2021 14:43:10 +0000 (16:43 +0200)
committerMarge Bot <eric+marge@anholt.net>
Wed, 20 Oct 2021 15:19:15 +0000 (15:19 +0000)
commite7599f09a149347b74bf0913cdd86d64e0ae9d20
tree404d809074e500cfde664ca5eb1899a56ad7cdf5
parent7deb0d296d83286b1f83dd0baeb4e355e717a615
ir3: Use stp/ldp base offset for {load,store}_scratch

When we have a series of loads/stores we were creating a constant for
each one, which isn't great. Furthermore, because the nir pass puts the
offset constant at the top of the shader, it resulted in extra register
pressure and spilling when that happened inside a loop. Fix this by
using the base/offset form of stp and ldp.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13307>
src/freedreno/ci/deqp-freedreno-a630-skips.txt
src/freedreno/ir3/ir3_compiler_nir.c