Samuel Pitoiset
231f2e4034
radv: add a helper to emit padding with DGC cmdbuf
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36028 >
2025-07-10 12:21:00 +00:00
Samuel Pitoiset
79ab85815b
radv: add helpers to emit one DGC sequence
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36028 >
2025-07-10 12:20:59 +00:00
Samuel Pitoiset
7c3c41c670
radv: add a helper to emit INDIRECT_BUFFER in DGC
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36028 >
2025-07-10 12:20:58 +00:00
Yiwei Zhang
50e299b71c
v3dv: adopt wsi_common_get_memory
...
v2: refactor back to the minimal change to avoid unused variable
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36035 >
2025-07-10 09:51:39 +00:00
Yiwei Zhang
ec71925268
v3dv: adopt wsi_common_create_swapchain_image
...
v2: drop unused variable for Android build
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36035 >
2025-07-10 09:51:39 +00:00
Marek Olšák
7a506d0a41
glsl: remove gl_nir_opt_dead_builtin_varyings
...
It doesn't do anything since IO variables are lowered to intrinsics,
which simplifies and eliminates a lot of variable-specific stuff
like declared but dead builtin varyings and unused components
of builtin varying arrays.
This reduces GLSL compile times by 2.4% with the gallium noop driver.
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Timothy Arceri <tarceri@itqueeze.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36023 >
2025-07-10 08:31:36 +00:00
Marek Olšák
08b522d21e
glsl: check against varying limits using NIR shader_info after nir_opt_varyings
...
nir_opt_varyings reduces the number of varyings. Check against limits after
that, so that old and limited GPUs don't fail linking when nir_opt_varyings
is able to reduce varyings to or below the limit.
The previous code only checked FS inputs, which is glaringly obvious
from the removed var_counts_against_varying_limit function.
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Timothy Arceri <tarceri@itqueeze.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36023 >
2025-07-10 08:31:36 +00:00
Marek Olšák
6d6fdad685
glsl: only set has_transform_feedback_varyings for the last pre-FS shader
...
I don't think this should be set for all shaders. Also simplify it.
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Reviewed-by: Timothy Arceri <tarceri@itqueeze.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36023 >
2025-07-10 08:31:35 +00:00
Mary Guillemard
d08a21b7a3
panvk: Fix wrong reporting of subgroup size for executable properties
...
Fixes: 563823c9ca ("panvk: Implement vk_shader")
Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com >
Reviewed-by: Caterina Shablia <caterina.shablia@collabora.com >
Reviewed-by: Eric R. Smith <eric.smith@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36006 >
2025-07-10 08:01:25 +00:00
Mary Guillemard
db5ad8e3d2
pan/bi: Disallow FAU for CLPER in bi_check_fau_src
...
Previously this was allowing invalid forms like
"CLPER.i32.subgroup8.zero lane-id, src1" to reach bi_pack.
This fixes the assert that can be seen with
"dEQP-VK.glsl.derivate.dfdxsubgroup.*" but doesn't fix failures.
Fixes: 0acc6b564e ("pan/bi: Rework FAU lowering")
Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com >
Reviewed-by: Eric R. Smith <eric.smith@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36006 >
2025-07-10 08:01:25 +00:00
Mary Guillemard
48d716a05f
pan/bi: Do not allow passthrough for instructions disallowing temps
...
Previously we were allowing passthrough to temps without using
bi_reads_temps.
This was causing instructions like CLPER to create undefined encodings.
We now check if the instruction support temps.
Fixes: 4252fb84f4 ("pan/bi: Add passthrough register rewriting helper")
Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com >
Reviewed-by: Eric R. Smith <eric.smith@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36006 >
2025-07-10 08:01:25 +00:00
Georg Lehmann
cac60c39a9
radv/nir/lower_cmat: use explicit shift when calculating gfx12 wave64 layout
...
The rest of the compiler stack doesn't understand the alignment implications
of the combined shift.
Effect on llama.cpp fossils:
Totals from 3 (13.64% of 22) affected shaders:
Instrs: 5778 -> 5684 (-1.63%)
CodeSize: 33540 -> 32800 (-2.21%)
VGPRs: 228 -> 216 (-5.26%)
Latency: 39942 -> 39417 (-1.31%)
InvThroughput: 12037 -> 11862 (-1.45%)
VALU: 2162 -> 2111 (-2.36%)
More importantly, this replaces some ds_load_2addr_b32 with ds_load_b64.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13447
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36016 >
2025-07-10 07:11:23 +00:00
Timothy Arceri
f617b4f850
util: add workaround for legacy OpenGL tf2
...
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3514
Fixes: a34cc97ca3 ("glsl: when NIR linker enable use it to resize uniform arrays")
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36036 >
2025-07-10 05:40:38 +00:00
Vitaliy Triang3l Kuzmin
21136d931d
r600: Fix rectangle coordinate limits on R6xx/R7xx
...
R6xx/R7xx use D3D10 15.8 fixed-point coordinates rather than 16.8.
Cc: mesa-stable
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Signed-off-by: Vitaliy Triang3l Kuzmin <triang3l@yandex.ru >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35953 >
2025-07-10 04:45:53 +00:00
Yiwei Zhang
ace49d9e52
lavapipe: adopt wsi_common_get_memory
...
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:04 +00:00
Yiwei Zhang
6f7dff3abf
lavapipe: adopt wsi_common_create_swapchain_image
...
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:04 +00:00
Yiwei Zhang
f887116c49
turnip: adopt wsi_common_get_memory
...
Reviewed-by: Rob Clark <rob.clark@oss.qualcomm.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:04 +00:00
Yiwei Zhang
273df23a21
nvk: adopt wsi_common_get_memory
...
Tested-by: Thomas H.P. Andersen <phomes@gmail.com >
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:04 +00:00
Yiwei Zhang
187956bd51
panvk: adopt wsi_common_get_memory
...
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:04 +00:00
Yiwei Zhang
7ef0566e26
dozen: adopt wsi_common_get_memory
...
Reviewed-by: Jesse Natalie <jenatali@microsoft.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:04 +00:00
Yiwei Zhang
825c05a7e8
radv: adopt wsi_common_get_memory
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:03 +00:00
Yiwei Zhang
3f273eb01b
hk: adopt wsi_common_get_memory
...
Acked-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:03 +00:00
Yiwei Zhang
7bb3f29b2a
venus: adopt wsi_common_get_memory
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:03 +00:00
Yiwei Zhang
e625862794
vulkan/wsi: add wsi_common_get_memory
...
The current wsi_common_get_image api is mainly used for aliased wsi
image binding. However, it's not a convenient api because what's missing
is the swapchain image memory bound, with which we can trivially fix the
VkBindImageMemoryInfo so it works just like a normal binding request
from the driver pov. To be noted, besides the simplification of the
driver codes, this helper is also to prepare for common BindImageMemory2
implementation.
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35875 >
2025-07-09 23:45:03 +00:00
Emma Anholt
fefa6aa899
dri2: Finish removing the now-unused dep_xcb_dri2.
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19942 >
2025-07-09 14:31:05 -07:00
Emma Anholt
9217e49e80
egl/x11: Match loader_destroy_screen_resources() with init().
...
With the DRI2 removal, it became clear that this code wasn't actually
being called in the DRI3 path.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19942 >
2025-07-09 14:31:05 -07:00
Emma Anholt
b4eed47828
glx: clean up a litttle remains of DRI2 support.
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19942 >
2025-07-09 14:31:05 -07:00
Gorazd Sumkovski
7bc1c456cb
panfrost: Fix incorrect condition in assert
...
Since commit 8bb46de0 , the correct way to check for a compute shader is
with `gl_shader_stage_is_compute()`.
Fixes: d2838f3c ("pan/bi: handle barriers with SUBGROUP scope")
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com >
Reviewed-by: John Anthony <john.anthony@arm.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35957 >
2025-07-09 21:05:54 +00:00
Mel Henning
295768c13e
egl: Clear modifiers if we clear use_flags
...
zink assumes that we won't pass modifiers without PIPE_BIND_SHARED
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13439
Cc: mesa-stable
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36008 >
2025-07-09 20:35:40 +00:00
Mel Henning
0f6a8283ca
zink: Assert ici.tiling != DRM_FORMAT_MODIFIER_EXT
...
if we're not populating VkExternalMemoryImageCreateInfo
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36008 >
2025-07-09 20:35:40 +00:00
Matt Turner
93d0635924
bin/people.csv: Prefer mattst88's @gmail.com address
...
I've never given R-b tags with any other address (and only accidentally
committed using something else).
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36033 >
2025-07-09 20:33:56 +00:00
Juan A. Suarez Romero
b09a07bca1
broadcom/ci: unlock some CI-Tron jobs
...
Enable CI-Tron jobs for piglit full run for rpi3 and skqp jobs for rpi4
and rpi5. They will run in parallel with the baremetal ones for
comparison.
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36032 >
2025-07-09 20:16:32 +00:00
Ian Romanick
5adab50283
brw/nir: Use nir_opt_reassociate_matrix_mul
...
This needs to be called before intel_nir_opt_peephole_ffma, so I
arbitrarilly decided to call it right before.
All Intel platforms had similar results. (Lunar Lake shown)
total instructions in shared programs: 17120227 -> 17118227 (-0.01%)
instructions in affected programs: 5854 -> 3854 (-34.16%)
helped: 51 / HURT: 0
total cycles in shared programs: 895497762 -> 894733940 (-0.09%)
cycles in affected programs: 4603518 -> 3839696 (-16.59%)
helped: 95 / HURT: 21
LOST: 1
GAINED: 0
Reviewed-by: Matt Turner <mattst88@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35925 >
2025-07-09 19:28:49 +00:00
Mike Blumenkrantz
69afd8678a
zink: fix UIL feedback loop usage
...
I got this confused with the DRLR type of feedback loop
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36029 >
2025-07-09 18:42:48 +00:00
Mike Blumenkrantz
1b0c377923
zink: slightly tighten the implicit feedback loop detection logic
...
parts of this are strict about using per-context flags but then using
res->fb_binds is potentially multi-context
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36029 >
2025-07-09 18:42:48 +00:00
Mike Blumenkrantz
8090e24567
zink: assert that batches never use a timeline value of 0
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36029 >
2025-07-09 18:42:47 +00:00
Mike Blumenkrantz
767ecc27cb
zink: enable img copy boxes for blit/copy ops
...
this might enable reduced sync for successive copies
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36010 >
2025-07-09 18:25:13 +00:00
Mike Blumenkrantz
b022cdc8a1
zink: only copy resource during add_bind if it is valid
...
this otherwise is a big no-op
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36010 >
2025-07-09 18:25:13 +00:00
Daniel Stone
e59305c29f
dri: Remove remnants of TexBuffer extension
...
This is no longer needed as a DRI extension.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:59 +00:00
Daniel Stone
a9298ca55c
dri: Remove DRI2 loader extension
...
Now that all our backends are either swrast or using client image-based
allocation, we don't need the DRI2 loader interface anymore. Remove it.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:59 +00:00
Daniel Stone
5be2e7f5c0
dri: Remove getBuffersWithFormat
...
This was only used for X11's DRI2, which we no longer have.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Daniel Stone
a8629e5622
dri: Remove dri2_from_names
...
This is now unused with the removal of X11 DRI2, and the wl_drm
pre-dmabuf path.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Daniel Stone
20f719ecb5
egl/wayland: Use DRM formats rather than wl_drm
...
They're the same thing (as the protocol spec notes, it's just a copy),
and we already have drm_fourcc.h to hand, so just use the DRM
definitions rather than the generated ones.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Daniel Stone
718ef151f2
egl/wayland: Remove support for non-dmabuf wl_drm
...
wl_drm is the legacy protocol which is used to support
EGL_WL_bind_wayland_display to exchange buffers between client and
server. It's supported dmabuf for a very long time, and as a private
protocol for Mesa's use, there is no need to carry around support for
old codepaths, as all relevant drivers support dmabuf.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Daniel Stone
94b51503b3
vulkan: Remove build-system remnants of wl_drm support
...
We don't need to depend on the generated wl_drm files, as wl_drm support
was removed from Vulkan quite some time ago.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Fixes: e090316570 ("vulkan/wsi/wayland: drop support for wl_drm")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Daniel Stone
20590ca771
egl: Remove EGL_MESA_drm_image
...
This extension was designed in a pre-dmabuf world, to allow us to share
DRM buffers based on global GEM names (generated with flink, as distinct
from context-local GEM handles).
We've had dmabuf since Linux kernel 3.4, so there's no need to carry
around this extension which encourages users to do bad things - namely,
to expose their buffers with a global ID that anyone can access - and
requires us to carry around some irritating support code.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Daniel Stone
08c6ba223b
x11: Remove DRI2 support
...
DRI2 was hidden behind a legacy-x11 build option back in the 24.2
release. It's now been a year, so let's get on with removing it so we
can simplify our winsys interactions.
Signed-off-by: Daniel Stone <daniels@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35885 >
2025-07-09 17:49:58 +00:00
Mike Blumenkrantz
b0624f4034
cso: use unbind_trailing for sampler view unbinds on context unbinds
...
this is a bit less noisy for drivers
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36025 >
2025-07-09 17:18:43 +00:00
Mel Henning
94f4fc12ea
nir/divergence_analysis: Add NV_shader_sm_builtins
...
Fixes crucible func.nv.shader-sm-builtins.q0
Fixes: a3839dbb90 ("nak: Change divergence analysis pass order")
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36011 >
2025-07-09 16:47:28 +00:00
David Rosca
a801df753c
radeonsi/video: Fix assert in radeon_bs_code_ns
...
It is valid for w to be 1, in that case nothing should be encoded
in the bitstream.
value must be lower than max, add that as an assert instead.
Reviewed-by: Ruijing Dong <ruijing.dong@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35648 >
2025-07-09 16:30:38 +00:00