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
...
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.
...
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
...
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
...
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
Karol Herbst
9c47461889
rusticl/formats: support cl_ext_image_unorm_int_2_101010
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35469 >
2025-06-30 18:04:59 +00:00
Karol Herbst
54b11069d1
rusticl/formats: support CL_UNORM_INT_101010_2
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35469 >
2025-06-30 18:04:59 +00:00
Karol Herbst
b3c245ecf2
clc: add support for cl_ext_image_unorm_int_2_101010
...
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35469 >
2025-06-30 18:04:59 +00:00
Alyssa Rosenzweig
7fd7b18b38
nir: rename AGX geom/tess intrinsics
...
to the new common code name.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:10 +00:00
Alyssa Rosenzweig
d13b321201
nir/lower_gs_intrinsics: drop stuff added for AGX
...
AGX now vendors a significantly different version of this pass, so the common
one doesn't need the stuff added for AGX.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:10 +00:00
Alyssa Rosenzweig
debd619555
hk: optimize point size writes with GS/TS
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:07 +00:00
Alyssa Rosenzweig
279b7c028b
hk: advertise more GS features
...
new impl handles this.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:07 +00:00
Alyssa Rosenzweig
1f7fe678e7
asahi,hk: significantly rework GS
...
get rid of the rasterizer discard variants, by pushing XFB into the hardware VS
and letting everything cascade down from there. that then means hardware VS runs
for all streams, which means we get dynamic rasterization stream selection.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:07 +00:00
Alyssa Rosenzweig
03a5b7f25c
asahi: flush around XFB
...
this is required by the spec. fixes
gles-3.0-transform-feedback-uniform-buffer-object.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Backport-to: 25.1
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:07 +00:00
Alyssa Rosenzweig
933b50b806
asahi: clang-format
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:06 +00:00
Alyssa Rosenzweig
700ee568e0
libagx: add agx_vdm_barrier
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:06 +00:00
Alyssa Rosenzweig
16b53d356a
nir: add rasterization_stream sysval
...
for plumbing transformFeedbackRasterizationStreamSelect (in turn for exercising
more CTS and proving out my design).
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:06 +00:00
Alyssa Rosenzweig
805ef6cc17
nir: add intrinsics for geometry shader lowering
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:05 +00:00
Alyssa Rosenzweig
4f7cae5e61
nir/opt_algebraic: add trichotomy identity
...
In https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 we will
significantly rework geometry shaders & transform feedback. In the new approach,
transform feedback is executed as part of the hardware vertex shader, meaning
the vertex shader needs to write out all the "copies" of the same value into
different parts of the XFB buffer. In the general case of a GS writing triangle
strips, we get 0-3 copies. This is good and lets us parallelize XFB better with
GS.
In the case of a VS alone with XFB, we insert a passthrough GS. In that case
special case, we can only get at most 1 copy, so if we can prove the length of
the output strip is 3 we can delete 2/3 of the shader.
Anyway, the only thing preventing NIR from doing that optimization is failing to
see through some conditionals, fixed by optimizing with the law of trichotomy.
We could add other variants of this pattern (signed vs unsigned, iand vs
ior/ixor) if we expect anything else to hit this other than my boutique use
case.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Marek Olšák <maraeo@gmail.com >
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35802 >
2025-06-30 16:24:04 +00:00
Yiwei Zhang
153857fb64
vulkan/wsi: amend barriers for blit dst buffer going to foreign queue
...
The prime blit dst buffer can be backed by external memory, no matter
host ptr shm or dma-buf export alloc. Whether the external path is taken
is only decided upon blit ctx creation time, so we have to track whether
external in the wsi_image. When the external path is taken, we have to
explicitly handle queue family ownership transfer from internal to
foreign. To be noted, no explicit foreign to internal ownership transfer
is needed since the blit dst content can be left undefined.
Reviewed-by: Hans-Kristian Arntzen <post@arntzen-software.no >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35034 >
2025-06-30 16:03:26 +00:00
Yiwei Zhang
f6bf5d9a3e
vulkan/wsi: amend barriers for blit dst buffer
...
For non-external blit dst buffer, it's bliting the wsi image to a buffer
with mapping populated by vkMapMemory, and it's shared via xcb_put_image
for x11 or memcpy into a shared wl_buffer backed by shm. So we need
additional host stage and host access bit to ensure proper cache flush.
There's no queue family ownership transfer needed.
Reviewed-by: Hans-Kristian Arntzen <post@arntzen-software.no >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35034 >
2025-06-30 16:03:24 +00:00
Jesse Natalie
7f4ae75903
dzn: Roll up initialization failure in dzn_meta_init
...
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13416
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35748 >
2025-06-30 15:13:54 +00:00
Karol Herbst
4b43780bbd
rusticl/queue: fix wrong_self_convention and needless_borrow clippy warnings
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35834 >
2025-06-30 14:17:33 +00:00
Mike Blumenkrantz
9482ad212d
tc: don't reuse first rp info on batch if there is work pending
...
this otherwise causes a mismatch if drivers try to access previous info
during a set_framebuffer_state call (e.g., to flush clears)
Acked-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35777 >
2025-06-30 13:51:42 +00:00
Sergi Blanch-Torne
f0c58518cc
ci: reduce the root .gitlab-ci file
...
Following the idea to distribute in a tree of files to include and split
between the files with or without hidden job definitions, some jobs in the
root file can be moved to files made specific to describe build or test jobs.
Signed-off-by: Sergi Blanch-Torne <sergi.blanch.torne@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35427 >
2025-06-30 12:32:30 +00:00
Valentine Burley
6508c6038f
ci: Use placeholder-job for mr-label-maker-test
...
This is a quick job using the .fdo.ci-fairy image.
Signed-off-by: Valentine Burley <valentine.burley@collabora.com >
Reviewed-by: Sergi Blanch-Torne <sergi.blanch.torne@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35427 >
2025-06-30 12:32:30 +00:00
Sergi Blanch-Torne
396074c59d
ci: split hidden job definition for bare-metal and ci-tron
...
The job definitions for lava-related jobs are encapsulated in a directory,
while the other two farm managers were in the generic test directory. Having a
directory for ci-tron places it side by side with other farm managers. For
bare-metal, it has another advantage, as this encapsulates elements related to
this farm manager in a single place.
To maintain simplicity and consistency in file naming, the gitlab-ci file in
the lava directory is renamed as it has a prefix that corresponds with the
directory hosting it. The other farm equivalent files don't include this
duplication as a prefix, and there isn't such a prefix in any other case of
the CI.
Signed-off-by: Sergi Blanch-Torne <sergi.blanch.torne@collabora.com >
Acked-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org >
Reviewed-by: Eric Engestrom <eric@igalia.com >
Reviewed-by: Valentine Burley <valentine.burley@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35427 >
2025-06-30 12:32:30 +00:00
Sergi Blanch-Torne
d5c63dd292
ci: split long containers build yaml
...
The yaml file for the definitions for container build on different systems can
have a split between systems before split between hidden and build jobs.
Signed-off-by: Sergi Blanch-Torne <sergi.blanch.torne@collabora.com >
Acked-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org >
Reviewed-by: Eric Engestrom <eric@igalia.com >
Reviewed-by: Valentine Burley <valentine.burley@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35427 >
2025-06-30 12:32:29 +00:00