Commit graph

209267 commits

Author SHA1 Message Date
Eric Engestrom
0e415e21c7 ci-tron: bump job template commit to get cached job templates
This also includes support for the new job cookie system, verifying that jobs
running originate from the claimed source. This is useful internally but won't
affect users, unlike the feature in the title :)

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37609>
(cherry picked from commit c3957860b8)
2025-10-15 13:55:11 +02:00
Mauro Rossi
4ea070a741 amd: require LLVM when amd-use-llvm is enabled
Commit 2aaa6ebb "build/amd: add amd-use-llvm build option"
allows to build radeonsi and radv without LLVM dependency
so LLVM constraint is applicable when amd-use-llvm=true

Fixes: 82047fa8 ("amd: drop support for LLVM 15, 16, 17")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37695>
(cherry picked from commit dd2476a257)
2025-10-15 13:55:11 +02:00
Karol Herbst
cea965eee5 clc: Fix createDiagnostics for LLVM-22
Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13986
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Mary Guillemard <mary@mary.zone>
Reviewed-by: Janne Grunau <j@jannau.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37690>
(cherry picked from commit 1db77d08e2)
2025-10-15 13:55:11 +02:00
Karol Herbst
7a87cc5299 libagx: fix heap argument type in libagx_draw_robust_index
Fixes: d339bf7a98 ("libagx: rename agx_geometry_state to agx_heap")
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Mary Guillemard <mary@mary.zone>
Reviewed-by: Janne Grunau <j@jannau.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37690>
(cherry picked from commit 9f67cc1510)
2025-10-15 13:55:11 +02:00
TellowKrinkle
3107407734 hk: Enable caching on memory marked with HOST_CACHED_BIT
cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37655>
(cherry picked from commit 05b927ac7e)
2025-10-15 13:55:10 +02:00
Eric Engestrom
7b55d69af1 .pick_status.json: Update to 282e8285f1 2025-10-15 13:55:10 +02:00
Eric Engestrom
6a24baee19 docs: add sha sum for 25.2.4
Some checks failed
macOS-CI / macOS-CI (dri) (push) Has been cancelled
macOS-CI / macOS-CI (xlib) (push) Has been cancelled
2025-10-01 12:45:48 +02:00
Eric Engestrom
ab462ae6b7 VERSION: bump for 25.2.4 2025-10-01 12:32:50 +02:00
Eric Engestrom
7614fa79da docs: add release notes for 25.2.4 2025-10-01 12:32:50 +02:00
Kenneth Graunke
84739d85bf intel/nir: Make ffma peephole optimization preserve fp_fast_math flags
float_controls2 may have marked these as needing to preserve NaN or
other values.  If so, our newly contracted ffma needs to as well.

Fixes dEQP-VK.spirv_assembly.instruction.compute.float_controls2.*.input_args.mat_det_testedWithout_NotNan*
when nir_opt_algebraic is run after this pass.

Cc: mesa-stable
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36750>
(cherry picked from commit 1b0808adf3)
2025-10-01 11:30:51 +02:00
Kenneth Graunke
f0d08a5ceb nir: Add load_simd_width_intel to divergence analysis
For some reason we missed adding this.  This prevents some asserts
from triggering when I call divergence analysis at certain points
in an upcoming patch.

Cc: mesa-stable
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36750>
(cherry picked from commit 25cb6dfbf7)
2025-10-01 11:30:51 +02:00
Ella Stanforth
aae59f1f7a v3d/compiler: Lower load_output after logic operations
Fixes: 42154029fc ("v3d/compiler: Implement software blend lowering")
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35820>
(cherry picked from commit 9263e1838b)
2025-10-01 11:30:51 +02:00
Jianxun Zhang
7d60cd0f93 iris: Disable compression on sharing without modifier
For an image created either without a modifier to share or as the
destination image to get rid of compression by re-allocation, it
should have compression disabled.

Close: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13729
(Fix firefox misrendering when gfx.wayland.hdr option is true)

Backport-to: 25.2

Signed-off-by: Jianxun Zhang <jianxun.zhang@intel.com>
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37098>
(cherry picked from commit 5aa4dc7f77)
2025-10-01 11:30:51 +02:00
Nanley Chery
03e147b17f iris: Drop iris_resource_image_is_pat_compressible
The functionality is provided by isl_surf_supports_ccs().

