Commit graph

73165 commits

Author SHA1 Message Date
Tanner Van De Walle
325b7692f8 d3d12: Fix d3d12_surface_destroy() to match pipe_surface_destroy_func()
Fixes: 0615a276 ("gallium: add a destructor param to surface refcounting functions")

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40751>
2026-04-01 18:37:22 +00:00
Juan A. Suarez Romero
48c086cb42 vc4: fix unwanted buffer release on uploader
When converting the index buffer from 4-bytes to 2-bytes, we use the
uploader for the job. Since commit b3133e250e we do an uploader alloc
ref, which releases the uploader buffer if there is no enough space,
creating a new one.

The problem happens when we also need this buffer because it is the one
containing the index buffer to convert. This happens, for instance, if
we need to convert the primitives because they are not supported (e.g.,
converting quads to triangles), as this is done
also using the uploader.

The solution is to ensure the uploader's buffer has an extra reference
so when released, it is not destroyed. This can easily achieved by
calling first pipe_buffer_map_range(), which is required to access the
buffer, and it increases the references.

This fixes `spec@!opengl 1.1@longprim`.

Fixes: b3133e250e ("gallium: add pipe_context::resource_release to eliminate buffer refcounting")
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40642>
2026-04-01 09:10:26 +00:00
Mario Kleiner
ab94515b0a dri: Fix "cosmetic" undefined behaviour warning for RGB[A]16_UNORM formats.
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Ian Romanick reported some "undefined behaviour" warnings during some
not specified tests, relating to introduction of RGB[A}16_UNORM formats
in merge request
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38588

This due to overflowing the 32-bits masks[], and then during assignment
the red/green/blue/alphaMask fields in struct gl_config when using a 16
bpc format. Iow. the red/green/blue/alphaMask would not be usable.

Suppress this warning by setting masks[] to zero for unorm16 formats,
just as was previously done for is_float16, ie. fp16 formats.

16 bpc formats are only exposed for display on non-X11 WSI target
platforms like GBM+DRM, Wayland, surfaceless, and these platforms do
not use the info in red/green/blue/alphaMask at all, so the "undefined
behaviour" is meaningless.

Fixes: f2aaa9ce00 ("dri,gallium: Add support for RGB[A]16_UNORM display formats.")
Reported-by: Ian Romanick @idr
Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40695>
2026-03-31 18:25:05 +00:00
Karol Herbst
73f0d8ed51 ci: add api@clgetmemobjectinfo to fails
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40726>
2026-03-31 17:39:47 +00:00
Ahmed Hesham
c8d7fad153 rusticl: return correct error from clCreateSubBuffer
From the OpenCL specification, `clCreateSubBuffer` should return:
`CL_MISALIGNED_SUB_BUFFER_OFFSET` if there are no devices in
`context` associated with `buffer` for which the `origin` field of
the `cl_buffer_region` structure passed in `buffer_create_info` is
aligned to the `CL_DEVICE_MEM_BASE_ADDR_ALIGN` value.

This was previously unhandled in the entrypoint, marked as TODO.

Add two functions to `Device` for querying the address alignment in
both bits and bytes, for convenience. Properly retrieving the
alignment value from the underlying device/screen is still marked as
TODO.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40726>
2026-03-31 17:39:47 +00:00
Valentine Burley
b68037473a lavapipe/ci: Skip flaky Android CTS test
E.g. https://gitlab.freedesktop.org/mesa/mesa/-/jobs/96379768.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40725>
2026-03-31 15:32:25 +00:00
Valentine Burley
6ebf2d6f32 meson: Add support for buidling zink + Turnip/KGSL
Rename the 'hurd' dri_platform to 'pseudo-drm' to represent non-DRM
presentation platforms.
This platform is now also enabled when building zink and Turnip with the
KGSL backend, allowing zink to use Kopper.

Acked-by: Emma Anholt <emma@anholt.net>
Reviewed-by: Eric Engestrom <eric@igalia.com>
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8634
Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40302>
2026-03-31 15:00:29 +00:00
Eric Guo
c1770565f3 panfrost: Fix NULL pointer dereference in panfrost_emit_images
Fix a crash in image descriptor emission caused by stale image_mask bits.

Root cause:
- set_shader_images used a shift expression with count==64 when clearing
  image_mask, which is undefined behavior in C.
- This could leave image_mask inconsistent with actual image bindings,
  so panfrost_emit_images() might dereferences NULL image resources.

Fixes:
- Use 64-bit-safe bit helpers for mask updates to avoid invalid shifts.

Crash observed when running: OpenCL-CTS api/test_api
Backtrace:
  #0 util_image_to_sampler_view (v->resource is NULL)
  #1 panfrost_emit_images
  #2 panfrost_update_shader_state
  #3 panfrost_launch_grid_on_batch
  #4 panfrost_launch_grid

