Commit Graph

212744 Commits

Author SHA1 Message Date
Boris Brezillon
adcd8411df panvk: Don't expose low/high priority queues on Bifrost
The JM backend logic is not ready for that yet.

Fixes: f04dbf0bc0 ("pan/kmod: query and cache available context priorities from KMD")
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37480>
2025-09-25 10:03:06 +00:00
Boris Brezillon
971e068762 panvk: Fix ordering in prepare_draw()
panvk_draw_prepare_attributes() depends on VS descriptors sets being
up-to-date which implies calling cmd_prepare_shader_desc_tables()
before. panvk_draw_prepare_vs_copy_desc_job() depends on img_attrib_table,
which can be set in panvk_draw_prepare_vs_attributes().

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37501>
2025-09-25 10:50:34 +02:00
Caio Oliveira
f011e5707d brw: Identify if/break/endif special case before emission
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37147>
2025-09-25 06:36:10 +00:00
Caio Oliveira
f00fca998e intel/mda: Add MDA_FILTER to select which archives to generate
Matches if names contains the filter value, multiple values separated by
commas.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
34198545aa intel/mda: Use archive filename as directory name instead of hardcoded "mda/"
This changes debug_archiver to create files inside a directory named
after the archive filename (e.g., "debug.anv.mda/") instead of the
hardcoded "mda/" directory.  This prevents conflicts if multiple
mda.tar files are extracted in the same location.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
3ff37e97a0 intel/mda: Allow more toplevel directory names inside mda.tar files
Will allow generate anv.tar with unique "first directory name" instead
of always "mda/", avoiding overlaps if user untars the files.  The name
still must end with "mda/".

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
a1d66c18c9 intel/mda: If MDA_PREFIX=timestamp use the actual timestamp as a prefix
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
c21494576e intel/mda: Add MDA_OUTPUT_DIR and MDA_PREFIX environment variable support
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
dfdc883833 intel/mda: Add pager support
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
ceb1baf939 intel/mda: Handle non-contiguous object versions in mda.tar files
Allow archives to have interleaved entries where different object
versions don't appear together.  This gives more flexibility to the
drivers when producing the mda.tar files.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
38b462e09a intel/mda: Add -U and -Y diff options
Make more ergonomic to use the common unified and side-by-side diffs,
and also optionally set the context lines (for -U) and the width (for -Y).
This should cover most common cases.  MDA_DIFF_COMMAND is still available
for full control.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
ef3cafe44e intel/mda: Add search/searchall commands
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
44f39eea55 intel/mda: Add tool to inspect mesa debug archives
The debug archive files are regular tar files, so can be
inspected by tar, and also used direct by file managers and editors.
However a few common tasks are worth having already set up in the
repository.

This tool adds convenience to some of those tasks, including

- Print last version of a shader representation;
- Print a `git-log`-like view of the changes of a shader;
- Comparing two shaders, e.g. SIMD8 and SIMD16 shaders in
  Intel;
- Comparing two specific versions of any shaders.

See the "manual" inside the commit for more details.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
dedbe0e826 iris: Create archive file when using INTEL_DEBUG=mda
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
6c90a9c8e3 anv: Create archive file when using INTEL_DEBUG=mda
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
bce2cb1e24 anv: Refactor anv_shader_compile result handling
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
9f6155e47d brw: Also include the final disassembly in the debug archive
This doesn't replace existing support for INTEL_DEBUG=shaders -- so both
`shaders` and `mda` can be used.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
cdef824b7a brw: Include some NIR states in the debug archive
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
f82d85a685 brw: Use debug archive file with INTEL_DEBUG=mda
Instead of dumping multiple files with the optimizer passes, write a single
archive file with all the contents.  The actual file is created
by the drivers, so later commits will actually enable the feature in
anv and iris.

This removes the use of INTEL_DEBUG=optimizer (and the corresponding
enum value) in brw.  That environment variable is still used by ELK --
which currently doesn't support mda.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Caio Oliveira
bccc0fa984 intel/mda: Add code to produce mesa debug archives
Uses the tar format to collect multiple output files.  It can
be inspected using the regular UNIX tools, but a later commit
will add a specialized tool to perform common tasks.

The tar implementation is enough to fulfill the current needs
without adding a dependency.  There's also a small test mostly
to ensure scaffolding is there in case we need to expand the
implementation.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29146>
2025-09-24 23:08:45 -07:00
Iván Briano
186cd59cf2 anv: use the color_map if present for calculating color_mask
If the FS has writes to multiple color outputs, but there are not enough
color attachments for them all, we may optimize out the exceeding ones.
With VK_KHR_dynamic_rendering_local_read, we were not respecting the
mapping from output to attachment set by the application, and the wrong
writes were getting eliminated.

