Commit graph

219952 commits

Author SHA1 Message Date
Georg Lehmann
85021cb5f0 nir/algebraic/tests: invert all excluded fp_math_ctrl flags
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Randomly thought about that, but of course only after marge was already done.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40389>
2026-03-16 13:03:50 +00:00
Georg Lehmann
98ff0a394a nir/opt_algebraic: move some fsat patterns next to the other fsat patterns
I almost missed that they already exist multiple times.

No Foz-DB chagnes.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40389>
2026-03-16 13:03:50 +00:00
Georg Lehmann
607f26814f nir/opt_algebraic: remove manual patterns that optimizes flt([0.0, 1.0], 0.0)
Range analysis can figure this out.

No Foz-DB changes.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40389>
2026-03-16 13:03:50 +00:00
Georg Lehmann
530bb4278c nir/opt_algebraic: remove manual pattern that removes fmax(..., 0.0)
Range analysis will figure this out.

No Foz-DB changes.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40389>
2026-03-16 13:03:50 +00:00
Georg Lehmann
4d176c8ea5 nir/opt_algebraic: turn fabs(a) into fneg(a) if a is not positive
fneg is usually more optimizable.

Foz-DB Navi48:
Totals from 214 (0.19% of 114655) affected shaders:
Instrs: 694279 -> 694155 (-0.02%); split: -0.02%, +0.00%
CodeSize: 3749268 -> 3748024 (-0.03%); split: -0.03%, +0.00%
VGPRs: 18252 -> 18264 (+0.07%)
Latency: 5453691 -> 5453503 (-0.00%); split: -0.00%, +0.00%
InvThroughput: 1024436 -> 1024314 (-0.01%); split: -0.01%, +0.00%
VALU: 453136 -> 453041 (-0.02%); split: -0.02%, +0.00%

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40389>
2026-03-16 13:03:50 +00:00
Georg Lehmann
d77c2a1ece nir/opt_algebraic: take advantage of range helpers including nnan
No Foz-DB changes.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40389>
2026-03-16 13:03:49 +00:00
Natalie Vock
b046eaf36d radv/rt: Fix shared ray query stack on top of application LDS
Since the stack pointer may wrap around the stack size in overflow
cases, traversal logic calculates the real stack pointer with
nir_umod_imm(b, stack, args->stack_entries * args->stack_stride).

For ray queries, "stack" was initialized to
"stack_base + local_invocation_idx * 4". This was completely broken, as
the umod would later delete the stack base completely and overwrite the
start of LDS, which belongs to the apps' shared memory.

Instead, add the stack base as a constant offset in the load/store_stack
callback. (This should also save 1 VALU per ray query)
Also, delete radv_ray_traversal_args::stack_base since it's unused now.

Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40420>
2026-03-16 12:43:59 +00:00
Radu Costas
28dd08755c pvr,ci: Update expected fails list with new tests
Temporarily until they are resolved

Reviewed-by: Frank Binns <frank.binns@imgtec.com>
Signed-off-by: Radu Costas <radu.costas@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40432>
2026-03-16 12:26:16 +00:00
Samuel Pitoiset
e1aa011ce4 radv: stop passing radv_device for SPIR-V debug reports
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40379>
2026-03-16 11:55:45 +00:00
Samuel Pitoiset
639207701d aco,radv,radeonsi: remove debug report support in ACO
This doesn't seem very useful since ACO will abort and print the
error messages to stderr.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40379>
2026-03-16 11:55:45 +00:00
Samuel Pitoiset
d6fe5ee8a6 vulkan: do not pass vk_instance for debug report messages
RADV wants to abstract the compiler from any instance/device/pdev
objects.

