Commit graph

207913 commits

Author SHA1 Message Date
Rob Clark
6bc47e65d7 rusticl: Fix work group size validation
For each dimension, we `threads *= lws`.. which is still zero if threads
is initialized to zero.

Fixes: eca4f0f632 ("rusticl/kernel: check that local size on dispatch doesn't exceed limits")
Signed-off-by: Rob Clark <rob.clark@oss.qualcomm.com>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35864>
2025-07-01 18:55:01 +00:00
Rob Clark
c417b83f19 freedreno/a6xx: Fix thread calc for dummy kernels
If a kernel uses no regs, max_reg will be -1.

Signed-off-by: Rob Clark <rob.clark@oss.qualcomm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35864>
2025-07-01 18:55:01 +00:00
Yiwei Zhang
83ae6393e5 virtio/ci: update AHardwareBufferNativeTests expectations
The Blob_BlobTest_* tests should have been fixed by the updated CF
image in 5ac532bfc7.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35865>
2025-07-01 18:28:58 +00:00
Dylan Baker
2e2826d121 meson: use .enable_if for intel tools dependency on expat
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35840>
2025-07-01 17:40:03 +00:00
Dylan Baker
66a30385fe meson: change RadV dependency on LLVM to an ACO tests dependency
RadV itself doesn't require LLVM, only the ACO tests do. So stop
requiring LLVM for ACO without its tests.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35840>
2025-07-01 17:40:03 +00:00
Dylan Baker
39ccd7899c meson: use feature options for LLVM
This allows us to get better error messages in cases where LLVM has been
explicitly disabled but not found, as well making use of the feature
object for the required argument to dependency. This in turn can give
better error messages when the object is used incorrectly.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35840>
2025-07-01 17:40:03 +00:00
Eric Engestrom
ec97eadc9f ci: fix yamllint warnings about whitespace
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35857>
2025-07-01 16:17:13 +00:00
Eric Engestrom
e149cba160 ci: make sure that sanity job must pass before running other jobs
An unintended consequence of !35203 is that when container jobs are not
there, nothing depends on the `sanity` job anymore.

Fix this by making all the jobs using a container image we generate also
depend on `sanity` through the `.use-$distro/$variant` templates.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35857>
2025-07-01 16:17:12 +00:00
Yiwei Zhang
a5762997da venus: support AHB storage image format
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
R8 + GPU_DATA_BUFFER has been added to support AHB backed storage image
for compute use cases.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35845>
2025-07-01 15:34:10 +00:00
Valentine Burley
5ac532bfc7 ci/android: Update Cuttlefish image
Main changes:
- Use hwcomposer=drm for venus_guest_angle instead of ranchu
- Cherry pick an upstream change in external/minigbm
  https://chromium-review.googlesource.com/c/chromiumos/platform/minigbm/+/6691931

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35786>
2025-07-01 14:50:55 +00:00
Valentine Burley
26bd1df9bf virtio/ci: Run additional VKCTS tests on Cuttlefish with Venus+ANV
Extend the deqp-runner suite to run a fractional set of VKCTS tests
on Cuttlefish with Venus on ANV. This involved:

- Introducing a skip list for tests incompatible with this setup
- Increasing the parallelism of the pre-merge job on CML

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35786>
2025-07-01 14:50:54 +00:00
Rhys Perry
21c4400278 aco: update ctx.block when inserting discard block
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13432
Backport-to: 25.1
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35833>
2025-07-01 14:31:11 +00:00
Job Noorman
329d47421b ir3/isa: ignore bit 54 in alias encoding
Recent versions of the blob started generating alias instructions with
bit 54 unset. The blob's disassembler doesn't seem to care about this
bit so let's ignore it as well.

Signed-off-by: Job Noorman <jnoorman@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35827>
2025-07-01 14:07:59 +00:00
Feng Jiang
7cffd3818f mesa/st: Fix potential array out-of-bounds in st_bind_hw_atomic_buffers()
The value of MaxAtomicBufferBindings comes from the driver
and may exceed PIPE_MAX_HW_ATOMIC_BUFFERS, causing an array
out-of-bounds issue.

Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
Reviewed-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35730>
2025-07-01 13:47:09 +00:00
Feng Jiang
ac6dddb850 virgl: Make max_hw_atomic_counter_buffers less than PIPE_MAX_HW_ATOMIC_BUFFERS
The values of gl_constants.MaxAtomicBufferBindings and
gl_program_constants.MaxAtomicBuffers are derived from
pipe_shader_caps.max_hw_atomic_counter_buffers, which is
synchronized with the host's GL_MAX_*_ATOMIC_COUNTER_BUFFERS.