Also, move the protected content restriction to
iris_resource_configure_aux(). I'm not aware of any reason protected
content wouldn't support CCS. However, to keep this series simple,
enabling that combination is left for another time.

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:51 +02:00
Nanley Chery
cb6b376855 intel: Enable CCS_E on linear surfaces on Xe2+
Allow CCS for non-display linear surfaces in isl_surf_supports_ccs().
We're going to rely more on the helper to determine CCS-enabling for Xe2
on iris.

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:51 +02:00
Nanley Chery
f005cd7d68 intel/isl: Only set CMF on renderable views on Xe2+
The compression format is only used during rendering.

This prevents drivers from hitting an unreachable when we start enabling
CCS on linear surfaces which may have non-renderable and non-pow2 formats.

For now, continue to use the surface format instead of the view format
to look up the CMF. This strategy should return the optimal CMF for
compressed surfaces that undergo redescription during copies.

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:50 +02:00
Nanley Chery
8802a63e17 iris: Fix image reallocation for sharing
On XeKMD, BOs need to be created with a vm_id of zero in order to get
prime handles. That only occurs if the image was created with
PIPE_BIND_SHARED/BO_ALLOC_SHARED. Ensure that shareable images have this
flag in iris_flush_resource().

Fixes the dmabufshare demo on BMG with INTEL_DEBUG=noccs and mesa hacked
to disable suballocation.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13511
Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:50 +02:00
Nanley Chery
d75c5803d3 iris: Add PIPE_BIND_SCANOUT when exporting textures
I don't see anything preventing images from being used for display via
EGL_MESA_image_dma_buf_export. When CCS is enabled on linear surfaces in
a future patch, this will prevent exported DRM_FORMAT_MOD_LINEAR images
from being compressed.

On BMG, this fixes the mesa demo, dmabufshare:
https://gitlab.freedesktop.org/mesa/demos/-/blob/main/src/egl/opengl/dmabufshare.c

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:50 +02:00
Nanley Chery
3885d1752e iris: Disable fast-clears on linear surfaces
Bspec 57340 does not have a fast-clear rectangle for linear surfaces.

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:50 +02:00
Nanley Chery
483cb3395f anv: Disable fast-clears on linear surfaces
Bspec 57340 does not have a fast-clear rectangle for linear surfaces.

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:50 +02:00
Nanley Chery
a0dc73e21d anv: Disable CCS if image bound to wrong heap on Xe2+
Avoids HIZ + CCS flushes and helps debug.

Reviewed-by: Jianxun Zhang <jianxun.zhang@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37168>
2025-10-01 11:30:50 +02:00
Ian Romanick
b6636130be brw/nir: nir_intrinsic_load_reloc_const_intel may not be scalar [v3]
If the (NIR) destination is a register (i.e., not an SSA value), the
destination of the BRW instruction will not be is_scalar. This occurs in
some shaders in Final Fantasy XVI (and
finalfantasytype0_1.rdc.2826e29da3722a83.1.foz).

If the destination is not is_scalar, revert most of this code to the
state previous to f3593df877. This means

- Allocate a SIMD1 register and UNDEF it.
- Emit a SIMD1 MOV_RELOC_IMM to that register.
- Emit an additional MOV to expand the SIMD1 result.

Closes: #12520
Fixes: f3593df877 ("brw/nir: Treat load_reloc_const_intel as convergent")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37384>
(cherry picked from commit 23bd356b42)
2025-10-01 11:30:50 +02:00
Bas Nieuwenhuizen
0955a160fc device-select: Fix error check.
Fixes: 355b96413d ("egl/wayland: Move bind_wayland_display to legacy build option")
Gitlab: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13931
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37622>
(cherry picked from commit 00b8b571c6)
2025-10-01 11:30:50 +02:00
Christoph Neuhauser
482d1c324a egl: Fix invalid device UUID returned by EGL_EXT_device_persistent_id
MR !36998 / commit 72f2565fc9 introduced
an issue where QueryDeviceInfo is not called in eglQueryDeviceBinaryEXT,
which causes the queried UUID to always be zero.
This commit fixes the issue by adding a call to QueryDeviceInfo.
Also, it refactors the inconsistent function names passed to _eglError.

Signed-off-by: Christoph Neuhauser <christoph.neuhauser@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37616>
(cherry picked from commit 5e5bc7a1c7)
2025-10-01 11:30:50 +02:00
Timur Kristóf
3482550e5c ac/nir/ngg: Fix scalarized mesh primitive indices
Take the write_mask into account when storing primitive indices,
otherwise they will end up being stored in the wrong place.

