Commit graph

201327 commits

Author SHA1 Message Date
Connor Abbott
5a4dff5922 ir3: Fix non-bindless s2en texture/sampler order
In gallium samplers and textures have a 1:1 correspondance, so it was
impossible to tell which is which. But we use non-bindless textures for
subpass loads, which don't have a sampler (so common code lowers to an
index of 0) and therefore the order matters. With dynamic rendering, we
can have more than 16 slots for input attachments, so the s2en wasn't
getting optimized away and suddenly it starts mattering, and it turns
out we got it wrong. By fixing this we also make the order the same as
the bindless order, which was always tested well by Vulkan.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31261>
2024-10-17 00:30:44 +00:00
Connor Abbott
65c0846537 nir/lower_input_attachments: Handle unscaled input attachments with no index
With VK_KHR_dynamic_rendering_local_read we can have input attachments
with no index, which normally correspond to depth/stencil attachments,
and we have to handle this here when determining whether we need to emit
an unscaled fragcoord for FDM.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31261>
2024-10-17 00:30:44 +00:00
Connor Abbott
4bd506a7f3 spirv: Make the default input attachment index ~0
This will let us know when an input attachment doesn't have an
InputAttachmentIndex, which used to be illegal but is now allowed and
meaningful with VK_KHR_dynamic_rendering_local_read.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31261>
2024-10-17 00:30:44 +00:00
Connor Abbott
87d9127136 v3dv: Don't misuse nir_variable::data.index
The code seems to assume that it's supposed to be a base index for the
binding array, but it's not. It's entirely meaningless and happens to be
set to 0 for all descriptor types except for input attachments, which is
the one case where it's already ignored. Delete the dead code so that
when we change it to a "no index" sentinel value v3dv doesn't blow up.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31261>
2024-10-17 00:30:44 +00:00
Connor Abbott
8e153bbd8f vulkan/state: Track the input attachment count
Tilers need to know, at the very least, which input attachments are
"real" input attachments which map to a color or depth/stencil
attachment in tile memory and which are "fake" input attachments that
should be treated as regular textures. To do this we need to know
VkRenderingInputAttachmentIndexInfoKHR::colorAttachmentCount, which
wasn't provided by the state tracking infrastructure. When the
VkRenderingInputAttachmentIndexInfoKHR isn't provided, we don't know it,
though, so we have to record a special UKNOWN value. In that case, the
driver will know thanks to
VUID-VkGraphicsPipelineCreateInfo-renderPass-09652 that all input
attachments are "real" input attachments that map directly to color
attachments if they have an InputAttachmentIndex.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31261>
2024-10-17 00:30:44 +00:00
Connor Abbott
82169ec551 vulkan/state: Handle NULL in DS input attachment mapping correctly
NULL and VK_ATTACHMENT_UNUSED have different meanings, and we need to
preserve the difference for drivers that use the input attachment
mapping (i.e. turnip).

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31261>
2024-10-17 00:30:44 +00:00
Daniel Stone
938e827c48 ci/deqp: Compress caselists with zstd
The Vulkan caselist is gigantic - over 400MB - and only growing over
time. Luckily zstd gets that down to about 9MB, with absolutely
negligible runtime overhead.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31595>
2024-10-16 22:52:44 +00:00
Daniel Stone
ed8441a339 ci/deqp: Flatten fraction/shard sed into a single pass
Currently, we:
  * copy the case list to a temporary file
  * have sed read it in, decimate for fraction, write it out again
  * have sed read it in, decimate for shard, write it out again

Flatten this out to have a single-pass sed covering both fraction and
shard that reads the source caselist in directly and writes the final
one.

This comes at the cost of an expression that's unreadable even for sed,
but with the Vulkan mustpass over 400MB and growing, it's a good
improvement.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31595>
2024-10-16 22:52:44 +00:00
Daniel Stone
0ec961325b ci: Strip yet more unnecessary things from the rootfs
We don't need to ship a Rust toolchain, drivers from Debian's version of
Mesa, etc. So stop doing it.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31595>
2024-10-16 22:52:44 +00:00
Daniel Stone
9295de1396 ci/vk: Strip and optimise validation layers
The validation layers being installed are somehow 206MB in size. Slim
them down to 26 MB by building the dependencies in release mode, and
stripping on install.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31595>
2024-10-16 22:52:44 +00:00
Daniel Stone
e26ea7a00e ci: Remove non-Proton Wine
We previously only had two traces (one for Raven, one for lavapipe)
running via Wine. To support this, the Vulkan container had Debian's
full Wine installation, one from DXVK, and then a third from Proton
which is used by the b2c jobs.

At 600MB each, this was pretty unsustainable. Remove everything but the
Proton ones.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31595>
2024-10-16 22:52:44 +00:00
Daniel Stone
400694c7c6 ci: Disable trace jobs using old Wine
The radv-raven and lavapipe trace jobs were using Wine installed from
Debian. lavapipe had a single post-merge trace running, and raven had
all but one trace disabled due to being flaky.

