Commit graph

46902 commits

Author SHA1 Message Date
Pierre-Eric Pelloux-Prayer
43438aa9c4 radeonsi: fix ac_create_shadowing_ib_preamble parameter
shadowing_preamble is a si_pm4_state but ac_pm4_cmd_add expects a
ac_pm4_state.

Fixes: 428601095c ("ac,radeonsi import PM4 state from RadeonSI")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29876>
2024-07-09 15:07:28 +02:00
Pierre-Eric Pelloux-Prayer
0a4f3d0b54 radeonsi/tests: correctly parse the family name
62a2ed8602 changed the format of GL_RENDERER and now the family name
is the 2nd word, not the first one.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29876>
2024-07-09 15:07:28 +02:00
Pierre-Eric Pelloux-Prayer
a7a1e3d329 radeonsi: fix crash in si_update_tess_io_layout_state for gfx8 and earlier
si_set_patch_vertices was only called if tcs.current was non-NULL but
this condition is not enough for GFX9+ since vs is used as ls.

Add a check in si_update_tess_io_layout_state instead, and set
sctx->do_update_shaders for case where the ls_current is not yet
available.
This fix crashes on GFX6.

Cc: mesa-stable
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29876>
2024-07-09 15:07:27 +02:00
Pierre-Eric Pelloux-Prayer
2021813450 Revert "ac, radeonsi: remove has_syncobj, has_fence_to_handle"
This reverts commit 02fe3c32cd.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11352
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29876>
2024-07-09 15:07:27 +02:00
Pierre-Eric Pelloux-Prayer
84a563cf6f radeonsi: fix buffer_size in si_compute_shorten_ubyte_buffer
buffer_size is not the full buffer size, but the part of the
buffer that is accessed by the compute shader.

This fixes the assert hit in si_set_shader_buffer.

Fixes: 1a99f50c7f ("radeonsi: use a compute shader to convert unsupported indices format")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29876>
2024-07-09 15:07:27 +02:00
Yogesh Mohan Marimuthu
47fb4b45f2 radeonsi: add more comments in si_query.c
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30052>
2024-07-08 17:51:25 +00:00
Yogesh Mohan Marimuthu
51885bba64 radeonsi: rename query_hw_ops to hw_query_ops match sw
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30052>
2024-07-08 17:51:25 +00:00
Yogesh Mohan Marimuthu
e00400e605 radeonsi: use reseults_end instead of unprepared to init query buffer
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30052>
2024-07-08 17:51:25 +00:00
Yogesh Mohan Marimuthu
068f631814 radeonsi: remove si_query_hw_ops table and call func directly
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30052>
2024-07-08 17:51:25 +00:00
Mike Blumenkrantz
a3c4d257a2 zink: don't lower fpow
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30070>
2024-07-08 16:35:21 +00:00
Erico Nunes
aa4d0836fe lima: fix surface reload flags assignment
These flags are set at the end of the job based on its buffer usage and
then checked by following jobs.
If an application toggles stencil and depth tests alternatigly in
a sequence of jobs while also relying on previous contents to render,
with the current assignment the reload flags for depth or stencil may
be cleared incorrectly and a depth/stencil buffer may not be properly
reloaded.

