Commit graph

186524 commits

Author SHA1 Message Date
Yiwei Zhang
2a7085584e venus: simplify vn_cmd_reset and apply more code sharing
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28112>
2024-03-14 23:40:44 +00:00
Yiwei Zhang
5dbd88ad2a venus: drop vn_get_temp_cmd_ptr
It's more robust to base on original batch cmds instead of assuming
various constraints on copied cmds in the temp storage.

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28112>
2024-03-14 23:40:44 +00:00
Yiwei Zhang
9e7797c8c1 venus: minor cmd count related refactors
This is to prepare for qfb refactor, so that we can distinguish the
current batch's cmd count and the appended new cmd count

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28112>
2024-03-14 23:40:44 +00:00
Yiwei Zhang
4bab7344a8 venus: massive qfb renamings
Summary:
- vn_feedback_query_batch => vn_cmd_query_record
- combined_batches => resolved_batches
- vn_feedback_query => vn_query_feedback

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28112>
2024-03-14 23:40:43 +00:00
Yiwei Zhang
25be8e721d venus: combine query record and reset
Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28112>
2024-03-14 23:40:43 +00:00
Yiwei Zhang
71bf46fa5d venus: qfb to track cmd handle directly
since all usages are with vk handle

Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28112>
2024-03-14 23:40:43 +00:00
Mike Blumenkrantz
e931ef4884 zink: iterate all the modes when doing separate shader fixups
otherwise this might only do the inputs without also handling outputs

Fixes: 0a12cedec9 ("zink: add a special separate shader i/o mode for legacy variables")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28185>
2024-03-14 23:17:02 +00:00
Faith Ekstrand
b68f2e747c zink: Rework sparse texture lowering
Instead of the previous fragile attempt to handle sparse_resident_and
by crawling deref chains, we now insert an is_sparse_resident_zink
intrinsic immediately after the tex or sparse_load intrinsic and define
Zink's sparse resident codes to always be 0/1.  Then sparse_resident_and
becomes iand and is_sparse_texels_resident becomes != 0 and everything
is well-defined and robust.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28123>
2024-03-14 22:37:51 +00:00
Eric Engestrom
8a5120003c ci/deqp: document which build produces which binary
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28181>
2024-03-14 22:06:05 +00:00
Corentin Noël
51593c6b34 dri/kopper: Assume a non-null drawable in flush_frontbuffer
It is expected that drawable is non-null here so don't add check for it.

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28180>
2024-03-14 21:30:31 +00:00
Kenneth Graunke
484246ea0a iris: Eliminate prototype introduced in the previous patch
By moving iris_flush_resource() below.  This is done separately to
make the diff for the actual change in the previous patch easier to
follow.

Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13154>
2024-03-14 20:37:09 +00:00
Kenneth Graunke
fa24ff24dd iris: Remove suballocation in iris_flush_resource()
pipe->flush_resource() is called from eglCreateImageKHR in order to
prepare images to be shared.  It also has a valid context.  We can
just remove suballocation there, rather than doing it on the first
dri_image_query like radeonsi does.

This is much simpler and seems to work fine.

Suggested-by: Michel Dänzer <mdaenzer@redhat.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13154>
2024-03-14 20:37:09 +00:00
Sviatoslav Peleshko
a330ecc48a dri: Flush the context after flush_resource when creating shareable image
This makes sure that we'll be done with any pending preparations before
the actual export of the resource.

Signed-off-by: Sviatoslav Peleshko <sviatoslav.peleshko@globallogic.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13154>
2024-03-14 20:37:09 +00:00
Nanley Chery
27d35588f5 iris: Copy main ISL surf when reallocating in place
When reallocating a resource in place, we make sure to pass the
PIPE_BIND_SHARED flag for the new resource. On ACM, this generally
changes the allocation of the resource from tiled to linear. To pick up
the new layout of the resource, copy the new ISL surf.

This enables ACM to pass piglit's egl-ext_egl_image_storage
test.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10367
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13154>
2024-03-14 20:37:09 +00:00
Valentine Burley
98690db847 tu: Reorder device features
Sort device features by KHR, EXT, vendor and then alphabetically within that.

Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28095>
2024-03-14 19:13:23 +00:00
Valentine Burley
1726e03df4 tu: Advertise VK_KHR_vertex_attribute_divisor
This is a promotion from the EXT, except the new property
supportsNonZeroFirstInstance which should already be supported.

Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28095>
2024-03-14 19:13:23 +00:00
Valentine Burley
355dd782c5 tu: Implement VK_KHR_map_memory2
Signed-off-by: Valentine Burley <valentine.burley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28080>
2024-03-14 18:50:19 +00:00
Corentin Noël
e7de9ab62a zink: Make sure to initialize all the fields of VkMemoryBarrier
Fixes several random validation errors as the value of dstAccessMask could be
anything.