The previous NULL check for instance seems to be useless.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40379>
2026-03-16 11:55:45 +00:00
Lionel Landwerlin
a8e49be9d9 vulkan/runtime: add implementation of older entrypoints using KHR_DAC
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40431>
2026-03-16 11:30:46 +00:00
Lionel Landwerlin
b7bf4e5304 vulkan/runtime: build (address|copy)_flags for vk_buffer
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40431>
2026-03-16 11:30:46 +00:00
Lionel Landwerlin
ba2e3b1d10 vulkan/runtime: add new helper for vertex strides
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40431>
2026-03-16 11:30:46 +00:00
David Rosca
25095cc393 radv/video: Fix coding pic_parameter_set_id in H264 slice header
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Cc: mesa-stable
Reviewed-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40374>
2026-03-16 10:39:13 +00:00
David Rosca
0450e4ff65 radv/video: Fix AV1 encode min tile size
Fixes: 37e71a5cb2 ("radv/video: add support for AV1 encoding")
Reviewed-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40374>
2026-03-16 10:39:13 +00:00
Andy Nguyen
44bed00b8b amd/addrlib: Add more GFX1013 GPUs
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40274>
2026-03-16 09:40:41 +00:00
Samuel Pitoiset
fd032536d9 radv: cleanup valid image layouts in radv_layout_is_htile_compressed()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:09 +00:00
Samuel Pitoiset
205fe011ea radv: always use separate depth/stencil layouts for rendering
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:09 +00:00
Faith Ekstrand
3abdee9ec7 vulkan/render_pass: Always use separate depth/stencil layouts
There are no Vulkan drivers in Mesa that don't support this feature and
it's a hard requirement for Vulkan 1.2 so there's no reason why we
shouldn't also require it for the runtime render pass code.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:09 +00:00
Samuel Pitoiset
7343aff8aa radv: fix missing HTILE decompression with separate depth/stencil layouts
These two layouts mean either the depth or the stencil aspect is
compressed. Without TC-compat HTILE (mostly < GFX8), the driver must
expand HTILE.

This prevents regressions with Vulkan runtime code using separate
depth/stencil layouts by default.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:09 +00:00
Samuel Pitoiset
5192ee3c88 radv: handle separate depth/stencil layouts correctly for barriers
Need to split the transitions, one for each aspect.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:08 +00:00
Samuel Pitoiset
3c26a2fdb1 radv: handle separate depth/stencil layouts correctly for fbfetch decompressions
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:08 +00:00
Samuel Pitoiset
cb3cbf4303 radv/meta: stop setting the other depth/stencil attachments when unused
It should be either both or depth-only or stencil-only.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:07 +00:00
Samuel Pitoiset
feffa62a41 radv/meta: add separate ds layouts support to the HTILE expand pass
This should work just fine.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:07 +00:00
Samuel Pitoiset
58441d014e radv: stop checking whether HTILE is compressed with the UNDEFINED layout
This doesn't make sense.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:07 +00:00
Samuel Pitoiset
a55b49569f radv: only set the relevant image views for custom depth/stencil resolves
So the rendering state has correct information, like the aspects.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:07 +00:00
Samuel Pitoiset
7c12efb370 vulkan: add helpers for depth/stencil only layouts
Original patch from Faith Ekstrand.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40154>
2026-03-16 09:16:06 +00:00
Samuel Pitoiset
770a94e126 vulkan: add vk_image_memory_copy_layout()
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/40385>
2026-03-16 08:44:08 +00:00
Samuel Pitoiset
045c1fff7d vulkan: add helpers for device address range
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40385>
2026-03-16 08:44:08 +00:00
Samuel Pitoiset
217dc750e7 vulkan: add support for vkCreateAccelerationStructure2KHR()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40385>
2026-03-16 08:44:08 +00:00
Samuel Pitoiset
730054ca47 vulkan: use vk_object_zalloc() for acceleration structs
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40385>
2026-03-16 08:44:08 +00:00
Samuel Pitoiset
e5bb3edad8 vulkan: update spec to 1.4.346
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40385>
2026-03-16 08:44:08 +00:00
Samuel Pitoiset
6d0fc30e7a vulkan: adjust MESA_VK_PIPELINE_RAY_TRACING_FLAGS with beta extensions disabled
This prevent a build failure in the next commit.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40385>
2026-03-16 08:44:07 +00:00
Samuel Pitoiset
1746837a71 radv/meta: remove CB_RESOLVE
CB_RESOLVE isn't very fast and we already have two different paths,
it's been removed in hw since GFX11. PAL and RadeonSI removed support
for it too.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39957>
2026-03-16 08:12:46 +00:00
Samuel Pitoiset
9c05ca4366 radv/meta: use the fragment resolve path by default
CB_RESOLVE is going to be removed. The driver will fallback to the
compute resolve path if necessary.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39957>
2026-03-16 08:12:46 +00:00
Samuel Pitoiset
90a60c84b5 ac/rtld: remove radeon_info
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:02 +00:00
Samuel Pitoiset
f6b4acdf45 radv: remove radv_use_llvm_for_stage()
This was useful few years ago to investigate ACO vs LLVM issues but
now it seems unnecessary.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:02 +00:00
Samuel Pitoiset
a7cc55c33b radv: remove unnecessary radv_device parameter to few functions
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:01 +00:00
Samuel Pitoiset
1f20feacaa radv: remove radv_nir_compiler_options::info
Passing radeon_info is bad.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:01 +00:00
Samuel Pitoiset
c8499885cb radv: use radv_physical_device_cache_key::use_ngg_culling more
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:00 +00:00
Samuel Pitoiset
744cedf3a1 radv: remove unused radv_device parameter to few functions
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:00 +00:00
Samuel Pitoiset
8d1e148c37 radv: remove empty gather_shader_info_cs()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:50:00 +00:00
Samuel Pitoiset
23dcabcb72 radv: tidy up radv_postprocess_nir()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40375>
2026-03-16 07:49:59 +00:00
Martin Roukala (né Peres)
e09c47cd67 zink/ci: mark the unvanquished trace on vangogh as flake
Signed-off-by: Martin Roukala (né Peres) <martin.roukala@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40394>
2026-03-16 07:25:12 +00:00
Sergi Blanch Torne
6cfab621c7 ci: disable Collabora's farm due to maintenance
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Planned downtime in the farm:
* Start: 2026-03-16 08:00 UTC
* End: 2026-03-16 14:00 UTC