Fixes: 8e24d3426d ("ac/nir/ngg: Refactor MS primitive indices for scalarized IO.")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37610>
(cherry picked from commit d3579190d6)
2025-10-01 11:30:50 +02:00
Faith Ekstrand
ac47f52651 spirv: Add support for OpBitcast in OpSpecConstantOp
This is required for OpenCL but not Vulkan.  This fixes a bunch of
OpenCL CTS fails using the SPIR-V back-end in LLVM as opposed to
SPIRV-LLVM-Translator.

Reviewed-by: Karol Herbst <kherbst@redhat.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37555>
(cherry picked from commit 8ef811b02a)
2025-10-01 11:30:50 +02:00
Jordan Justen
eddc511714 anv: Use image view base-layer in can_fast_clear_color_att()
We currently only support fast clearing the first layer of an image.
Attachments use VkImageView which can specify a base-layer of the view
for an image attachment.

Fixes: 44351d67f8 ("anv: Change params of anv_can_fast_clear_color_view")
Ref: https://projects.blender.org/blender/blender/issues/141181
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Reviewed-by: Rohan Garg <rohan.garg@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37562>
(cherry picked from commit be61c12f3e)
2025-10-01 11:30:50 +02:00
Mel Henning
d134b44b3b nak: Fix divergence test for redux availability
nak's divergence differs slightly from nir's divergence. Fix the test to
match what the backend will use, since we need to allocate a ureg.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13964
Fixes: 295373f29f ("nak: Implement nir_intrinsic_reduce with REDUX")
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37585>
(cherry picked from commit 094804131e)
2025-10-01 11:30:50 +02:00
José Roberto de Souza
e99bd7dbd3 intel/brw: Use ASR over SHR for SHADER_OPCODE_ISUB_SAT
src[1]/src0 is signed and Xe2+ SHR don't support operations over signed
data types so lets switch this over ASR that supports signed data
types.

Cc: mesa-stable
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37557>
(cherry picked from commit 141a225ca1)
2025-10-01 11:30:50 +02:00
Georg Lehmann
9826524924 aco/lower_branches: update branch hints after changing jump targets
Fixes: 13ad3db43f ("aco/lower_branches: implement try_remove_simple_block() in lower_branches()")
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37552>
(cherry picked from commit 8343e45467)
2025-10-01 11:30:50 +02:00
Hyunjun Ko
b67358765a vulkan/video: fix misuse of CLAMP in h265 slice parsing.
Fixes: 7998106355 ("vulkan/video: Fix wrong parsing for H265 decoding")

Signed-off-by: Hyunjun Ko <zzoon@igalia.com>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37412>
(cherry picked from commit 84802cf325)
2025-10-01 11:30:50 +02:00
Tapani Pälli
cf43bd3d62 blorp: add missing pipecontrol after 3DSTATE_WM_HZ_OP for Xe2+
Backport-to: 25.2
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37547>
(cherry picked from commit c8f47d7681)
2025-10-01 11:30:50 +02:00
Dave Airlie
b4cbb513f6 gallivm: handle u8/u16 const loads properly on big-endian.
Turns out just putting the u32 in doesn't work on big endian, so
put the proper u8/u16 values in.