Backport-to: *
Signed-off-by: Eric Guo <eric.guo@nxp.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40621>
2026-03-31 09:46:39 +00:00
Samuel Pitoiset
c4e3380187 nir,treewide: add nir_image_intrinsic_type
We have 4 image intrinsic variants now. This enum is useful for
nir_rewrite_image_intrinsic() and it will be used by other NIR passes.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40709>
2026-03-31 09:10:27 +00:00
Samuel Pitoiset
cb469cc945 amd: bump required DRM version to 3.54 (Linux kernel 6.6+)
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/40596>
2026-03-31 07:57:25 +00:00
Samuel Pitoiset
4087cf09af radv: improve dumping RGP captures
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
With the per-submit mode, the driver was overwriting the existing file.
To fix that properly, add a RGP capture mode to add _frameXXX or
_submitXXX to the filenames.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40535>
2026-03-31 06:27:07 +00:00
Karol Herbst
b7ca34db13 nir: unvendor ac_nir_lower_sin_cos
So we can use it for Nvidia.

Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Mel Henning <mhenning@darkrefraction.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40541>
2026-03-31 01:47:31 +02:00
Karol Herbst
5bb3c9f69c nir: rename fsin_amd and fcos_amd to a more generic name
Nvidia implements both the same way as AMD does, so it makes sense to
allow for code sharing here.

Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Reviewed-by: Mel Henning <mhenning@darkrefraction.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40541>
2026-03-31 01:47:29 +02:00
Pavel Ondračka
fddc101070 r300: split large HiZ clears into multiple packets
R300_PACKET3_3D_CLEAR_HIZ encodes COUNT in 14 bits (COUNT[13:0]), so a
single packet can clear at most 0x3fff dwords.

Large depth surfaces on R5xx can require more HiZ dwords than that.
When we emitted a single packet, COUNT truncated and part of HiZ RAM
remained uncleared, which could show up as HyperZ corruption.

Emit CLEAR_HIZ in chunks of R300_CLEAR_HIZ_COUNT_MAX and reserve enough
atom space for the worst-case packet count derived.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/360
Fixes: 12dcbd5954 ("r300g: enable Hyper-Z by default on r500")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40040>
2026-03-30 13:37:16 +00:00
Pavel Ondračka
e97ac38ff3 r300: add shared HyperZ pipe-count helper
Introduce r300_hyperz_pipe_count and use it in\nr300_setup_hyperz_properties.\n\nRV530 selects pipe topology from NUM_Z_PIPES, while other families use\nNUM_GB_PIPES. Keeping this in one helper avoids duplicated family checks\nand prepares follow-up HiZ clear sizing changes to reuse the same rule.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40040>
2026-03-30 13:37:16 +00:00
Pavel Ondračka
3fc2627897 r300: disable zmask clears for large surfaces
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40040>
2026-03-30 13:37:16 +00:00
Pavel Ondračka
648dfe88f4 r300: don't apply odd macroblock rounding to 3D textures
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
This is intended only for NPOT 2D textures.

Fixes: 0763fb947 ("r300: align macro-tiled stride-addressed textures in X")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40674>
2026-03-30 12:39:57 +00:00
Pavel Ondračka
f6b9e9c22b r300: lower Z16 polygon offset scale coefficient
The previous value was too high and led to issues in tesseract.

Fixes: 83d636fc7 ("r300: Z16 polygon offset fixes")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40674>
2026-03-30 12:39:57 +00:00
Pavel Ondračka
e68e519b91 r300: fix bias presubtract algebraic transformation
One fneg too many.

Fixes: 0508db915 ("r300: implement bias presubtract")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40674>
2026-03-30 12:39:57 +00:00
Tapani Pälli
d348654a75 iris: use mi_set_autostrip_state for autostrip control
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: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40344>
2026-03-30 11:02:27 +00:00
Adam Simpkins
e16c8cc579 iris: fix a crash in disable_rb_aux_buffer
I have been running into crashes in this function when using blender.
Some of the entries in ice->state.framebuffer.base.cbufs[0] can
apparently have the texture field be null, which was causing a segfault
in this loop.

In my case, nr_cbufs was 3, and the first two cbufs entries had a null
texture and format set to PIPE_FORMAT_NONE. The last entry had format of
PIPE_FORMAT_R16G16_FLOAT and a non-null texture.

Adding this null check before attempting to dereference the texture
fixes the crash for me and allows blender to work normally.

Fixes: ca96f8517c ("iris: remove uses of pipe_surface as a pointer")
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40688>
2026-03-30 07:55:33 +00:00
Samuel Pitoiset
3324abad06 radv: introduce RADV_EXPERIMENTAL envvar for experimental features
Abusing RADV_PERFTEST for experimental features doesn't make real
sense, and I think we should stop doing that.

