mesa/src/panfrost
Alyssa Rosenzweig 2f2738dc90 pan/bi: Use nir_lower_mem_access_bit_sizes
OpenCL can generate large loads and stores that we can't support, so we need to
lower. We can load/store up to 128-bits in a single go. We currently only handle
up to 32-bit components in the load and no more than vec4, so we split up
accordingly.

It's not clear to me what the requirements are for alignment on Valhall, so we
conservatively generate aligned access, at worst there's a performance penalty
in those cases. I think unaligned access is suppoerted, but likely with a
performance penalty of its own? So in the absence of hard data otherwise, let's
just use natural alignment.

Oddly, this shaves off a tiny bit of ALU in a few compute shaders on Valhall,
all in gfxbench. Seems to just be noise from the RA lottery.

total instructions in shared programs: 2686768 -> 2686756 (<.01%)
instructions in affected programs: 584 -> 572 (-2.05%)
helped: 6
HURT: 0
Instructions are helped.

total cvt in shared programs: 14644.33 -> 14644.14 (<.01%)
cvt in affected programs: 5.77 -> 5.58 (-3.25%)
helped: 6
HURT: 0

total quadwords in shared programs: 1455320 -> 1455312 (<.01%)
quadwords in affected programs: 56 -> 48 (-14.29%)
helped: 1
HURT: 0

Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22228>
2023-04-13 01:49:33 +00:00
..
ci Uprev Piglit to 2391a83d1639a7ab7bbea02853b922878687b0e5 2023-04-04 15:37:14 +00:00
compiler pan/bi: Use nir_lower_mem_access_bit_sizes 2023-04-13 01:49:33 +00:00
drm-shim panfrost: clang-format the tree 2022-12-24 02:22:57 +00:00
ds panfrost: clang-format the tree 2022-12-24 02:22:57 +00:00
include panfrost: Re-run clang-format 2023-04-10 21:56:04 +00:00
lib panfrost: Re-run clang-format 2023-04-10 21:56:04 +00:00
midgard nir: Combine if_uses with instruction uses 2023-04-07 23:48:03 +00:00
perf panfrost: clang-format the tree 2022-12-24 02:22:57 +00:00
shared meson: inline gtest_test_protocol now that it's always 'gtest' 2023-03-10 07:20:29 +00:00
tools panfrost: clang-format the tree 2022-12-24 02:22:57 +00:00
util nir: Combine if_uses with instruction uses 2023-04-07 23:48:03 +00:00
vulkan panvk: Clang-format 2023-04-10 21:56:04 +00:00
.clang-format nir: Combine if_uses with instruction uses 2023-04-07 23:48:03 +00:00
meson.build panfrost: drop no-longer-needed libglsl 2023-02-10 14:09:37 +00:00