Commit Graph

189580 Commits

Author SHA1 Message Date
Constantine Shablia
0d59fe21ce panvk: remove descriptor pool counters
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29250>
2024-05-21 19:41:11 +00:00
Samuel Pitoiset
bb09fac659 ac,radv,radeonsi: add a function for getting border color swizzle
The swizzle for 8-bit stencil shuld be also fine on RadeonSI.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29307>
2024-05-21 19:12:52 +00:00
Rob Clark
25a206b9ac tu: Don't advertise AHB handle time on non-android
Fixes
dEQP-VK.api.external.memory.android_hardware_buffer.dedicated.image.info
among others.

Fixes: 99753001f3 ("turnip: Support AHardwareBuffer")
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29309>
2024-05-21 18:45:31 +00:00
Rob Clark
b71f3f1314 docs/features: Add missing AHB for tu
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29309>
2024-05-21 18:45:31 +00:00
Marek Olšák
eef5e4221f radeonsi: vectorize load/stores and shrink stores
based on RADV

Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29282>
2024-05-21 18:20:30 +00:00
Marek Olšák
8cb254e0b8 radeonsi: call nir_lower_int64 later to fix ACO failure with Tomb Raider
Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29282>
2024-05-21 18:20:30 +00:00
Marek Olšák
5a115b1055 ac/llvm: global stores should have no holes in the writemask
Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29282>
2024-05-21 18:20:30 +00:00
Marek Olšák
7952e4fc7a ac: move radv_mem_vectorize_callback to common code
Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29282>
2024-05-21 18:20:30 +00:00
Samuel Pitoiset
26cd3a1718 ac,radv,radeonsi: add a helper to set mutable tex desc fields
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
7523c1ec57 radv: stop clearing unnecessary bitfields in radv_set_mutable_tex_desc_fields()
They should already be zero because nothing else sets them before.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
d09afbdebc radv: set ITERATE_256 for GFX10+ in radv_set_mutable_tex_desc_fields()
To be closer to the RadeonSI helper. This doesn't change anything for
RADV because images are required to be bound at image view creation.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
fb37ea092d radv: tidy up meta_va in radv_set_mutable_tex_desc_fields()
To be closer to the RadeonSI helper.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
8adb326f59 radv: tidy up custom pitch for gfx10.3 in radv_set_mutable_tex_desc_fields()
To be closer to the RadeonSI helper.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
d1fa5ffab0 radv: tidy up swizzle in radv_set_mutable_tex_desc_fields()
To be closer to the RadeonSI helper.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
81e927ea05 ac,radv,radeonsi: add a helper to get the tile mode index
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Samuel Pitoiset
72485fe592 radv: set image view descriptors as buffer for non-graphics GPU
Ported from RadeonSI, for CDNA.

Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29286>
2024-05-21 16:41:40 +00:00
Timur Kristóf
c1d38b0b37 nir: Add nir_opt_load_store_update_alignments.
New pass that shares code with nir_opt_load_store_vectorize but
it only updates the alignment of load/store instructions.

It is useful before running other passes which may
potentially destroy that information (eg. by removing some
instructions from which the alignment may be deduced).

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29210>
2024-05-21 16:06:23 +00:00
Alyssa Rosenzweig
0b582449f0 nir/lower_point_size: support lowered i/o
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29248>
2024-05-21 15:30:10 +00:00
Valentine Burley
471ac97a4a drm-shim: Stub syncobj reset ioctl
Fixes DRM_SHIM: unhandled core DRM ioctl 0xC4 (0xc01064c4).

Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28504>
2024-05-21 14:14:25 +00:00
Georg Lehmann
cc404d45ff aco: remove perfwarn
This didn't do anything useful.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29270>
2024-05-21 13:31:23 +00:00
Georg Lehmann
ea3e5bcc99 aco/optimizer: remove ineffective undef opt
No stats changes.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29270>
2024-05-21 13:31:23 +00:00
Georg Lehmann
bd699b5d88 aco/optimizer: remove ineffective vcc opt
No stats changes.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29270>
2024-05-21 13:31:23 +00:00
Eric R. Smith
eefe34127f panfrost: add a barrier when launching xfb jobs in CSF
When we start writing to an XFB buffer we need to synchronize with
any batches reading from it (because the data they need is about
to be overwritten). Do this by introducing a barrier in csf_launch_xfb.