Cc: mesa-stable
Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30065>
2024-07-08 08:44:04 +00:00
Lucas Stach
f0c54e02cf etnaviv: always flush pending queries on get_query_result
This is basically a port from commit 591a3c738d ("freedreno: Be more
strict about QUERY_AVAILABLE to simplify the code.") to etnaviv.

perfmon queries already forced such a flush by setting no_wait_cnt
to a value above the flush threshold, now we unify the behavior between
occlusion and perfmon queries.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30055>
2024-07-08 08:11:47 +00:00
Eric Engestrom
801ed4d032 ci: simplify setting .no-auto-retry now that it isn't bundled with unrelated rules:
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30004>
2024-07-07 19:31:44 +00:00
Eric Engestrom
f37af2ab8c ci: split .no-auto-retry out of .scheduled_pipeline-rules
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30004>
2024-07-07 19:31:44 +00:00
Mike Blumenkrantz
158369c38a zink: enable compute pbos for turnip
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30026>
2024-07-05 12:05:32 +00:00
Konstantin Seurer
d571e19966 radv: Fix smooth lines with dynamic polygon mode and topology
Non-line modes need to disable the smoothing paths. (overrasterization,
shader code)

Fixes: 85cbdba ("radv: add support for smooth lines")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9393
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26833>
2024-07-05 08:58:53 +00:00
Mike Blumenkrantz
4576f440c3 zink: add an a750 skip
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30042>
2024-07-04 13:42:53 +00:00
David Rosca
28fdc4b372 gallium: Remove PIPE_VIDEO_CAP_EFC_SUPPORTED
Reviewed-by: Thong Thai <thong.thai@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29932>
2024-07-03 17:56:28 +00:00
David Rosca
40c3a53fec radeonsi: Implement is_video_target_buffer_supported
Check EFC supported formats and reject DCC.

Reviewed-by: Thong Thai <thong.thai@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29932>
2024-07-03 17:56:27 +00:00
Qiang Yu
8e146512d1 glsl: fix indirect tess factor access for compact_arrays=false drivers
Driver with compact_arrays=false (i.e. radeonsi) is broken when
tess factor is accessed indirectly, for example:
  gl_TessLevelOuter[gl_InvocationID] = xxx;

This fix use nir_vectorize_tess_levels to lower array tess factor
access into direct vector access before nir_lower_io() like clip
and cull distance way.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29799>
2024-07-03 02:06:56 +00:00
Ganesh Belgur Ramachandra
9c8dffd282 radeonsi: add GL_ARB_texture_filter_minmax extension
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29653>
2024-07-02 18:27:00 +00:00
Ganesh Belgur Ramachandra
1f9bafbc74 radeonsi: add GL_EXT_texture_filter_minmax extension
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29653>
2024-07-02 18:27:00 +00:00
Juan A. Suarez Romero
c157e8991e v3d: use original enabled_mask on setting vertex buffers
Current code uses a non-initialized enabled_mask to set the vertex
buffers mask, instead of using the original value from
`so->enabled_mask`

Let's use the original field instead of using an intermediate variable.

Fixes: cbcfb34cf7 ("v3d: use BITSET for the masks")
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/29987>
2024-07-02 07:20:47 +00:00
Mike Blumenkrantz
cb7b1a8d23 zink: remove adreno from broken_cache_semantics driver workaround
the proprietary driver was never affected by this, and turnip should
no longer be affected after some recent MRs

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29174>
2024-07-01 18:37:46 +00:00
Michel Dänzer
cbd19e09d1 dri: Go back to hard-coded list of RGBA formats
Catching these programmatically without false positives / negatives is
surprisingly tricky, go back to the known-working list for now.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11398
Fixes: ad0edea53a ("st/dri: Check format properties from format helpers")
Fixes: 5ca85d75c0 ("dri: Fix BGR format exclusion")

v2:
* Also put back lima fails removed by 9eeaa4618f ("egl/gbm: Enable
  RGBA configs"), as those tests are now failing again.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29979>
2024-07-01 15:42:58 +00:00
Mike Blumenkrantz
a7f86e38ca zink: free sparse page for miptail on uncommit
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29818>
2024-07-01 14:24:57 +00:00
Juan A. Suarez Romero
feaa5ce1ec vc4: fix out-of-bounds access to array
Detected by by Undefined Behaviour Sanitizer (UBSan), this fixes trying
to access index 5 in `util_format_channel_description`, which is
declared of size 4.

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/29911>
2024-07-01 08:02:07 +00:00
Juan A. Suarez Romero
b827aee3a3 vc4: do not create 0-bytes variable length arrays
When declaring an array with variable length, like `nir_variable
*vars[num_entries]`, ensure the length is always greater than 0

This has been detected by Undefined Behaviour Sanitizer (UBSan).

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/29911>
2024-07-01 08:02:07 +00:00
Juan A. Suarez Romero
2a16575dec vc4: do not pass NULL pointer to function not expecting NULLs
memcmp() pointers arguments are declared to be non NULL.

This has been detected by Undefined Behaviour Sanitizer (UBSan).

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/29911>
2024-07-01 08:02:07 +00:00
Juan A. Suarez Romero
eab3ee8d71 vc4: do not access member of a NULL structure
Check if the structure is NULL before trying to get access to its
members.

This has been detected by the Undefined Behaviour Sanitizer (UBSan).

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/29911>
2024-07-01 08:02:07 +00:00
Juan A. Suarez Romero
5e09b2b3f3 vc4: use unsigned types when performing bitshifting
Ensure unsigned integers of proper size are used instead of signed ones
when performing left bit shifts.

This has been detected by the Undefined Behaviour Sanitizer (UBSan).

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/29911>
2024-07-01 08:02:07 +00:00
Juan A. Suarez Romero
1bcf9c5da9 v3d: do not pass NULL pointer to function not expecting NULLs
memcpy() pointers arguments are declared to be non NULL.

This has been detected by Undefined Behaviour Sanitizer (UBSan).

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/29911>
2024-07-01 08:02:07 +00:00
Juan A. Suarez Romero
417f70ef5a v3d: do not access member of a NULL structure
Check if the structure is NULL before trying to get access to its
members.

This has been detected by the Undefined Behaviour Sanitizer (UBSan).

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/29911>
2024-07-01 08:02:07 +00:00
David Heidelberg
68215332a8 build: pass licensing information in SPDX form
Acked-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Acked-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric@igalia.com>
Acked-by: Daniel Stone <daniels@collabora.com>
Signed-off-by: David Heidelberg <david@ixit.cz>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29972>
2024-06-29 12:42:49 -07:00
Jesse Natalie
13d11ab442 zink: Add ASSERTED to assert-only local variable
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29970>
2024-06-28 20:44:36 +00:00
Neha Bhende
8b8f347e4b svga: Retrieve stride info from hwtnl->cmd.vdecl for swtnl draws
This fixes spec@!opengl 1.0@gl-1.0-polygon-line-aa
spec@!opengl 1.1@clipflat and multiple piglit tests
failures on VGPU9 device

Fixes: 76725452 ("gallium: move vertex stride to CSO")

Reviewed-by: Brian Paul <brian.paul@broadcom.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29947>
2024-06-28 19:24:46 +00:00
Rémi Bernon
f9a15b37ef zink: Add VKAPI_PTR specifier to generated stub functions.
Same as 8d210ae232 but for when NDEBUG
isn't defined.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29863>
2024-06-28 18:15:34 +00:00
Mike Blumenkrantz
6466a977e4 zink: add a driver workaround to disable 2D_VIEW_COMPATIBLE+sparse
this fixes a lot of stuff on intel and hopefully never hits any corner
case app use

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29197>
2024-06-28 17:44:00 +00:00
Jesse Natalie
e8ab5e4320 d3d12: Use GetResourceAllocationInfo instead of GetCopyableFootprints for residency sizes
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29967>
2024-06-28 17:21:52 +00:00
José Expósito
1ef3b38ff8 llvmpipe: Init eglQueryDmaBufModifiersEXT num_modifiers
Initialize the number of modifiers when `max` is 0 as documented [1]:

  If <max_formats> is 0, no formats are returned, but the total number
  of formats is returned in <num_formats>, and no error is generated.

[1] https://registry.khronos.org/EGL/extensions/EXT/EGL_EXT_image_dma_buf_import_modifiers.txt

Fixes: d74ea2c117 ("llvmpipe: Implement dmabuf handling")
Reported-by: Michal Odehnal <modehnal@redhat.com>
Tested-by: Michal Odehnal <modehnal@redhat.com>
Reviewed-by: Lucas Fryzek <lfryzek@igalia.com>
Signed-off-by: José Expósito <jexposit@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29941>
2024-06-28 16:57:26 +00:00
Karol Herbst
646a0ea576 meson: rename with_gallium_opencl to with_gallium_clover
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29646>
2024-06-27 20:50:32 +00:00
Eric Engestrom
959d38099f llvmpipe,rusticl/ci: move rusticl files rule out of llvmpipe
With the next commit, llvmpipe will no longer be the only driver to test rusticl.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29851>
2024-06-27 17:49:02 +00:00
Eric Engestrom
b2a025f9a2 llvmpipe/ci: set rusticl variables in deqp-runner instead of passing them down from the job
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29851>
2024-06-27 17:49:02 +00:00
Eric Engestrom
5b3782a5ab llvmpipe/ci: fix indentation of list nested in a dict item
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29851>
2024-06-27 17:49:01 +00:00
Eric Engestrom
3d09f93287 llvmpipe/ci: add comment for later on weird-looking code
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29851>
2024-06-27 17:49:01 +00:00
Boris Brezillon
8293376f7c pan/blitter: Let pan_preload_fb() callers queue the jobs to the job chain
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/29450>
2024-06-27 10:57:38 +00:00
Boris Brezillon
629b9258df pan/desc: Prepare things for fragment job chaining
Right now we assume the fragment job chain contains only one job, but
with multilayer/multiview rendering, we want to submit fragment jobs
for all layers at once.

Turn pan_emit_fragment_job() into pan_emit_fragment_job_payload() and
delegate the job header packing to the caller.

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/29450>
2024-06-27 10:57:38 +00:00
Boris Brezillon
c694556657 pan/desc: Extend pan_emit_fbd() to support multilayer rendering
Right now, we always emit a framebuffer descriptor for the first layer
in the RT views. Extend the logic so we can emit one FBD per layer we're
supposed to render to without having to manually modify the RT views.

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/29450>
2024-06-27 10:57:38 +00:00
Konstantin Seurer
6168317b84 lavapipe: Implement shaderResourceResidency
Adds a bit set to llvmpipe_resurce where each bit stores the residency
of a 64KB tile. The sampling code is adjusted to make use of said table
and return a residency code for sparse texture operations.

Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29408>
2024-06-27 09:29:34 +00:00
Konstantin Seurer
d747c4a874 lavapipe: Implement sparse buffers and images
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29408>
2024-06-27 09:29:34 +00:00