Based on the definition of struct virgl_context and other
factors, the current virgl driver can only support a maximum
of 32 atomic buffers. If no restrictions are imposed on
pipe_shader_caps.max_hw_atomic_counter_buffers, an error like
the following will occur in the vm when the host's
GL_MAX_*_ATOMIC_COUNTER_BUFFERS exceeds 32.

  Thread 1 "glmark2-drm" received signal SIGABRT, Aborted.
  Download failed: Invalid argument.  Continuing without source file ./nptl/./nptl/pthread_kill.c.
  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
  warning: 44	./nptl/pthread_kill.c: No such file or directory
  #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
  #1  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
  #2  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
  #3  0x00007ffff784527e in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
  #4  0x00007ffff78288ff in __GI_abort () at ./stdlib/abort.c:79
  #5  0x00007ffff782881b in __assert_fail_base (fmt=0x7ffff79d01e8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n",
  assertion=assertion@entry=0x7ffff63f686a "start + count <= 32", file=file@entry=0x7ffff63f6854 "../src/util/
  bitscan.h", line=line@entry=306, function=function@entry=0x7ffff6d4c020 <__PRETTY_FUNCTION__.16> "u_bit_cons
  ecutive") at ./assert/assert.c:96
  #6  0x00007ffff783b517 in __assert_fail (assertion=assertion@entry=0x7ffff63f686a "start + count <= 32", file
  =file@entry=0x7ffff63f6854 "../src/util/bitscan.h", line=line@entry=306, function=function@entry=0x7ffff6d4c020
  <__PRETTY_FUNCTION__.16> "u_bit_consecutive") at ./assert/assert.c:105
  #7  0x00007ffff5250ef5 in u_bit_consecutive (count=48, start=0) at ../src/util/bitscan.h:306
  #8  0x00007ffff5252337 in u_bit_consecutive (count=48, start=0) at ../src/gallium/auxiliary/util/u_inlines.h:75
  #9  virgl_set_hw_atomic_buffers (ctx=<optimized out>, start_slot=0, count=48, buffers=0x7fffffffd9b0) at ../src/
  gallium/drivers/virgl/virgl_context.c:1351
  #10 0x00007ffff4a58faf in st_bind_hw_atomic_buffers (st=<optimized out>) at ../src/mesa/state_tracker/st_atom_
  atomicbuf.c:168
  #11 0x0000000000000000 in ?? ()

Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
Reviewed-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35730>
2025-07-01 13:47:09 +00:00
Christoph Pillmayer
c7cb7b7dc3 panvk: Advertise VK_KHR_calibrated_timestamps
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35510>
2025-07-01 12:52:41 +00:00
Christoph Pillmayer
4d5f0f6ee2 panvk: Implement VK_KHR_calibrated_timestamps
Add entrypoints for calibrated timestamps.

Co-authored-by: Mary Guillemard <mary.guillemard@collabora.com>

Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35510>
2025-07-01 12:52:41 +00:00
Christoph Pillmayer
fb38f10240 panvk: Handle IUBs in decoder
When we encode inline uniform data into the descriptor table, we should
skip the descriptors that are actually data instead of real descriptors.
Let's do that and also print the inlined data for convenience.

Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35831>
2025-07-01 12:34:41 +00:00
Valentine Burley
54c967cb76 ci: Fix location of conditional build tags
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
This allows the components to be found again after the move in
d5c63dd292 ("ci: split long containers build yaml").

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35851>
2025-07-01 10:41:14 +00:00
Jose Maria Casanova Crespo
0f8c681c5c v3d: fix support for no buffer object bound
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Piglit arb_texture_buffer_object-render-no-bo was generating
gpu resets because the uniform stream was missing the last
Fragment Shader uniform. So it was reading instead of the last
fragment shader uniform the first uniform of the vertex shader.

And using that unrelated VS uniform as the sampler address where
the texture should be read.