The existing RADV_PERFTEST options like RADV_PERFTEST=transfer_queue
still exists but they are marked as deprecated, they will be removed
in future Mesa releases.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40646>
2026-03-30 07:27:01 +00:00
Faith Ekstrand
4d56fa661f vulkan: Rename some VK_EXT_descriptor_buffer properties
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40649>
2026-03-30 06:51:26 +00:00
Benjamin Cheng
917dff0b22 ac: Update FW required for variable slice mode
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
There are some compatiblity issues with variable slice mode and
preencode that are fixed with newer FW.

Fixes: d9ba641e28 ("ac: Add variable slice mode interface")
Reviewed-by: David Rosca <david.rosca@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40604>
2026-03-29 15:30:55 +00:00
Benjamin Cheng
bb6d57c90d radeonsi/vcn: Reorder get_slice_ctrl_param
This will need to depend on quality_modes.pre_encode_mode, so reorder
the calls to make it possible.

Fixes: d9ba641e28 ("ac: Add variable slice mode interface")
Reviewed-by: David Rosca <david.rosca@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40604>
2026-03-29 15:30:55 +00:00
Marek Olšák
c361c82a5a radeonsi: draw using a single triangle in u_blitter
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
This fixes dEQP-GLES3.functional.fbo.blit.rect.nearest_consistency*
when not using the rectangle path.

Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40634>
2026-03-28 18:47:55 +00:00
Marek Olšák
6ce1b12a76 radeonsi: sink si_get_pipe_constant_buffer in si_blitter_begin
Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40634>
2026-03-28 18:47:55 +00:00
Marek Olšák
7f846bc50a radeonsi: remove always-set SI_SAVE_FRAGMENT_STATE
Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40634>
2026-03-28 18:47:55 +00:00
Marek Olšák
2dc65308f8 radeonsi: add 64K texture support to gfx blits
Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40634>
2026-03-28 18:47:55 +00:00
Marek Olšák
918e5764f4 radeonsi: disable streamout queries for u_blitter
Cc: mesa-stable
Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40634>
2026-03-28 18:47:55 +00:00
Marek Olšák
556ceb1b75 radeonsi: fix blits via util_blitter_draw_rectangle
It didn't save states properly. The only correct place to save them is
si_blitter_begin. Unfortunately, we can't skip saving and restoring
those states because we don't know in advance whether the rectangle path
will be used.

Cc: mesa-stable
Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40634>
2026-03-28 18:47:54 +00:00
Marek Olšák
ea9a31cc8c gallium/u_blitter: allow using the single triangle for scaled blits too
This should be faster because 2 triangles are inefficient on the diagonal,
generating helper invocations and potentially extra memory loads from dst
because tiles aren't fully covered.

Reviewed-by: Pierre-Eric
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40633>
2026-03-28 18:01:40 +00:00
Natalie Vock
6f80027447 vulkan: Rename {encode,update}_bind_pipeline to {encode,update}_prepare
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39985>
2026-03-28 16:12:09 +01:00
Lorenzo Rossi
c0e0591999 pan/compiler: Replace frag_coord_zw_pan with var_special_pan
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Just a bit cleaner, and we can unify point size too.

Signed-off-by: Lorenzo Rossi <lorenzo.rossi@collabora.com>
Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40677>
2026-03-27 19:23:02 +00:00
Maíra Canal
691cfe40fa v3d: use devinfo->page_size for state uploader default size
The state uploader was hardcoded to 4096 bytes, which doesn't fill the
full page on systems with 16KB pages. Use devinfo->page_size instead so
the uploader default matches the actual allocation granularity.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Maíra Canal <mcanal@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40496>
2026-03-27 18:54:29 +00:00
Maíra Canal
4db32305ec v3d: Rename cle_buffer_min_size to page_size
The variable doesn't store a granularity specific to CLE buffers. It
stores the granularity that the OS imposes on buffer allocations (that
is, the OS page size). Therefore, rename the variable to best reflect
its meaning.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Maíra Canal <mcanal@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40496>
2026-03-27 18:54:29 +00:00
Maíra Canal
bfe92d50ce v3d: sub-allocate sampler view texture state from state uploader
Previously, each sampler view allocated a dedicated BO for its,
TEXTURE_SHADER_STATE packet (~24 bytes), which got rounded up to a
full 4KB page. This wastes memory and inflates the per-job BO handle
count.