b2c is using Proton instead, and it makes absolutely no sense to have
two parallel versions of Wine installed. These should be brought back at
some point running on the same version of Wine as the newer b2c jobs.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31595>
2024-10-16 22:52:44 +00:00
Job Noorman
dd6ac7055f ir3: optimize subgroup shuffles using shfl
One quirk of the shfl instruction is that it only works with dynamically
uniform indices. This commit adds a pass to lower shuffles to the
ir3-specific ones using a loop that iterates all distinct indices one by
one. This is based on the blob's sequence.

Signed-off-by: Job Noorman <jnoorman@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31501>
2024-10-16 22:05:10 +00:00
Job Noorman
0919d0f694 ir3: add helper to get glsl type for nir_def
Signed-off-by: Job Noorman <jnoorman@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31501>
2024-10-16 22:05:10 +00:00
Job Noorman
575c89a73c ir3: add codegen for shuffle_{xor,up,down}_uniform_ir3
Signed-off-by: Job Noorman <jnoorman@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31501>
2024-10-16 22:05:10 +00:00
Job Noorman
4556b18f51 nir: add shuffle_{xor,up,down}_uniform_ir3 intrinsics
These are like shuffle_{xor,up,down} except they expect a dynamically
uniform index. This is necessary since the ir3 shfl instruction does not
work with a divergent index.

Signed-off-by: Job Noorman <jnoorman@igalia.com>
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31501>
2024-10-16 22:05:10 +00:00
Eric Engestrom
9f58d0b0e7 nvk/ci: document more flakes seen
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31691>
2024-10-16 20:40:18 +00:00
Eric Engestrom
6c88251167 zink+radv/ci: document more flakes seen
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31691>
2024-10-16 20:40:18 +00:00
Eric Engestrom
f53deeda9d zink+nvk/ci: document more flakes seen
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31691>
2024-10-16 20:40:18 +00:00
Eric Engestrom
078cbfb076 zink+nvk/ci: document regression
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31691>
2024-10-16 20:40:18 +00:00
Eric Engestrom
01285a1da4 ci: drop spec@egl_ext_surface_compression@create from the rest of the expected fails
Fixes: 68aa78a858 ("Uprev Piglit to 7ce69da1199d12ed0ddaa251ed489750523798fb")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31691>
2024-10-16 20:40:18 +00:00
Eric Engestrom
e0c933677e docs: add sha sum for 24.2.5
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31689>
2024-10-16 20:31:45 +00:00
Eric Engestrom
cf7f8afecc docs: update calendar for 24.2.5
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31689>
2024-10-16 20:31:45 +00:00
Eric Engestrom
d04cc53f55 docs: add release notes for 24.2.5
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31689>
2024-10-16 20:31:45 +00:00
Dylan Baker
bf3b1d8ea9 anv: when handling descriptor sets, layout cannot be NULL if dynamic_offets are used
We have no cases where we intentionally pass a NULL layout when dynamic
offsets, and doing so would cause a null dereference. Le't asd an assert
for that.

CID: 1620447
Fixes: f39cd30f4f ("anv: Track all the descriptor sets")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31638>
2024-10-16 19:54:07 +00:00
Dylan Baker
0714fbff8f anv: assert that we don't read off the end color_att array
Coverity notices that we've insured that index index is < MAX_RTS in one
case, but that it must be greater in one case. Since `color_att_count`
is a uint32_t, it can easily exceed MAX_RTS (8), and would thus create
an out-of-bounds read situation. While the type system would allow this,
the actually implementation shouldn't, so an assert should make Coverity
happy and help us check our assumption.

CID: 1620440
Fixes: d2f7b6d5a7 ("anv: implement VK_KHR_dynamic_rendering_local_read")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31640>
2024-10-16 19:09:25 +00:00
Samuel Pitoiset
17dc91709d radv: use radv_normalize_blend_factor() more
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31688>
2024-10-16 18:24:22 +00:00
Samuel Pitoiset
38e12dd53c radv: optimize breaking batch when CB_TARGET_MASK change
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31688>
2024-10-16 18:24:22 +00:00
Deborah Brouwer
f406595ec7 ci/deqp-runner: implement max-fails
If we get more than 40 unexpected fails/crashes in a merge pipeline,
then stop early to preserve pipeline resources.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31429>
2024-10-16 17:32:53 +00:00
Deborah Brouwer
fd9e0a41dd ci/deqp-runner: uprev from 0.20.0 to 0.20.2
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31429>
2024-10-16 17:32:53 +00:00
Deborah Brouwer
aa53f73be1 ci/deqp-runner: update instructions for uprevving
Since deqp-runner is already being built in the debian base image for test
jobs, it’s not necessary to build it subsequently in GL and VK debian
test images. Update the image tag instructions for uprevving deqp-runner.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31429>
2024-10-16 17:32:53 +00:00
Deborah Brouwer
6a564d84e2 ci/deqp-runner: print version info
Since deqp-runner is built in several different images, print the
deqp-runner version before running it just to double check that we are
using the expected version.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31429>
2024-10-16 17:32:53 +00:00
Deborah Brouwer
5acdef547e ci/deqp-runner: fix option to build from a commit
Since the 'git clone --branch' option only accepts branch names or tags as
arguments, it’s not currently possible to build deqp-runner directly from
a git commit hash.