Cc: mesa-stable
Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28166>
2024-03-14 18:29:14 +00:00
Danylo Piliaiev
2aab8e0806 meson: Correctly get sizeof_pointer with cross-compilers
"native : true" used build system's compiler to determine
sizeof void*, which is wrong - we need to use host compiler.

Found when using pure NIX cross-compilation environment.

Fixes: ad34c932cd
("glapi: pass pointer size to python for glthread from meson")

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.co
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28177>
2024-03-14 17:49:18 +00:00
Yonggang Luo
d2229304dc panfrost/meson: remove redundant gallium include from meson files
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24439>
2024-03-14 17:23:55 +00:00
Yonggang Luo
13ce0358b0 panfrost/shared: avoid use gallium helper in pan_minmax_cache.*
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24439>
2024-03-14 17:23:55 +00:00
Lionel Landwerlin
20df1d2b1f anv: ignore descriptor alignment for inline uniforms
For this particular case only it doesn't matter. Fixes some new CTS
tests with small inline uniform sizes.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Reviewed-by: Ivan Briano <ivan.briano@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28040>
2024-03-14 16:54:30 +00:00
Corentin Noël
812be09cd2 st_pbo/compute: Use the correct structure type when allocating a specialized key
Use pbo_spec_async_data instead of pbo_async_data.

Cc: mesa-stable
Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28173>
2024-03-14 16:18:13 +00:00
José Roberto de Souza
27ab5fcf9f anv: Set VM control to true in Xe KMD
Xe KMD needs VMs to be created to work.
Setting this on Xe KMD code path allow us to simply a feature check
in init_queue_families().

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28161>
2024-03-14 15:53:22 +00:00
José Roberto de Souza
c20388d617 anv: Set VK_QUEUE_PROTECTED_BIT during queue families initialization
Don't make sense to only set it in VkGetPhysicalDeviceQueueFamilyProperties2().
Not setting it to the code path without pdevice->engine_info because
the protected support landed on i915 after DRM_I915_QUERY_ENGINE_INFO.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28161>
2024-03-14 15:53:22 +00:00
José Roberto de Souza
9102cb972a anv: Replace the 2 sparse booleans by 1 enum
Having just one place to check the Sparse type is less error prone.
For example in i915 it was always setting sparse_uses_trtt to true
even if running in gfx 9 that don't support sparse.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28161>
2024-03-14 15:53:22 +00:00
Rhys Perry
ec892c4d2b aco: don't reuse misaligned attribute destination VGPRs in VS prologs
Since we split misaligned attributes, we could overwrite one of these
VGPRs in the middle of loading the attribute.

For example:
   v_add_u32_e32 v4, vcc, s7, v1
   s_waitcnt lgkmcnt(0)
   buffer_load_dword v4, v4, s[32:35], 0 idxen
   buffer_load_dword v5, v4, s[32:35], 0 idxen offset:4
can overwrite the vertex index in the load of the first component.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27920>
2024-03-14 15:30:12 +00:00
Rhys Perry
df7024bcdd radv,aco: allow VS prologs to increase VGPR usage
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27920>
2024-03-14 15:30:12 +00:00
Samuel Pitoiset
1a20942f6a radv: fix wave32 support with ESO
For example when RADV_PERFTEST=gewave32 is used, the vgt shader key
was incorrect.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28151>
2024-03-14 14:56:45 +00:00
Samuel Pitoiset
e1c73db01c radv: rework generating vgt_shader_key for pipelines
This new helper will also be used for ESO.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28151>
2024-03-14 14:56:45 +00:00
Samuel Pitoiset
c6485f560d radv: determine radv_vgt_shader_key::has_ngg_xxx with the last VGT shader
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28151>
2024-03-14 14:56:44 +00:00
Samuel Pitoiset
9ccbd459c6 radv: fix determining if PrimId is used for merged shaders compiled separately
For ESO when TES and GS are compiled separately,
BREAK_WAVE_AT_EOI/IA_SWITCH_ON_EOI must be enabled if the GS uses
PrimID.