So now if a buffer object is not bound for a texture buffer object
we write the texture state base address to 0 (NULL) so the default
texture state is used.

So only is needed to set the 4 lower bits of the tmu_p0 with
the bit-mask of word enables.

Fixes: bb8285c258 ("v3d: add support for no buffer object bound")
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35847>
2025-07-01 09:18:31 +00:00
Christoph Pillmayer
7bf7d8c884 panvk: Advertise timestamp support
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:48 +00:00
Christoph Pillmayer
369b3826fd panvk: Add timestamp copy
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:29 +00:00
Christoph Pillmayer
92c4dfe6ea panvk: Add timestamp write and reset
Timestamps are made up of multiple results from the different subqueues,
decided by the target stage for the timestamp. Afterwards, when the
timestamp query is copied, those individual results will be combined
into the final result.
For the computation of the final result, each timestamp query also has
a separate info field, containing the info required to perform the copy.

Timestamps inside a renderpass which cover the fragment subqueue need
to be deferred until after the RUN_FRAGMENT job. This happens via a linked
list of timestamps in the subqueue context.

Once in each primary command buffer, the syncobjs of the queries completed
so far are signalled. The list of those queries is part of the subqueue
context as well.

Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Acked-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:29 +00:00
Christoph Pillmayer
a472dd8518 panvk: Move get_subqueue_stages to header
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:29 +00:00
Christoph Pillmayer
0be3958159 panvk: Add conditional wait in emit_barrier
This makes it possible to choose, at runtime, to skip the wait in the
dst subqueue of the barrier.
This is needed to remove unnecessary dependencies between subqueues when
no timestamp queries are used.

Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:29 +00:00
Christoph Pillmayer
658550bcc6 panvk: Rename reset_oq_batch
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:29 +00:00
Christoph Pillmayer
eb6f591fd6 panvk: Pull CSF barrier logic into separate function
This makes it easier to implement internal syncs between subqueues later
in this MR.

Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34932>
2025-07-01 08:27:29 +00:00
Erico Nunes
ccff24ba09 lima: drop lima_surface
With the previous refactors, lima_surface no longer contains
driver-specific info. And with recent refactors in mesa,
lima_surface_create is also no longer needed.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35749>
2025-07-01 08:03:03 +00:00
Erico Nunes
cfbb2b590b lima: drop util_framebuffer_init usage
It is marked deprecated together with PIPE_FB_SURFACES.
This refactors the code so that it is not needed.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35749>
2025-07-01 08:03:03 +00:00
Erico Nunes
972da604dc lima: move reload flags from surface to resource
This is in preparation to remove lima_surface.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35749>
2025-07-01 08:03:03 +00:00
Erico Nunes
87e990ec56 lima: handle luminance and intensity pixel formats
These need to be handled when passing formats from pipe_resource
instead of pipe_surface.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35749>
2025-07-01 08:03:03 +00:00
Erico Nunes
bae978d3eb lima: drop tiled_w and tiled_h from lima_surface
These were written but not used anywhere.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35749>
2025-07-01 08:03:03 +00:00
Erico Nunes
4b80ae8c8d lima: drop unused fields from lima_context_framebuffer
These are duplicated in lima_job_fb_info and not used from
lima_context_framebuffer at all, so can just be dropped.

Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35749>
2025-07-01 08:03:02 +00:00
Yiwei Zhang
09eda329a2 venus: filter out vulkan video feature bits on common video formats
Tested with ANV_DEBUG=video-decode,video-encode:
- dEQP-VK.api.info.format_properties.*

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35842>
2025-07-01 07:25:58 +00:00
Samuel Pitoiset
71397a8162 radv/meta: stop allocating sampler for blit operations
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35790>
2025-07-01 08:58:03 +02:00
Samuel Pitoiset
ba8bd13a14 radv: rework initializing/finishing samplers
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35790>
2025-07-01 08:58:02 +02:00
Samuel Pitoiset
b4ea1c37ad vulkan/runtime: add vk_sampler_{init,finish}() helpers
RADV will use them to initialize samplers with no allocations.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35790>
2025-07-01 08:54:04 +02:00
Wenfeng Gao
d81e5c5aa3 mediafoundation: Modify the helper function MFAttachPipeResourceAsSampleExtension to tell MF that the attached IMFMediaBuffer is ready to use.
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
With this change, application can use Lock() to get the buffer.

