Samuel Pitoiset
255e76b419
ac,radv,radeonsi: add a function to translate tex numformat
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29265 >
2024-05-20 13:41:02 +00:00
Samuel Pitoiset
6030c876d0
radv: use PIPE_FORMAT in radv_translate_tex_numformat()
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29265 >
2024-05-20 13:41:02 +00:00
Samuel Pitoiset
2fef95f901
radv: stop checking the output value of radv_translate_tex_numformat
...
This function just never returns ~0.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29265 >
2024-05-20 13:41:02 +00:00
Rhys Perry
418fed1805
aco: update VS prolog waitcnt for GFX12
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29225 >
2024-05-20 10:45:39 +00:00
Rhys Perry
f01cac835f
aco/stats: support GFX12 in collect_preasm_stats()
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29225 >
2024-05-20 10:45:39 +00:00
Rhys Perry
9e9cabd2fa
aco/waitcnt: support GFX12 in waitcnt pass
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29225 >
2024-05-20 10:45:39 +00:00
Rhys Perry
cadce0f3b7
aco: add GFX12 wait counters
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29225 >
2024-05-20 10:45:38 +00:00
Samuel Pitoiset
7fe169dd4a
ac,radv,radeonsi: introduce a helper to build a sampler descriptor
...
This introduces ac_sampler_state which contains all information to
build a sampler descriptor for AMD hardware instead of duplicating
code between RADV and RadeonSI. Both drivers just need to fill this
new struct to get a descriptor.
This allows RADV to get GFX12 support for free. I think we should
introduce helpers for other type of descriptors.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29221 >
2024-05-17 13:43:12 +00:00
Samuel Pitoiset
caca5e0de6
radv: add more helpers to emit viewports
...
Viewports are emitted differently on GFX12 and adding helpers would
help.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29215 >
2024-05-17 08:04:02 +00:00
Samuel Pitoiset
73e1ff6b54
radv: use float instead of double for viewport zscale/ztranslate
...
The float precision should be largely enough.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29215 >
2024-05-17 08:04:02 +00:00
Samuel Pitoiset
50ef8600bc
radv: pass radv_physical_device to radv_emit_default_sample_locations()
...
To emit PA_SC_CENTROID_0 which changed on GFX12.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29215 >
2024-05-17 08:04:02 +00:00
Samuel Pitoiset
9e7c44ea11
radv: simplify radv_emit_default_sample_locations()
...
PA_SC_CENTROID_PRIORITY has been moved on GFX12 and it will be easier
to emit it outside of the switch case.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29215 >
2024-05-17 08:04:02 +00:00
Samuel Pitoiset
0697452f57
ac,radv,radeonsi: add a helper to translate buffer dataformat
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29236 >
2024-05-17 07:30:16 +00:00
Samuel Pitoiset
5d9bdb6410
ac,radv,radeonsi: add a helper to translate buffer numformat
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29236 >
2024-05-17 07:30:16 +00:00
Samuel Pitoiset
3409015103
radv: reject unsupported buffer formats earlier
...
To simplify adding common helpers for translating buffer formats.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29236 >
2024-05-17 07:30:16 +00:00
Samuel Pitoiset
622e1b6385
radv: only enable VK_MESA_image_alignment_control on GFX9-11.5
...
This is not yet implemented on GFX6-8 and GFX12, better to disable it.
Fixes: 6c3457033a ("radv: Implement VK_MESA_image_alignment_control")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29219 >
2024-05-17 06:56:07 +00:00
Samuel Pitoiset
f0200a54d9
radv: add a helper to configure ring buffer descriptors
...
Instead of duplicating everything which is annoying for bringup when
some fields are updated.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29234 >
2024-05-17 06:21:35 +00:00
Collabora's Gfx CI Team
75931d6e68
Uprev Piglit to 8a6ce9c6fc5c8039665655bca4904d5601c6dba0
...
7aa7bc1b01...8a6ce9c6fc
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29050 >
2024-05-16 10:15:17 +00:00
Samuel Pitoiset
c8852719d0
radv: rename radeon perfctr uconfig helpers
...
To match other helpers.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29192 >
2024-05-15 11:34:35 +00:00
Samuel Pitoiset
2957cedad7
radv: remove redundant radeon_set_perfctr_reg() helper
...
It's exactly the same as radeon_set_uconfig_reg_perfctr().
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29192 >
2024-05-15 11:34:35 +00:00
Samuel Pitoiset
6b023780ad
radv: introduce radeon_set_reg_seq()
...
This is the base helper for emitting packets, it will be much more
closer to the new command buffer recording mecanishm if we decide to
use the same helpers as RadeonSI.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29192 >
2024-05-15 11:34:35 +00:00
Samuel Pitoiset
f0d4212847
radv: stop using radv_physical_device for radeon helpers
...
It will be easier to share helpers between RadeonSI and RADV.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29192 >
2024-05-15 11:34:35 +00:00
Marek Olšák
573b2b813a
ac/llvm: improve/simplify/fix load_ssbo
...
Effects:
- multi-component subdword handling removed because it's lowered
- 3-dword loads selected correctly instead of 4-dword loads
- the failure of dEQP-GLES3.functional.buffer.copy.subrange.large_to_small
due to LLVM exposed by a future commit is mysteriously fixed by this
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29053 >
2024-05-15 06:42:33 +00:00
Chia-I Wu
59babe9fa0
radv: make radv_pipeline_has_ngg static
...
radv_pipeline_has_ngg has no external user anymore. Also remove the
unused radv_pipeline_has_gs_copy_shader.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29200 >
2024-05-14 23:42:25 +00:00
Chia-I Wu
be391fdb33
radv: check gs_copy_shader directly for executable props
...
The pipeline could be a graphics pipeline library and
radv_pipeline_to_graphics would assert on debug builds.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29200 >
2024-05-14 23:42:25 +00:00
Rhys Perry
4abe5b7927
aco/gfx12: disable s_cmpk optimization
...
These opcodes were removed.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:28 +00:00
Rhys Perry
2c4f561708
aco: don't change prefetch mode on GFX11.5+
...
This instruction was effectively removed:
https://github.com/llvm/llvm-project/commit/ba131b7017ce
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:27 +00:00
Rhys Perry
5e58e32832
aco/tests: add GFX12 assembler tests
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:27 +00:00
Rhys Perry
e1e5bc0dd0
aco: support GFX12 in assembler
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:27 +00:00
Rhys Perry
74aa6437d6
aco: add GFX11.5+ opcodes
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:27 +00:00
Rhys Perry
97698e564a
aco: add SFPU/ValuPseudoScalarTrans instr class
...
The latency is from LLVM's SISchedule.td
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:27 +00:00
Rhys Perry
e9a25151fa
aco/tests: support GFX12
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Acked-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29162 >
2024-05-14 20:50:27 +00:00
Samuel Pitoiset
6c8224c693
radv: simplify radv_emit_ps_inputs() slightly
...
Also remove useless check about ps_offset being zero because memcmp
return false in this case.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28983 >
2024-05-14 15:32:08 +00:00
Samuel Pitoiset
c63ac0521a
radv: track all graphics shaders context registers
...
This should be similar to the previous ctx_cs logic that was
implemented in order to reduce context rolls but this also applies
to shader objects.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28983 >
2024-05-14 15:32:08 +00:00
Samuel Pitoiset
db597d274b
radv: add more radeon_opt_set_xxx variants
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28983 >
2024-05-14 15:32:08 +00:00
Samuel Pitoiset
d5af67ea2c
radv: add graphics shaders context registers that need to be tracked
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28983 >
2024-05-14 15:32:07 +00:00
Samuel Pitoiset
9532b0f1b2
radv: emit graphics pipelines directly from the cmdbuf
...
This allows us to unify emitting monolithic graphics pipelines and
shader objects.
Though, this temporarily reduces performance in some games due to more
context rolls. But this will be fixed in the following commits by
using the recent mechanism to track context register writes.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28983 >
2024-05-14 15:32:07 +00:00
Samuel Pitoiset
fca40bcce3
radv: make radv_conv_gl_prim_to_gs_out() a non-static function
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28983 >
2024-05-14 15:32:07 +00:00
Friedrich Vock
590ea76104
aco/spill: Insert p_start_linear_vgpr right after p_logical_end
...
If p_start_linear_vgpr allocates a VGPR that is already blocked, RA
will try moving the blocking VGPR somewhere else. If
p_start_linear_vgpr is inserted right before the branch, that move will
be inserted after exec has been overwritten, which might cause the move
to be skipped for some threads.
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28041 >
2024-05-14 13:54:34 +00:00
Friedrich Vock
84c1870b65
aco/tests: Insert p_logical_start/end in reduce_temp tests
...
Linear VGPR insertion will depend on a p_logical_end existing in the
blocks the VGPR is inserted in.
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28041 >
2024-05-14 13:54:34 +00:00
Konstantin Seurer
1f0f76dbdc
radv/ci: Document recent flakes
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29188 >
2024-05-14 13:09:28 +00:00
Konstantin Seurer
9db41dfec5
radv/ci: Add back pipeline library flakes
...
The tests are still flaky.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29188 >
2024-05-14 13:09:28 +00:00
Rhys Perry
cb81ec7a61
aco: don't count certain pseudo towards VMEM_STORE_CLAUSE_MAX_GRAB_DIST
...
fossil-db (navi31):
Totals from 1023 (1.29% of 79395) affected shaders:
MaxWaves: 29258 -> 29240 (-0.06%)
Instrs: 1134024 -> 1133163 (-0.08%); split: -0.10%, +0.02%
CodeSize: 5682108 -> 5678696 (-0.06%); split: -0.08%, +0.02%
VGPRs: 60248 -> 60272 (+0.04%); split: -0.08%, +0.12%
Latency: 3797510 -> 3792797 (-0.12%); split: -0.18%, +0.05%
InvThroughput: 781270 -> 781239 (-0.00%); split: -0.03%, +0.03%
VClause: 24701 -> 23976 (-2.94%); split: -3.55%, +0.61%
Copies: 75177 -> 75169 (-0.01%); split: -0.20%, +0.19%
VALU: 659939 -> 659962 (+0.00%); split: -0.02%, +0.02%
VOPD: 2040 -> 2009 (-1.52%); split: +0.29%, -1.81%
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/28948 >
2024-05-14 12:30:54 +00:00
Eric Engestrom
a40345aaeb
ci: reuse dead .vkd3d-proton-test to make vkd3d less radv-specific
...
Replace dead `script:` with `HWCI_TEST_SCRIPT`, and rename it to have
the `b2c-` prefix since it's no longer generic.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29170 >
2024-05-14 11:46:41 +00:00
Eric Engestrom
9af82fc98f
amd/ci: track changes to VKD3D_PROTON_RESULTS files
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29170 >
2024-05-14 11:46:41 +00:00
Eric Engestrom
7dd2b9e11a
ci: hardcode -vkd3d namespace for VKD3D_PROTON_RESULTS
...
This means we can rely on these files always having that name.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29170 >
2024-05-14 11:46:41 +00:00
Hans-Kristian Arntzen
6c3457033a
radv: Implement VK_MESA_image_alignment_control
...
Signed-off-by: Hans-Kristian Arntzen <post@arntzen-software.no>
Co-authored-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Co-authored-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29129 >
2024-05-14 09:30:40 +00:00
Hans-Kristian Arntzen
14457b358f
ac/surface: Add surface flags to prefer 4K and 64K alignment.
...
Signed-off-by: Hans-Kristian Arntzen <post@arntzen-software.no>
Co-authored-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Co-authored-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29129 >
2024-05-14 09:30:40 +00:00
Samuel Pitoiset
2097bec163
radv: fix the late scissor workaround for GFX9 since a recent refactoring
...
This was a typo.
Fixes: 92337aff03 ("radv: split cmdbuf dirty flags into dirty/dirty_dynamic")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11142
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29156 >
2024-05-14 08:36:46 +00:00
Dave Airlie
2f02af39b3
radv/video/encode: fix quality params on v2 hw.
...
This should have the extra dword as well.
Fixes: 54d499818c ("radv/video: add initial support for encoding with h264.")
Acked-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29098 >
2024-05-14 05:45:57 +00:00