This fixes
tests/spec/arb_tessellation_shader/execution/gs-primitiveid-instanced.shader_test
on RDNA2 when shader object is enabled with Zink.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28149>
2024-03-14 14:34:19 +00:00
Guilherme Gallo
e052e30b29 r300/ci: Update xfiles based on nightly run
Refer to:
- https://gitlab.freedesktop.org/mesa/mesa/-/pipelines/1125483
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164946

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28145>
2024-03-14 13:53:45 +00:00
Guilherme Gallo
3d45451fb4 etnaviv/ci: Update xfiles based on nightly run
Refer to:
- https://gitlab.freedesktop.org/mesa/mesa/-/pipelines/1125483

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28145>
2024-03-14 13:53:45 +00:00
Guilherme Gallo
7d9ba366d4 freedreno/ci: Update xfiles based on nightly run
Refer to:
- https://gitlab.freedesktop.org/mesa/mesa/-/pipelines/1125483
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164985
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164987
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164988
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164989
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164989
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164990
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164990

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28145>
2024-03-14 13:53:45 +00:00
Guilherme Gallo
c6b65ac639 v3d/ci: Update xfiles based on nightly run
Refer to:
- https://gitlab.freedesktop.org/mesa/mesa/-/pipelines/1125483
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164970

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28145>
2024-03-14 13:53:45 +00:00
Guilherme Gallo
4350c7cb30 radv/ci: Update xfiles based on nightly run
Refer to:
- https://gitlab.freedesktop.org/mesa/mesa/-/pipelines/1125483
- https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56167363

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28145>
2024-03-14 13:53:45 +00:00
Guilherme Gallo
697a5a7b91 radv+zink/ci: Update xfiles based on nightly run
Refer to: https://gitlab.freedesktop.org/mesa/mesa/-/jobs/56164998

Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28145>
2024-03-14 13:53:45 +00:00
Mike Blumenkrantz
0f5b0dbc25 zink: handle image_deref_samples when stripping MS image instrs
fixes #10812

Fixes: 660671d462b ("zink: add a pass to strip out multisample storage image ops")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28160>
2024-03-14 13:17:45 +00:00
Mike Blumenkrantz
b46479d443 zink: don't deref swapchain image array with UINT32_MAX
this indicates an unacquired swapchain

Fixes: 8fb83c0935 ("zink: only update swapchain readback cache on create if necessary")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28160>
2024-03-14 13:17:45 +00:00
Boris Brezillon
9f2b23dd85 panvk: Get rid of fields we already have in vk_xxx objects
There's no point adding our own pointer when the base vk_xxx object
already provides a way to get back to the parent. Replace those
fields by _get_xxx() helpers.

Signed-off-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/28104>
2024-03-14 11:32:39 +01:00
Boris Brezillon
d5ed77800e panvk: Fix GetPhysicalDeviceProperties2() to report accurate info
Fix GetPhysicalDeviceProperties2 to report accurate information, and
add comment explaining the reasoning behind the new limits.

While at it, stop using the MAX_xxx definitions since some of them
will be per-gen, and this file is not.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28104>
2024-03-14 11:32:33 +01:00
Boris Brezillon
783172add3 panvk: Make panvk_sampler inherit from vk_sampler
Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
203f1a35a7 panvk: Implement {Map,Unmap}Memory2KHR
The core provides wrappers for {Map,Unmpa}Memory().

Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
d9c0c728a2 panvk: Add extra checks to panvk_MapMemory()
While at it, add error messages to the existing error paths.

Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
88930cd95d panvk: Make pan_AllocateMemory() robust to errors
Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
db1fde16d7 panvk: Make panvk_device_memory inherit from vk_device_memory
Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
4dc5613be6 panvk: Make panvk_buffer_view inherit from vk_buffer_view
Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
567324749c panvk: Get rid of panvk_pipeline_cache
We use the vk runtime stubs.

Signed-off-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/28104>
2024-03-14 10:26:13 +01:00
Boris Brezillon
e7b68cdef1 panvk: Drop panvk_framebuffer
vk_framebuffer provides exactly the same thing, so let the core
implement the VkFramebuffer entry points for us.

Signed-off-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/28104>
2024-03-14 10:26:13 +01:00