Reviewed-by: Pohsiang (John) Hsu <pohhsu@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35836>
2025-06-30 23:37:30 +00:00
Timothy Arceri
2ca46c7a7a dri: fix __DRI_IMAGE_FORMAT* to PIPE_FORMAT* mappings
As per the old comment:

"These formats correspond to the similarly named MESA_FORMAT_*
 tokens, except in the native endian of the CPU.  For example, on
 little endian __DRI_IMAGE_FORMAT_XRGB8888 corresponds to
 MESA_FORMAT_XRGB8888, but MESA_FORMAT_XRGB8888_REV on big endian."

Fixes: 7e10601786 ("dri: Redeclare __DRI_IMAGE_FORMAT_* as PIPE_FORMAT_*")
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35814>
2025-06-30 23:04:57 +00:00
Timothy Arceri
94032b2298 dri: add missing field to dri2_dup_image()
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35814>
2025-06-30 23:04:57 +00:00
Timothy Arceri
3a51865faa dri: use plane format directly
Since 7e10601786 we not longer need the table we can just use
the formats directly.

Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35814>
2025-06-30 23:04:57 +00:00
Faith Ekstrand
3853f72f52 nak: I/O offsets are unsigned when combined with RZ
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Fixes dEQP-VK.pipeline.monolithic.descriptor_limits.compute_shader.samplers_16384

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:22 +00:00
Faith Ekstrand
2feedeeecb nak: Don't se .yld or .reuse_mask on Blackwell+
These appear to be gone and everything works without setting them so
let's just treat them like missing bits for now.  According to the CUDA
12.8 disassembler, they still do something but it's not the same thing
they did before and I don't have docs to tell me what they really do.
Best to just not set them.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:21 +00:00
Dave Airlie
1f990187ca nvk: add support for separate depth/stencil for blackwell
Blackwell uses separate ds storage on blackwell for d32s8,
optionally for d24s8, but I've used it here because I could make it
work.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:19 +00:00
Faith Ekstrand
baffad9077 nvk: Allocate separate planes for depth and stencil on Blackwell+
Blackwell adds separate depth/stencil support (finally!) and interleaved
depth/stencil no longer seems to work.  We employ the same trick as ANV
and several other drivers and put stencil in nil_image::planes[1].

Co-authored-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:19 +00:00
Faith Ekstrand
d396544fe1 nvk: Allow sparse binding of YCbCr images
We support sparse binding, just not sparse residency.  While we're here,
we change the check to plane_count > 1, which is the real requirement.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:19 +00:00
Faith Ekstrand
13afd66d78 nvk: Use util_format_stencil_only()
There's no reason to roll our own since the util helpers already have
exactly that function.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:19 +00:00
Faith Ekstrand
db80cb3a04 nil/copy: Base swizzling on the per-plane pipe_format
Among other things, this actually descriptive of the in-memory layout
whereas the VkFormat can sometimes map to multiple pipe_formats.  Also
fix a couple harmless typos while we're here and add some unreachable
cases so packed depth/stencil formats don't fall through to the default
case if we support them in future.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35843>
2025-06-30 21:00:19 +00:00
Alyssa Rosenzweig
3c2f46fcac treewide: use nir_break_if with named if
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Via Coccinelle patch:

    @@
    expression builder, condition;
    identifier nif;
    @@

    -nir_if *nif = nir_push_if(builder, condition);
    -{
    -nir_jump(builder, nir_jump_break);
    -}
    -nir_pop_if(builder, nif);
    +nir_break_if(builder, condition);

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Mel Henning <mhenning@darkrefraction.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35794>
2025-06-30 14:51:54 -04:00
Alyssa Rosenzweig
67237b6f1b treewide: use nir_break_if
Via Coccinelle patch:

    @@
    expression builder, condition;
    @@

    -nir_push_if(builder, condition);
    -{
    -nir_jump(builder, nir_jump_break);
    -}
    -nir_pop_if(builder, NULL);
    +nir_break_if(builder, condition);

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed-by: Mel Henning <mhenning@darkrefraction.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35794>
2025-06-30 14:51:24 -04:00