Use u_upload_alloc_ref() to sub-allocate texture shader state from the
shared state_uploader, matching the pattern already used by image views.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Maíra Canal <mcanal@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40496>
2026-03-27 18:54:29 +00:00
Maíra Canal
751e0d26ec v3d: use the state uploader for the image view texture shader state
From the documentation, the state uploader should be used inside the
driver for long-term state inside buffers, while the stream uploader
should be used by Gallium's internals. Considering that the image view
texture shader state can be considered long-lived state data, use
`state_uploader` instead of `uploader` for consistency.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Maíra Canal <mcanal@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40496>
2026-03-27 18:54:29 +00:00
Rob Clark
b76678cddd freedreno/a6xx: Fix supported-blit fmt check
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Fixes some KHR-GLES*.core.internalformat.texture2d.* failures.

Signed-off-by: Rob Clark <rob.clark@oss.qualcomm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40665>
2026-03-27 17:48:21 +00:00
Pavel Ondračka
56a6528744 r300/ci: expectation update
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40671>
2026-03-27 10:48:55 +01:00
Tomeu Vizoso
e23fcc1464 ethosu: implement ml_device_destroy for standalone ML device
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
Use ralloc_free to release the device allocated by
ethosu_ml_device_create().

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40578>
2026-03-27 09:35:40 +01:00
Tomeu Vizoso
f06b4dbe33 gallium: add ml_device_destroy callback to pipe_ml_device
Add a destroy callback so that standalone ML devices created via
*_ml_device_create() can properly free their resources.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40578>
2026-03-27 09:35:40 +01:00
Tomeu Vizoso
f0e4ccf664 ethosu: handle NULL bias tensor in convolution
PyTorch Conv2d without explicit bias produces a NULL bias_tensor
in the Gallium pipe_ml_operation. Guard against NULL dereferences
in two places:

- ethosu_lower.c: pass NULL to fill_coefs when bias_tensor is NULL
- ethosu_coefs.c: treat missing biases as zero

Fixes crashes when running Conv2d models without bias through the
Ethos-U NPU backend.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40578>
2026-03-27 09:33:52 +01:00
Tomeu Vizoso
e0b401aa87 ethosu: implement ml_subgraph_deserialize()
Add ethosu_ml_subgraph_deserialize() which reconstructs a subgraph
from a serialized byte buffer. Parses the header (cmdstream size,
coefs size, io size, tensors size), restores the tensor array,
cmdstream, and coefficient buffers.

DRM buffer object creation is deferred to prepare_for_submission()
which is called lazily on first invoke.

Wire pctx->ml_subgraph_deserialize in ethosu_create_context().

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40578>
2026-03-27 09:33:52 +01:00
Tomeu Vizoso
6bae0b55d0 gallium: add pipe_context::ml_subgraph_deserialize()
Add ml_subgraph_deserialize() to pipe_context for reconstructing
a previously-serialized ML subgraph at runtime. This complements
ml_subgraph_serialize() on pipe_ml_device and allows the runtime
to load pre-compiled subgraphs.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40578>
2026-03-27 09:33:52 +01:00
Tomeu Vizoso
aff92add98 ethosu: Specifying SRAM size in pipe_ml_device ID
The spec format is now GEN-MACS-SRAM, e.g. "65-256-4096".

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40578>
2026-03-27 09:07:12 +01:00
Tomeu Vizoso
fc0770d5e3 ethosu: parse optional SRAM size from device spec string
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run
The spec format is now GEN-MACS[-SRAM], e.g. "65-256-4096" or
"85-256". When the SRAM parameter is omitted it defaults to 0.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40647>
2026-03-26 16:13:23 +00:00
Tomeu Vizoso
abd681c169 ethosu: add U85-256 support to ethosu_ml_device_create()
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40647>
2026-03-26 16:13:23 +00:00
Tomeu Vizoso
3b68c5b4bc ethosu: move hardware description from ethosu_screen to ethosu_ml_device
Move target-specific fields (is_u65, ifm_ublock, ofm_ublock,
max_concurrent_blocks, sram_size) from ethosu_screen into
ethosu_ml_device. This decouples the compilation phase from the DRM
file descriptor and pipe_screen, allowing ahead-of-time compilation
where the target NPU is not present on the compilation host.

The ethosu_device_screen() helper is retained only for runtime paths
that need the DRM fd (buffer allocation, job submission, destroy).

Compilation code now accesses hardware parameters through
ethosu_ml_device() cast of pipe_ml_device, which can be created
either from a DRM-backed screen or standalone via
ethosu_ml_device_create() with a target string like "65-256".

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40647>
2026-03-26 16:13:23 +00:00
Qiang Yu
00b1d77176 radeonsi: advertise GL_NV_timeline_semaphore
Set max_timeline_semaphore_difference = UINT64_MAX when timeline syncobj
is supported and GFX uses the kernel queue path (not userq). The GL
state tracker auto-enables GL_NV_timeline_semaphore when this cap is
non-zero.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/15113
Author: Claude Opus 4.6 <noreply@anthropic.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40526>
2026-03-26 14:26:56 +00:00