aco: disallow SMEM offsets that are not multiples of 4
authorRhys Perry <pendingchaos02@gmail.com>
Tue, 30 Nov 2021 15:45:12 +0000 (15:45 +0000)
committerMarge Bot <emma+marge@anholt.net>
Fri, 17 Dec 2021 22:14:36 +0000 (22:14 +0000)
commitcf5fc4b973cd9193f3a1fcb684c75a0e15c2b25c
tree6e7fac0f8e42a67d0226e160e4c00f8202911876
parent860532c5a16e912b66537d911f60b61439630937
aco: disallow SMEM offsets that are not multiples of 4

These can't be encoded on GFX6/7, and combining these additions causes
CTS failures on GFX10.3.

I think the low 2 MSBs are ignored before the addition, not after, so
load(a + 3, 0) becomes load(a, 3), which is the same as load(a, 0).

No fossil-db changes.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13755>
src/amd/compiler/aco_optimizer.cpp