Commit Graph

199876 Commits

Author SHA1 Message Date
Job Noorman
c3e7384bbb ir3: always set wrmask for movmsk
We failed to set the wrmask of movmsk expanded from ballot.macro. This
caused legalization to miss the need for (ss) when a component other
than the first is used.

Signed-off-by: Job Noorman <jnoorman@igalia.com>
Fixes: 1a78604d20 ("ir3: Add support for subgroup arithmetic")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32918>
2025-01-07 20:55:22 +00:00
Marek Olšák
c20c46cf7b ac: update ATOMIC_MEM definitions
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32877>
2025-01-07 20:24:19 +00:00
Marek Olšák
f72a11f38d radeonsi: always use RADEON_USAGE_DISALLOW_SLOW_REPLY
All places are fine with getting a false negative as long as buffer_wait
returns quickly. This can improve performance.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32877>
2025-01-07 20:24:19 +00:00
Marek Olšák
271d5edf87 radeonsi: fix a perf regression due to slow reply from GEM_WAIT_IDLE for timeout=0
It sometimes takes 1 ms to return with timeout=0, which is unacceptable.

Fixes: 4194774edf - radeonsi: move barriers out of si_launch_grid_internal_ssbos

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32877>
2025-01-07 20:24:19 +00:00
Pierre-Eric Pelloux-Prayer
dd11eec06b gl/spirv: update subgroup_size if GroupNonUniform is used
This is similar to what link_intrastage_shaders is doing and it
fixes the following test:
   KHR-Single-GL46.subgroups.builtin_var.compute.subgroupsize_compute

Which was failing with SPIRV but passing with GLSL, the diff being:
 - SPIRV: "subgroup_size: 1"
 - GLSL:  "subgroup_size: 2"

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32698>
2025-01-07 19:32:43 +00:00
Pierre-Eric Pelloux-Prayer
33affa7c36 radeonsi/tests: update results
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32698>
2025-01-07 19:32:43 +00:00
Pierre-Eric Pelloux-Prayer
dc293ffe50 radeonsi: fallback to util_blitter_draw_rectangle
The blitter VS expects coords to fit in a signed int16. When this
is not the case, use util_blitter_draw_rectangle instead.

Since util_blitter_draw_rectangle sets vertex elements, we need
to make sure they're properly restored.