Revise the deqp-runner build script so that it can build from a commit
even if it doesn’t have a tag or version number.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31429>
2024-10-16 17:32:53 +00:00
Deborah Brouwer
3e901f7c37 ci: remove obsolete build-hang-detection script
The build-hang-detection script was part of the old parallel-deqp-runner
repository which is now superseded by deqp-runner.

Remove the script because it’s no longer used.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31429>
2024-10-16 17:32:53 +00:00
Chia-I Wu
7f4f20c811 panvk: advertise VK_KHR_external_{fence,semaphore}_fd
Remove panvk_GetPhysicalDeviceExternal{Fence,Semaphore}Properties and
let vk_common_GetPhysicalDeviceExternal{Fence,Semaphore}Properties
handle them.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31647>
2024-10-16 16:48:09 +00:00
Samuel Pitoiset
fc52c6358c radv: stop recomputing the viewport xform for guarband/viewport
It's already computed when viewports are bound.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31680>
2024-10-16 16:10:12 +00:00
Chia-I Wu
da80d7dc86 panvk: advertise VK_EXT_external_memory_dma_buf
It is already supported.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31649>
2024-10-16 15:19:25 +00:00
Chia-I Wu
a78b7d3c52 panvk: advertise VK_KHR_external_memory_fd
It is already supported.

Also remove an outdated TODO because pan_kmod_bo_import supports
reference counting.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31649>
2024-10-16 15:19:25 +00:00
Chia-I Wu
21f6ec9e8e panvk: remove panvk_GetPhysicalDeviceImageFormatProperties
Let vk_common_GetPhysicalDeviceImageFormatProperties handle it.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31649>
2024-10-16 15:19:25 +00:00
Chia-I Wu
95db0250e6 panvk: fill in VkExternalImageFormatProperties
Opaque fds are internally dma-bufs.  We also support both export and
import.  But for dma-bufs, we additonally require the image tiling
allows vkGetImageSubresourceLayout for export and
VkImageDrmFormatModifierExplicitCreateInfoEXT for import.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31649>
2024-10-16 15:19:25 +00:00
Chia-I Wu
75f833ca82 panvk: fill in VkExternalBufferProperties
Opaque fds are internally dma-bufs.  We also support both export and
import.

Fixes: 17b81d1fdc ("panvk: expose KHR_external_memory and KHR_external_memory_capabilities")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31649>
2024-10-16 15:19:25 +00:00
Valentine Burley
50a9d1b987 vulkan/format: Update vk_format_from_pipe_format with additional formats
This has been neglected.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:16 +00:00
Valentine Burley
aa01a8c018 vulkan/format: Properly translate 10-bit and 12-bit formats
Some hardware have native 10-bit and 12-bit formats. In order to be able to support these, we need
to translate these VK_FORMATs to new padded pipe formats instead of regular 16-bit formats.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:16 +00:00
Valentine Burley
af338d2d2e tu: Fix incorrect bpcs value for padded formats
This doesn't make a difference for now as we don't expose any padded formats yet,
but will be needed for VK_FORMAT_G10X6_B10X6R10X6_2PLANE_420_UNORM_3PACK16.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00
Valentine Burley
c8a8543af7 vulkan: Fix incorrect bpcs value for padded formats
Skip padding channels and only consider valid color channels.
Add and use a common helper for this.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00
Valentine Burley
9eb315ff98 hk: Remap 10 and 12 bit formats to 16 bit formats
Preserves the previous behavior while handling the new formats.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Acked-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00
Valentine Burley
a33538cb9f nvk: Remap 10 and 12 bit formats to 16 bit formats
Preserves the previous behavior while handling the new formats.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00
Valentine Burley
ab298b9c3a lavapipe: Remap 10 and 12 bit formats to 16 bit formats
Preserves the previous behavior while handling the new formats.

Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00
Konstantin Seurer
0098f8ef35 radv: Remap 10 and 12 bit formats to 16 bit formats
Preserves the previous behavior while handling the new formats.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00
Valentine Burley
81ebd6ea8d util/format: Add new 12-bit P012 RGB/planar formats
Introduce three 12-bit formats: X4R12_UNORM, X4R12X4G12_UNORM, and X4G12_X4B12X4R12_420_UNORM.
These formats allocate 12 bits for each color channel with 4 bits of padding to align with Vulkan's P012
and related planar formats.

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30821>
2024-10-16 14:30:15 +00:00