Signed-off-by: Sergi Blanch Torne <sergi.blanch.torne@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40119>
2026-03-16 08:06:46 +01:00
Francois Coulombe
4112eb2b0f vulkan/wsi/headless: add sRGB swapchain format support
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Headless surfaces when queried return that they only support RGBA UNORM
and BGRA UNORM. Adding those lines enables RGBA SRGB and BGRA SRGB
support to headless surfaces.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40275>
2026-03-15 23:15:15 +00:00
Pavel Ondračka
9b12664b72 r300: pad short vertex shaders to avoid R3xx hangs
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Vertex shaders shorter than four instructions can hard-lock R3xx GPUs.
This seems to happen in combination with a small vertex count. This was
seen before, most notably with dummy shaders, but the earlier fix only
removed those dummy shaders, so some occurrences could still slip
through the cracks. Pad all vertex shaders to four instructions on R3xx.

Reviewed-by: Filip Gawin <filip@gawin.net>
Fixes: c6aa639ba9 ("r300: skip draws instead of using a dummy vertex shader")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/337
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40331>
2026-03-15 21:51:43 +00:00
Bas Nieuwenhuizen
5a84a6b775 ac/llvm: Fix build with LLVM 23.
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Simple ac_llvm_context vs LLVMContextRef mixup.

Fixes: c431eaad63 ("ac/llvm: Use new denormal_fpenv attribute for llvm >= 23")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40419>
2026-03-14 19:57:11 +00:00
Natalie Vock
867d0b33b3 radv/rt: Bump ray query stack base limit for GFX12
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
GFX12 encoding added one bit to the stack offset, doubling the limit on
the stack base offset that is possible to encode. In practice, this
always allows using bvh_stack_push* instructions on GFX12 since LDS is
still 64kB.

Cc: mesa-stable
Fixes: 59a39779 (radv/rt: Only use ds_bvh_stack_rtn if the stack base is possible to encode)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40405>
2026-03-14 15:27:49 +00:00