Got a report that since the loop limiter got removed, a gtk4 blur
shader was looping forever on s390x. Turns out it was using a 16-bit
loop variable (because why wouldn't you), and the loop counter was
just staying at 0 all the time.

Cc: mesa-stable
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37593>
(cherry picked from commit e28cfb2bad)
2025-10-01 11:30:49 +02:00
Karol Herbst
65c7192287 Revert "ci: Update CrosVM and Virglrenderer"
This reverts commit ab5605aab3.

We require 1.78 on 25.2 and we should CI against 1.78 on 25.2.

If something in CI requires a newer version, this should be handled
differently. If we require a newer rustc version because of a dependency
we should properly bump the rustc version requirement.

But please no random bumps like this because we don't want to cause random
build failures due to changes in rustc.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37198>
2025-10-01 11:30:49 +02:00
Faith Ekstrand
23495cf441 vulkan/queue: Move shared binary semaphores to temps
If a client creates a semaphore, exports it, and then re-imports it back
into the device, this can trick our semaphore reset logic.  When this
happens, we end up with two different vk_sync structs that have the same
underlying payload so if one is used as the signal and one is used as
the wait of the same submit, we'll end up resetting it because we think
they're different, causing us to lose the signal.

We already have the ability to handle this for the threaded case by
moving the semaphore payload into a new vk_sync which we then destroy
after we're done submitting to the driver.  Use this path for shared
semaphores in the immediate case so we can just wait and signal without
worrying about the reset.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13805
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37149>
(cherry picked from commit 0f7e0f79ad)
2025-10-01 11:30:49 +02:00
Mel Henning
4533272f9c nak: Don't copy-prop adds that flush to zero
Adding zero has the effect of flushing to zero when ftz is set.

This fixes a regression in
dEQP-VK.spirv_assembly.instruction.compute.float_controls.fp32.input_args.reflect_denorm_flush_to_zero
An add.ftz changes one of its arguments to negative rather than positive
zero starting in 8d19ffef0a ("nir: Add more matches for `fmulz`") on
that test, which was then triggering copy-prop which brought this
issue to light.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13961
Fixes: 29bfdcd7 ("nak: Add an ftz bit to a bunch of float ops")
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Reviewed-by: Mary Guillemard <mary@mary.zone>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37537>
(cherry picked from commit ce1d0ae108)
2025-10-01 11:30:49 +02:00
Mario Kleiner
a555c018f9 asahi: Set PIPE_BIND_SCANOUT in agx_resource_from_handle().
Commit 534a04d557 optimized agx_resource_from_handle() to lazily
defer assignment of a kms-ro renderonly_scanout object to an imported
resource until its kms winsys handle is actually queried by a caller
via agx_resource_get_handle(), to avoid unnecessary import into the
DCP display controller. Only resources with bind flag PIPE_BIND_SCANOUT
will get a renderonly_scanout object assigned during such queries.

Problem: This prevents Mesa GBM's gbm_bo_import() function from properly
importing dmabufs for direct scanout use by some Wayland compositors,
e.g., GNOME mutter.

gbm_bo_import() of dmabuf fd's (GBM_BO_IMPORT_FD / GBM_BO_IMPORT_FD_MODIFIER),
even with GBM_BO_USE_SCANOUT flag, will not mark an imported bo with the
PIPE_BIND_SCANOUT bind flag before internally assigning its KMS winsys
handle via screen->resource_get_handle() -> agx_resource_get_handle(),
causing silent failure of that query. Therefore gbm_bo_import() seems
to return a successfully created gbm_bo with all proper properties,
but gbm_bo_get_handle() and gbm_bo_get_handle_for_plane() will return
invalid handles. These invalid handles cause drmAddFbXXX ioctl calls to
fail, and therefore failure of direct scanout of wl_buffers.

Setting PIPE_BIND_SCANOUT for a resource in agx_resource_from_handle()
may retain the optimization and makes gbm_bo_get_handle[_for_plane]()
work. This fixes direct scanout of fullscreen wl_surface / wl_buffers
under at least GNOME mutter 48.

Fixes: 534a04d557 ("asahi: Flip kmsro around to allocate on the GPU")
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37538>
(cherry picked from commit fc44e708d7)
2025-10-01 11:30:49 +02:00
Mario Kleiner
4bd2fe8be3 asahi: Fix lseek failure error handling in agx_bo_import().
If bo->size = lseek(); would return a failure value of bo->size ==-1,
then current error handling would return while leaving the already
allocated and cached bo for the dmabuf fd in a half initialized "zombie"
state. On a successive call to agx_bo_import() for the same fd, the
assigned bo->size == -1 would mark the bo as "already initialized",
just bumping its reference count, and then returning a dysfunctional
bo to the caller, leasing to followup failures elsewhere.

Use goto error; instead, where "error:" handling will zero-out the bo,
marking it as effectively uninitialized, and hopefully causing proper
initialization on a successive call to agx_bo_import().

Fixes: df725d4f64 ("asahi: remove agx_bo::dev")
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37538>
(cherry picked from commit 3c01205e32)
2025-10-01 11:30:49 +02:00
Calder Young
877fbf74c9 anv: Fix tiling for AV1 IntraBC surface on Gfx125+
Fixes: 3c7a834e ("anv: Add support for AV1 video decoding on Gfx125 and Xe2")

Reviewed-by: Hyunjun Ko <zzoon@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37352>
(cherry picked from commit a6b11b58d9)
2025-10-01 11:30:49 +02:00
Ian Romanick
92f6593001 elk: Increase the size of some structure fields in combine_constants
In very large shaders, first_use_ip, last_use_ip, and even (register) nr
can overflow 16 bits. Increase the size of these fields.  Some structure
components are rearranged to promote better packing.

Fixes: 2dad1e3abd ("i965/fs: Add pass to combine immediates.")
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37482>
(cherry picked from commit 3e04990c68)
2025-10-01 11:30:49 +02:00
Ian Romanick
f54df11b41 brw: Increase the size of some structure fields in combine_constants
In very large shaders, first_use_ip, last_use_ip, and even (register) nr
can overflow 16 bits. Increase the size of these fields.
used_in_single_block is moved earlier in the structure to promote better
packing.

Fixes: 2dad1e3abd ("i965/fs: Add pass to combine immediates.")
Closes: #9489
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Tested-by: Tapani Pälli <tapani.palli@intel.com>
Tested-by: @joostruis
Tested-by: @Snoucher
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37482>
(cherry picked from commit b7e1ac8309)
2025-10-01 11:30:49 +02:00
Olivia Lee
31c2259cea panvk: fix FS driver set layout when LD_VAR_BUF is disabled
We can't use shader->info.stage here because it is only initialized in
pan_shader_compile, which is called after nir_lower_descriptors. This
causes us to miss the index adjustment to make room for the varying
attributes when LD_VAR_BUF is disabled.

Signed-off-by: Olivia Lee <olivia.lee@collabora.com>
Fixes: 7b949dd8c4 ("panvk: Use LD_VAR_BUF[_IMM] when possible")
Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37471>
(cherry picked from commit 729827878a)
2025-10-01 11:30:49 +02:00
Lucas Fryzek
752cc3260b anv: Update viewport/scissor state when count changes
We need to ensure that HW viewport and scissor state is updated when
just the count is updated.

Cc: mesa-stable
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37487>
(cherry picked from commit 6e29e13e78)
2025-10-01 11:30:49 +02:00
Qiang Yu
1d286d2e08 radeonsi: fix use aco/llvm debug options
They should be moved to shader options.

Fixes: 5c92fe45a1 ("radeonsi: support more than 64 options for AMD_DEBUG")
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37433>
(cherry picked from commit 996c0af482)
2025-10-01 11:30:49 +02:00
Mike Blumenkrantz
376cb8022d zink: fix u_blitting when clears are pending
previously this only checked to see if dst was bound, but that is not
the only condition in which clears may be flushed, and triggering a clear
flush while blitting will not set image layouts, which means that a renderpass
could be illegally triggered on an UNDEFINED image (even though it wouldn't be used)

instead, do a much more thorough check to determine whether clears can actually be
stored with the expectation that they will otherwise be flushed

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37467>
(cherry picked from commit d98cf09feb)
2025-10-01 11:30:49 +02:00
Mike Blumenkrantz
62d8a3f324 mesa: don't assert when finding a renderbuffer miplevel fails
this can also be caused by winsys and api being out of sync, e.g.,
if the window resize is lagging behind the framebuffer resize

in this case, just use level 0 and assume things will be okay

cc: mesa-stable

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37467>
(cherry picked from commit f9dd9bc30d)
2025-10-01 11:30:49 +02:00
Mike Blumenkrantz
1efceff14a tu: don't deref end info in tu_CmdEndRendering2EXT
this can be null

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37476>
(cherry picked from commit 4b30df4462)
2025-10-01 11:30:49 +02:00
Timur Kristóf
f1d85aebf8 spirv: Always mark FS layer and viewport index inpus as flat
The spec requires these to be decorated as FLAT,
but some apps forgot to set that,
eg. old DXVK before d12a8e09a855

Let's unconditionally decorate these FS inputs as FLAT
in spirv_to_nir, we can do that for free and prevent those
apps from crashing RADV.

Cc: mesa-stable
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33205>
(cherry picked from commit da184ddbe4)
2025-10-01 11:30:48 +02:00
Timothy Arceri
ff77f8951f nir: fix uniform cloning helper again
UBOs in different stages can have the same instance name for
different UBOs so here we make sure to also check that types match
before deciding we have a match.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13254
Fixes: b47b8d16d9 ("nir: expose reusable linking helpers for cloning uniform loads")
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37428>
(cherry picked from commit 870ce22754)
2025-10-01 11:30:48 +02:00
Mike Blumenkrantz
020046ad98 zink: flag gfx pipeline_changed if switching from a shader object draw
this otherwise might fail to do some updates

cc: mesa-stable

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37466>
(cherry picked from commit 6f3d71f790)
2025-10-01 11:30:48 +02:00