The alternative to this fallback would be to pass coordinates
unpacked (so 4 SGPRs instead of 2), but this doesn't fix the
fbo-blit-check-limits test because of uv interpolation precision
issue.
Using 2 triangles instead of a rectangle + disabling
window_space_position helps but then this breaks some GLES3 tests,
like dEQP-GLES3.functional.fbo.blit.rect.nearest_consistency_mag_reverse_src_x
(which doesn't pass either if u_blitter is used for all cases).

Using a single triangle covering the whole rectangles fixes all
cases but it then requires to setup scissors to not write too
much pixels...
So, instead of adding so much complexity, let's use u_blitter
for the "large coordinates" fallback, and keep the rectangle blit
for the other cases.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32698>
2025-01-07 19:32:43 +00:00
Samuel Pitoiset
7f50162424 radv: fix programming WALK_ALIGN8_PRIM_FITS_ST on GFX12
This also needs to be disabled when a VRS image is used.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32914>
2025-01-07 18:56:24 +00:00
Samuel Pitoiset
d7bc370b9e radv: configure the VRS surface swizzle mode on GFX12
GFX11 allowed only one swizzle mode for the VRS image but GFX12 allows
all 2D non-linear swizzle modes and PC_SC_VRS_INFO needs to be
configured.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32914>
2025-01-07 18:56:24 +00:00
Samuel Pitoiset
0b53e645a0 radv: disable VRS coarse shading with 8x MSAA on GFX12
This isn't supported and the hw always clamps to 1x1.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32914>
2025-01-07 18:56:24 +00:00
Juan A. Suarez Romero
c5954c4329 v3dv: check requirements for USAGE_INPUT_ATTACHMENT
If the format does not support COLOR_ATTACHMENT or DEPTH_STENCIL
features then it can't be used as an input attachment.

Fixes dEQP-VK.api.info.unsupported_image_usage.*.

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/32790>
2025-01-07 14:50:44 +00:00
Juan A. Suarez Romero
db249f24a6 vc4: initialize variable
While this is strictly not necessary, it fixes an apparent false
positive issue about reading garbage value detected by static analyzer.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
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/32819>
2025-01-07 14:21:42 +00:00
Juan A. Suarez Romero
69d3d7288e v3dv: fix assigned value is garbage or undefined
This is actually a false positive detected by static analyzer, because
it assumes that `device->instance->meta_cache_enabled` can change
between two execution points.

In order to instruct static analyzer this is not the case, we assing it
to a local variable, and do the checks based on that.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
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/32819>
2025-01-07 14:21:42 +00:00
Juan A. Suarez Romero
0d14e129bc v3d: avoid 0-size variable length array
Declaring a variable-length array (VLA) based on a variable that can be
0 is declared dangerous.

In this case, the variable can't take value 0, so adding an assertion
fixes the issue.

This was detected by static analyzer.

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/32819>
2025-01-07 14:21:42 +00:00
Samuel Pitoiset
f94bd67b82 aco: fix VS prologs on GFX12
MTBUF/MUBUF instructions must use zero for SOFFSET, use const_offset
instead.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32904>
2025-01-07 13:44:32 +00:00
Corentin Noël
55cd0fb42c virgl: Use MAX_SAMPLERS instead of MAX_SHADER_SAMPLER_VIEWS
The PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS cap is meant for samplers and not sampler
views, change this.

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32706>
2025-01-07 13:15:47 +00:00
Corentin Noël
ab5084b054 virgl: Update virgl_hw.h from virglrenderer
Use the latest version and update the supported formats.

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32706>
2025-01-07 13:15:46 +00:00
Job Noorman
b5c99e6f57 ir3/cp: swap back correct srcs when swap failed
While making the swapping code generic, the swap-back path was left as
is causing the wrong sources to be swapped.

Signed-off-by: Job Noorman <jnoorman@igalia.com>
Fixes: 00656526d8 ("ir3/cp: extract common src swapping code")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32920>
2025-01-07 12:14:14 +00:00
Danylo Piliaiev
ac2046c5b0 tu/perfetto: Add app and engine names to the command buffer tracepoint
Makes possible to understand which app submitted a command buffer.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31550>
2025-01-07 11:44:41 +00:00
Danylo Piliaiev
5ae03b4aea tu/perfetto: Always emit submission event and time it
We previously missed submissions that don't sync timestamps.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31550>
2025-01-07 11:44:41 +00:00
Boris Brezillon
e55de285cc panfrost: Kill panfrost-job.h
It's empty now, so we don't need to include it from the packer headers.

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/32899>
2025-01-07 11:10:55 +00:00
Boris Brezillon
c0f3bac826 panfrost: Move MAX_{MIP_LEVELS,IMAGE_PLANES} to pan_texture.h
This is where those macros are used, and those are the last two
definitions preventing us from dropping panfrost-job.h.

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/32899>
2025-01-07 11:10:55 +00:00
Boris Brezillon
e48f2da7da panfrost: Move MALI_EXTRACT_INDEX to pan_format.h
Move MALI_EXTRACT_INDEX to pan_format.h where all format-related macros
live and kill the unused MALI_EXTRACT_TYPE and MALI_FORMAT_COMPRESSED
macros.

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/32899>
2025-01-07 11:10:55 +00:00
Boris Brezillon
2fdbdc270b panfrost: Kill the uXX typedefs
We use uintXX_t most of the time, so let's be consistent and use the
stdint types everywhere instead of their shorter uXX variants.

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/32899>
2025-01-07 11:10:55 +00:00
Boris Brezillon
63fc0a2de9 panfrost: Kill the mali_ptr typedef
mali_ptr is no shorter than uint64_t, and we already have a few places
where we use uint64_t to store GPU virtual addresses in src/panfrost, so
let's just kill this typedef and use uint64_t types everywhere.

That's one step towards panfrost-job.h removal.

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/32899>
2025-01-07 11:10:55 +00:00
Feng Jiang
701600fb11 radv/rt: Fix memleak in radv_init_header()
Fixes: f8b584d ("vulkan/runtime,radv: Add shared BVH building framework")
Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32887>
2025-01-07 09:49:56 +00:00
Samuel Pitoiset
c5fe9dcf16 ac/descriptors: fix configuring NBC views on GFX12
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32892>
2025-01-07 09:15:12 +00:00
Boris Brezillon
ae76a6a045 panvk: Pack push constants
We're about to add more sysvals, and the more we add, the bigger the
sysvals region gets, which increases the amount of memory we have to
allocate when push_uniforms are dirty.

Instead of allocating FAUs for all sysvals/push_constants, track FAU
usage per-shader, and pack those. This implies emitting an FAU buffer
per stage instead of trying to share it, but that's an acceptable
trade-off.

While at it, automate the sysval dirty tracking a bit.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
aa78fe7683 panvk: Pass a cmdbuf to blend_emit_descs()
Now that panvk_cmd_buffer.h is accessible from
src/panfrost/vulkan/panvk_vX_xxx.c files, there's no reason to pass
a gazillon arguments to blend_emit_descs(). We can just pass a cmdbuf
and let the helper extract the other parameters from there. It also
allows for extra automation, like dirtying the push_uniform buffer
when the new blend config reads the blend constant.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
ed55ab17db panvk: Factor-out the sysvals initialization logic
We're about to make the sysval logic a bit more complication when
introducing push constant packing. Let's first factor-out the sysvals
handling so the JM/CSF backend don't have to duplicate the thing.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
a6319f8951 panvk: Don't lower load_blend_const_color_rgba
We use blend shaders, so load_blend_const_color_rgba should
not be present in the fragment shader. We might want to re-introduce
this code if we decide to specialize fragment shaders when the
blend configuration is static, but let's drop it for now.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
2af6e4beeb pan: Don't pretend we support load_{vertex_id_zero_base,first_vertex}
load_vertex_id_zero_base() is supposed to return the zero-based
vertex ID, which is then offset by load_first_vertex() to get
an absolute vertex ID. At the same time, when we're in a Vulkan
environment, load_first_vertex() also encodes the vertexOffset
passed to the indexed draw.

Midgard/Bifrost have a sligtly different semantics, where
load_first_vertex() returns vertexOffset + minVertexIdInIndexRange,
and load_vertex_id_zero_base() returns an ID that needs to be offset
by this vertexOffset + minVertexIdInIndexRange to get the absolute
vertex ID. Everything works fine as long as all the load_first_vertex()
and load_vertex_id_zero_base() calls are coming from the
load_vertex_id() lowering. But as mentioned above, that's no longer
the case in Vulkan, where gl_BaseVertexARB will be turned into
load_first_vertex() and expect a value of vertexOffset in an
indexed draw context.

We thus need to fix the mismatch by introducing two new
panfrost-specific intrinsic so we can stop abusing load_first_vertex()
and load_vertex_id_zero_base().

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
54033bc052 panvk: Fix first_vertex/base_instance types
gl_Base{VertexARB,Instance} are signed integers, so reflect that in
the types we declare in the sysval struct.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
19173dfa40 panvk: Don't lower load_base_vertex
load_base_vertex is coming from SYSTEM_VALUE_BASE_VERTEX which should
only exist in GL. In Vulkan, gl_BaseVertex is translated to
SYSTEM_VALUE_FIRST_VERTEX, which is turned into load_first_vertex
instructions.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
bbfcd473f9 pan/bi: Fix mem_access_size_align_cb() for push constants
bit_size should be at least 32, and alignment at least 4 bytes.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
2611dc106a pan/bi: Disallow non-zero .{range,base} on load_push_constant instructions
There seems to be several lowering pass that don't take the base/range
into account, like nir_lower_mem_access_bit_sizes(). This caused
issues when we tried using it on push_constants to make sure accesses
are 32-bit aligned, so let's make sure the frontend is propagating the
base to the offset, and assigns range to zero (AKA undefined).

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
8496159885 pan/mi: Don't pretend we support push constants
This code was probably added when we were considering supporting
Vulkan on Midgard, but we don't handle the
nir_intrinsic_load_push_constant, so it make little sense to
lower push constant IOs in this backend.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
8166a218ee pan/indirect: Don't use .base to pass the push_constant offset
We're about to assert when .base != 0 in the Bifrost backend,
but we first make sure all push_constant users stop passing
the offset through .base.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
22bbc8f87b panvk: Don't define push_constant range/base when we don't have to
We just removed a lowering pass making use of these because base/range
are not updated by some other lowering passes, so let's not encourage
future use of base/range by keeping them set to zero.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
3e473a9d4c pan/bi: Get rid of bi_lower_load_push_const_with_dyn_offset()
The vulkan driver is now lowering push constant dynamic indexing to
global loads, so we can get rid of this pass.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
0361c1ca08 panvk: Lower load_push_constant with dynamic offset to global loads
The csel-ladder we have in bi_lower_load_push_const_with_dyn_offset()
is not great, and is relying on base/range being valid. It turns out
nir_lower_mem_access_bit_sizes(), which we rely on to make push constant
accesses 32-bit aligned, doesn't preserve those when splitting accesses.

Let's simplify the thing by lowering push constant accesses with a
dynamic offset to global loads.

We also reset the base and offset values in the lowering pass, to make
sure the backend doesn't rely on them for other things.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
58d8d4ce7b panvk: Lower dynamic push_constant loads in desc_copy logic
We're about to drop the dynamic push_constant lowering pass,
but first we must patch all the bits relying on it.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Acked-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
3d5ddaaffa panvk: Automate sysval access from NIR shaders
Emitting nir_load_push_constant() calls with the right base/range/offset
for sysvals is tedious and error prone. Provide syntactic sugar macros
to automate that.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
cb20cb7b2f panvk: Stop using magic values for the sysval push constant offset/range
The sysval base comes from the amount of FAU words we reserve for user
push constants, and the range is capped by the sysval struct size.
Add macros to express that instead of using magics values.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:19 +00:00
Boris Brezillon
258979d69c panvk: Wrap our descriptor lowering passes in NIR_PASS()
This allows us to do the validation after each step instead of once at
the end.

Since validation is done in nir_lower_descriptors(), we no longer
need to do it panvk_lower_nir(), and we don't need to return
progress information either. So adjust the prototype of
nir_lower_descriptors() accordingly.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Lars-Ivar Hesselberg Simonsen <lars-ivar.simonsen@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32415>
2025-01-07 08:15:18 +00:00
Valentine Burley
6564f56a55 ci: Uprev vkd3d-proton to b121e6d746341e0aaba7663e3d85f3194e8e20e1
Fixes a regression affecting drivers that lack support for sparse
binding, introduced in version 2.14.

Signed-off-by: Valentine Burley <valentine.burley@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32860>
2025-01-07 07:35:26 +00:00
Sagar Ghuge
385977955b intel: Set correct maxComputeSharedMemorySize for Xe3+
For Xe3+, set preferred SLM and SLM per threadgroup size.

Bspec: 73211
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32872>
2025-01-07 07:06:09 +00:00
Rob Clark
64d76bbab2 freedreno/a6xx: Fix timestamp emit
I guess this worked accidentially before due to suballocation.  But we
can't rely on that.

Fixes: 8609d62e4d ("freedreno/a6xx: Drop "hardpin" support")
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32908>
2025-01-07 06:36:31 +00:00
Marek Olšák
3800f0af41 nir/algebraic: optimize pack_split(unpack(a).x, unpack(a).y) -> a
This is required to optimize FP64 and Int64 shaders generated by
virglrenderer. It generates pack/unpack around every 64-bit op,
which NIR currently can't eliminate. This fixes that.

There is a new constraint ".y", which means that the use of an instruction
should have swizzle.y. This allows us to add patterns that have Y swizzle
on results of instructions.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32172>
2025-01-07 05:47:52 +00:00
Marek Olšák
b1bc691b0f nir/algebraic: add and improve pack/unpack patterns
Some duplicated patterns are removed.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32172>
2025-01-07 05:47:52 +00:00