This patch fixes a valhall failure in
KHR-GLES31.core.vertex_attrib_binding.advanced-iterations

Cc: mesa-stable
Signed-off-by: Eric R. Smith <eric.smith@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29092>
2024-05-21 13:03:40 +00:00
Juan A. Suarez Romero
69ceb5dab9 v3d: remove handled cases for devices <= 42
The driver nowadays requires hardware version >= 4.2, but in the old
days it managed older versions.

Remove some leftovers remaining in the code.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29299>
2024-05-21 12:39:41 +00:00
Juan A. Suarez Romero
cbcfb34cf7 v3d: use BITSET for the masks
So far we were using raw uint32_t for handling masks. But this has the
issue that it only allows to handle up to 32 elements; if we need to
handle more elements, the we need to upgrade to uint64_t.

And this happened inadvertently with commit 370f02bf02 ("gallium: Bump
PIPE_MAX_SHADER_IMAGES to 64"), where the number of elements to handled
were increased from 32 to 64, but we didn't upgrade the mask type.

To fix this, and avoid this happening again in the future, let's use
BITSET, which is designed to handle bitmasks, and can able to handle as
many elements as desired.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29299>
2024-05-21 12:39:41 +00:00
Rob Clark
924c5ad2ac egl/android: Fix sRGB visuals
The switch to filtering visuals by pipe_format overlooked the
corresponding _SRGB formats.

Fixes: 273e54391a ("egl/android: Remove hard-coded color-channel data")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11182
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29292>
2024-05-21 11:57:55 +00:00
Samuel Pitoiset
97962f2a34 radv: mark some formats as unsupported on GFX8/CARRIZO
Ported from RadeonSI, untested.

Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29288>
2024-05-21 06:34:06 +00:00
Samuel Pitoiset
e384b28805 radeonsi: reject some texture formats but only on GFX8/CARRIZO
Not sure why this check was missing.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29288>
2024-05-21 06:34:06 +00:00
Samuel Pitoiset
95122a1cf7 ac,radv,radeonsi: introduce a helper to build a FMASK descriptor
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29259>
2024-05-21 06:10:32 +00:00
Juston Li
e1b4b399ce zink: disable cpu_storage for PIPE_USAGE_STREAM
See 8af8dc97bc ("tc: do a GPU->CPU copy to initialize cpu_storage")

On zink, initializing cpu_storage that requires a GPU->CPU copy is
particularly expensive; in addition to a sync, the buffer_map call to
copy the GPU data submits a batch and has to wait for that batch.

Take the PIPE_USAGE_STREAM hint and disable using cpu_storage on
resources that "will be modified once and used at most a few times"
where the benefit of cpu_storage is outweighed by the heavy init time.

Signed-off-by: Juston Li <justonli@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29294>
2024-05-20 22:59:42 +00:00
Rob Clark
01bac643f6 freedreno/ir3: Fix ldg/stg offset
Basically a revert (but not a clean one) of commit 60686d4146
("ir3/a6xx: fix ldg/stg of ulong2 and ulong4 data").  The offset
is a byte offset, not a dword offset.

Backport note: Prior to commit 513fa1873c ("ir3/a7xx: Fix
load_global_ir3 with immediate offset") you could instead just revert
the original commit.

Fixes: 60686d4146 ir3/a6xx: ("fix ldg/stg of ulong2 and ulong4 data")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11169
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29228>
2024-05-20 21:24:53 +00:00
Mike Blumenkrantz
23488790c1 zink: remove dgc debug mode
there is alternative testing available now

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29289>
2024-05-20 19:47:39 +00:00
Mike Blumenkrantz
e093107115 lavapipe: lvp_indirect_command_layout -> lvp_indirect_command_layout_nv
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29293>
2024-05-20 19:27:33 +00:00
Mike Blumenkrantz
aaa3f37ae5 lavapipe: plumb print_cmds through NV DGC
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29293>
2024-05-20 19:27:33 +00:00
Mike Blumenkrantz
42e3d580cc lavapipe: split out DGC into separate file
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29293>
2024-05-20 19:27:33 +00:00
Mike Lothian
3be436830e ac/llvm: Remove global access ops handling
They have been lowered in nir

v2: Keep the _amd versions
v3: Fix if's with removed ops

Signed-off-by: Mike Lothian <mike@fireburn.co.uk>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29280>
2024-05-20 18:41:20 +00:00
Mike Lothian
d2e80e57a3 radeonsi,aco: Run ac_nir_lower_global_access pass
This allows rusticl to run under radeonsi when using ACO

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11179
Signed-off-by: Mike Lothian <mike@fireburn.co.uk>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29280>
2024-05-20 18:41:20 +00:00
Dylan Baker
46644ba371 meson: use glslang --depfile argument when possible
This reduces the amount of manual dependency tracking developers need to
do. This is turned on if glslang >= 11.3.0 is used, or 11.9.0 on
Windows, but otherwise the status quo is maintained. This means I have
not removed any use of `depend_files`. We could make make these hard
requirements and remove the use of `depend_files` too.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28329>
2024-05-20 17:34:17 +00:00
Samuel Pitoiset
32e43fe77c ac,radv,radeonsi: add helper to know if a format is supported by DB
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29291>
2024-05-20 16:55:37 +00:00
Samuel Pitoiset
d2234adf59 ac,radv,radeonsi: add helper to know if a format is supported by CB
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29291>
2024-05-20 16:55:37 +00:00
Samuel Pitoiset
c62f86587f amd/common: move some format related helpers to ac_formats.c
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29291>
2024-05-20 16:55:37 +00:00
Samuel Pitoiset
473559001f radv: add radv_is_colorbuffer_format_blendable()
This will allow us to add a common helper to know if a format is
supported by CB.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29291>
2024-05-20 16:55:37 +00:00
Samuel Pitoiset
8f39e3a0f3 radv: stop checking the return value of ac_get_cb_number_type()
It can't be ~0U.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29291>
2024-05-20 16:55:37 +00:00
Samuel Pitoiset
e227f2cc72 radv: remove redundant check for VK_FORMAT_E5B9G9R9_UFLOAT_PACK32 on GFX6-10
ac_get_cb_format() already returns V_028C70_COLOR_INVALID.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29291>
2024-05-20 16:55:37 +00:00
Sil Vilerino
58ca4cee9e d3d12: Video Encode - Fix inputs for older OS support query cap
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29290>
2024-05-20 14:45:56 +00:00
Sil Vilerino
d8eb9fc9b4 nir: Mark variable as ASSERTED to fix unused variable warning treated as error
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29290>
2024-05-20 14:45:56 +00:00
Samuel Pitoiset
07080c5fc5 radv: simplify creating gfx10 texture descriptors for sliced 3d/2d view of 3d
This will be easier to add a common helper between RADV and RadeonSI
for creating texture descriptors.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29269>
2024-05-20 14:15:40 +00:00
Samuel Pitoiset
16952a179b radv: allow 3d views with VK_IMAGE_CREATE_2D_VIEW_COMPATIBLE_BIT_EXT
VK_IMAGE_CREATE_2D_VIEW_COMPATIBLE_BIT_EXT allows to create 2d views
of a 3d image but nothing in the spec disallows to also create 3d views
when this flag is set.

Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29269>
2024-05-20 14:15:40 +00:00
Samuel Pitoiset
96a9625866 ac,radv,radeonsi: add a function to get the color format endian swap
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:03 +00:00
Samuel Pitoiset
35c6b9c066 ac,radv,radeonsi: add a function to translate db format
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:03 +00:00