Fixes future CTS tests: dEQP-VK.renderpasses.dynamic_rendering.primary_cmd_buff.local_read.remap_single_attachment*

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37531>
2025-09-24 21:47:42 +00:00
Iván Briano
66fcae5b1b anv: fix FS output <-> attachment map building
The arrays is first memset to OUTPUT_DISABLED, but if we iterate over
MAX_RTS instead of the actual attachment count, we end up resetting any
values not set by the application to the, probably identity, that comes
from the state.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37531>
2025-09-24 21:47:42 +00:00
Caio Oliveira
9f979776ed egl: Don't maintain a list of AtExit functions
Dynamically adding to the list is not used anymore, so
just inline the calls in the atexit callback and remove
_eglAddAtExitCall().

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37518>
2025-09-24 21:16:02 +00:00
Caio Oliveira
8435837a5b egl: Set atexit() handler during initialization
This ensure that the default handlers enumerated in
eglGlobal will be called.  Historically the atexit() would
be set when adding a new handler, but as the code moved on
the handlers were included by default and the function
that added them is not being called anymore.

This fixes memory leaks like

```
==37635== 144 bytes in 1 blocks are still reachable in loss record 2,416 of 2,428
==37635==    at 0x48463F3: calloc (vg_replace_malloc.c:1675)
==37635==    by 0x7D13686: ??? (in /usr/lib64/libdrm.so.2.125.0)
==37635==    by 0x7D13A13: ??? (in /usr/lib64/libdrm.so.2.125.0)
==37635==    by 0x7D18310: drmGetDevices2 (in /usr/lib64/libdrm.so.2.125.0)
==37635==    by 0x4FFC411: _eglDeviceRefreshList (egldevice.c:431)
==37635==    by 0x4FF079A: eglInitialize (eglapi.c:672)
==37635==    by 0x40078F: main (main.c:75)
```

and

```
==37664== 2,680 bytes in 1 blocks are still reachable in loss record 2,423 of 2,428
==37664==    at 0x48463F3: calloc (vg_replace_malloc.c:1675)
==37664==    by 0x4FFCDF3: _eglFindDisplay (egldisplay.c:270)
==37664==    by 0x4FEED00: eglGetDisplay (eglapi.c:418)
==37664==    by 0x501464E: __eglGLVNDGetPlatformDisplay (eglglvnd.c:67)
==37664==    by 0x488170D: ??? (in /usr/lib64/libEGL.so.1.1.0)
==37664==    by 0x40075C: main (main.c:68)
```

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37518>
2025-09-24 21:16:02 +00:00
Faith Ekstrand
0f7e0f79ad 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>
2025-09-24 20:38:13 +00:00
Eric Engestrom
e4edf9203b meson: use vcs_tag() instead of custom script
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37337>
2025-09-24 18:49:37 +00:00
Yonggang Luo
00783d821d meson/util: Define _GNU_SOURCE for mingw
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13944
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13906

Even though use -Dc_std=gnu18 -Dcpp_std=gnu++20 can also compile with mingw,
but for not bothering user, let's us define _GNU_SOURCE for mingw, and it's also
expose more functional that exists in mingw

As it's not a fixes just a improve so have no fixes in commit message

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Tested-by: Vinson Lee <vlee@freedesktop.org>
Tested-by: Prodea Alexandru-Liviu <liviuprodea@yahoo.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37514>
2025-09-24 18:13:03 +00:00
Yonggang Luo
a8470a3c1c meson: Update comment to be clear
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Tested-by: Vinson Lee <vlee@freedesktop.org>
Tested-by: Prodea Alexandru-Liviu <liviuprodea@yahoo.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37514>
2025-09-24 18:13:03 +00:00
Yiwei Zhang
e4b524709f panvk: fix image/buffer destroy to use MODE_IMMEDIATE for unmap
The TYPE_UNMAP was falsely passed as mode, and got mapped to MODE_ASYNC.
This change fixes that.

Fixes: 86068ad1ee ("panvk: implement sparse resources")
Reviewed-by: Caterina Shablia <caterina.shablia@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37539>
2025-09-24 17:55:43 +00:00
Yiwei Zhang
807bb875d6 panvk: fix blackhole bo error path to use MODE_IMMEDIATE for unmap
The TYPE_UNMAP was falsely passed as mode, and got mapped to MODE_ASYNC.
This change fixes that.

Fixes: 7f263dd2fb ("panvk: add blackhole bo")
Reviewed-by: Caterina Shablia <caterina.shablia@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37539>
2025-09-24 17:55:43 +00:00
Silvio Vilerino
12354cd96e d3d12: Fix typo in cast when reading pipe_h265_enc_picture_desc::gpu_stats_psnr
Reviewed-by: Pohsiang (John) Hsu <pohhsu@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37551>
2025-09-24 17:41:45 +00:00
Sushma Venkatesh Reddy
95669ad5df intel/executor: Add examples for srnd
srnd_edge_cases.lua is checking edge cases.
srnd_randomized.lua is shared by Caio and it serves as a good example for
understanding the randomness and probability of rounding.

Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36529>
2025-09-24 17:18:37 +00:00
Sushma Venkatesh Reddy
a1c5f1ccf6 intel/compiler: Validation for SRND instructions
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36529>
2025-09-24 17:18:37 +00:00
Sushma Venkatesh Reddy
fe6d364ca8 brw: Add assembler support for SRND
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36529>
2025-09-24 17:18:37 +00:00
Sushma Venkatesh Reddy
51f4a2572a intel/compiler: Initial bits for SRND instruction
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36529>
2025-09-24 17:18:37 +00:00
Gurchetan Singh
e2b0dee91f virtio: virtgpu_kumquat: clippy fixes
Run clippy and fix the warnings.

Reviewed-by: David Gilhooley <djgilhooley.gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37530>
2025-09-24 16:57:51 +00:00
Mel Henning
ce1d0ae108 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>
2025-09-24 16:41:34 +00:00
Simon Perretta
41a48f4109 pco: add usclib build dependency on generated files
Signed-off-by: Simon Perretta <simon.perretta@imgtec.com>
Acked-by: Frank Binns <frank.binns@imgtec.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37549>
2025-09-24 16:57:02 +01:00
Dylan Baker
1c930a505e anv: don't attempt to memcpy if allocation fails
Based on git history thhese appears to be a subset of
`anv_batch_emit_batch`, so I've structured the code similarly, if
`anv_batch_emit_dwords` returns `nullptr`, we just move on without
copying the memory.

CID: 1665339
CID: 1664814
Reviewed-by: Iván Briano <ivan.briano@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37534>
2025-09-24 15:29:48 +00:00
Mario Kleiner
fc44e708d7 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>
2025-09-24 15:14:42 +00:00
Mario Kleiner
3c01205e32 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>
2025-09-24 15:14:42 +00:00
Daniel Schürmann
d041640b88 aco: remove excess offset handling for load/store_shared
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37453>
2025-09-24 14:28:25 +00:00
Daniel Schürmann
dbb20a4e23 aco/optimizer: remove DS offset optimization
No fossil changes.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37453>
2025-09-24 14:28:24 +00:00
Daniel Schürmann
dd68825feb radeonsi: allow for unsigned wraps for shared memory intrinsics in nir_opt_offsets
Also set correct maxima.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37453>
2025-09-24 14:28:24 +00:00
Daniel Schürmann
10266e7b21 radv: allow for unsigned wraps for shared memory intrinsics in nir_opt_offsets
Totals from 76 (0.10% of 79839) affected shaders: (Navi48)

Instrs: 237450 -> 237323 (-0.05%); split: -0.05%, +0.00%
CodeSize: 1276732 -> 1275824 (-0.07%); split: -0.07%, +0.00%
Latency: 1123467 -> 1123387 (-0.01%); split: -0.01%, +0.01%
InvThroughput: 364942 -> 364738 (-0.06%); split: -0.06%, +0.00%
Copies: 20654 -> 20636 (-0.09%); split: -0.09%, +0.00%
Branches: 7326 -> 7327 (+0.01%)
PreSGPRs: 5197 -> 5195 (-0.04%)
PreVGPRs: 3395 -> 3396 (+0.03%)
VALU: 96134 -> 96034 (-0.10%)
SALU: 48059 -> 48041 (-0.04%); split: -0.04%, +0.00%
VOPD: 10 -> 8 (-20.00%)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37453>
2025-09-24 14:28:24 +00:00
Daniel Schürmann
e1a692f74b nir/opt_offsets: allow for unsigned wraps when folding load/store_shared2_amd offsets
Totals from 131 (0.16% of 79839) affected shaders: (Navi48)

Instrs: 217026 -> 216541 (-0.22%); split: -0.24%, +0.01%
CodeSize: 1150136 -> 1146772 (-0.29%); split: -0.31%, +0.02%
Latency: 4225732 -> 4225549 (-0.00%); split: -0.01%, +0.00%
InvThroughput: 840231 -> 839823 (-0.05%); split: -0.05%, +0.00%
VClause: 3815 -> 3816 (+0.03%)
Copies: 15414 -> 15358 (-0.36%); split: -0.38%, +0.02%
PreSGPRs: 6322 -> 6323 (+0.02%)
PreVGPRs: 6064 -> 6062 (-0.03%)
VALU: 117317 -> 116873 (-0.38%); split: -0.40%, +0.02%
SALU: 25384 -> 25331 (-0.21%); split: -0.22%, +0.02%
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37453>
2025-09-24 14:28:24 +00:00
David Rosca
27f1c671ec radeonsi/uvd: Swap order of comparison to avoid warning
This code worked correctly because va frontend only sets 15 references
and thus ref[15] is always NULL. But the code is still written as being
able to handle 16 refs, so let's fix that.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13920
Reviewed-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37456>
2025-09-24 11:40:28 +00:00
Eric Engestrom
5b4903a2bd i915/meson: generate intel_device_info_gen.h before compiling i915_drm_winsys.c
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37544>
2025-09-24 10:23:18 +00:00
Eric Engestrom
559851ab9e freedreno/meson: generate xml headers before compiling gmemtool
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37544>
2025-09-24 10:23:18 +00:00
Eric Engestrom
f60886d09d etnaviv/meson: generate enums.h before compiling assembler.c
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37544>
2025-09-24 10:23:18 +00:00