Commit graph

180808 commits

Author SHA1 Message Date
Erik Faye-Lund
a08d33abff docs: apply permanent redirect
The HTTP URL now redirects to the HTTPS URL, so let's update our link.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26222>
2023-11-16 20:30:08 +00:00
José Roberto de Souza
014e51251e intel: Sync xe_drm.h
Sync xe_drm.h with commit 6253cfa4c324 ("drm/xe/pmu: Drop interrupt pmu event").
No changes in code need, it is just removing uAPIs that are not used
by any UMD but it still breaks the uAPIs as uAPI numbers changed.

Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Reviewed-by: Rohan Garg <rohan.garg@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26151>
2023-11-16 19:54:44 +00:00
Tatsuyuki Ishi
e1cf75b411 zink: Remove now unused dead_framebuffers.
These were deleted in fe8212791f ("zink: delete all non-imageless
framebuffer code").

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26168>
2023-11-16 17:40:14 +00:00
José Expósito
2a71f06f29 zink: allow software rendering only if selected
In environments where 3D acceleration is not available, like in a VM,
the behavior before commit 8cd44b8843 ("egl: add automatic zink
fallback loading between hw and sw drivers") was to fallback to swrast.

This was the output of `eglinfo` in that situation:

    $ eglinfo
    [...]
    Wayland platform:
    EGL driver name: swrast
    OpenGL core profile renderer: llvmpipe (LLVM 17.0.4, 256 bits)

However, after commit 8cd44b8843 ("egl: add automatic zink fallback
loading between hw and sw drivers") Zink support is tested before
falling back to swrast.
Since the system doesn't support 3D acceleration, Zink + software
rendering is used instead of swrast causing issues like the ones
described in #10146.

In this case, `eglinfo` prints:

    $ eglinfo
    [...]
    Wayland platform:
    EGL driver name: zink
    OpenGL core profile renderer: zink Vulkan 1.3(llvmpipe (LLVM 17.0.4,
    256 bits) (MESA_LLVMPIPE))

This patch ensures that Zink + software rendering is used only when the
user opts-in by setting `LIBGL_ALWAYS_SOFTWARE` or `D3D_ALWAYS_SOFTWARE`
and swrast is used otherwise.

After the patch, the output of `eglinfo` is identical to the one before
the regression:

    $ eglinfo
    [...]
    Wayland platform:
    EGL driver name: swrast
    OpenGL core profile renderer: llvmpipe (LLVM 17.0.4, 256 bits)

Resolves: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10146
Fixes: 8cd44b8843 ("egl: add automatic zink fallback loading between
hw and sw drivers")

Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
Signed-off-by: José Expósito <jexposit@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26220>
2023-11-16 17:18:34 +00:00
Eric Engestrom
99fed1f9b3 lima: drop unused lima_get_absolute_timeout()
If someone wants that functionality in the future, use
`os_time_get_absolute_timeout()` instead.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26229>
2023-11-16 16:52:10 +00:00
Eric Engestrom
9c62aee027 util/xmlconfig: drop default SYSCONFDIR & DATADIR values
The only build system left is meson, which always defines these.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26228>
2023-11-16 15:55:02 +00:00
Robert Mader
5f4253e096 panfrost: Support parameter queries for main planes
In order to return correct offsets, strides and possibly other
parameters. This is relevant for formats like NV12 and P010 where
the second plane, when produced by the V4L2 decoder, uses the
same FD like the first one, but with an offset.

Analogous to 7a7e577d.

Also use the new helper to get the number of planes.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10094
Cc: mesa-stable
Reviewed-by: Italo Nicola <italonicola@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26109>
2023-11-16 14:28:45 +00:00
Robert Mader
d679154dc0 util: Add new helpers for pipe resources
They will be handy for drivers supporting multi-planar formats.

Cc: mesa-stable
Reviewed-by: Italo Nicola <italonicola@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26109>
2023-11-16 14:28:45 +00:00
Tatsuyuki Ishi
94e867e4a6 zink: Fix waiting for texture commit semaphores.
The commit was always being treated as failed...

Fixes: d1456a6b0a ("zink: add semaphore handling for sparse binds")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26171>
2023-11-16 13:38:07 +00:00
Tatsuyuki Ishi
729ce08815 zink: Defer freeing sparse backing buffers.
Sparse backing buffers were destroyed immediately after issuing the
unbind call, which was against the Vulkan spec which requires the
destroy call to not happen before the unbind semaphore was signaled.

To tackle this, keep a reference against buffers we are unbinding within
the batch. This will keep the backing buffer long enough to not cause
use-after-free. As described in comments, we don't need to reference
every backing page used in the batch, as the resource usually keeps
references to them until they are unbound, which is now correctly
handled.

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26171>
2023-11-16 13:38:06 +00:00
Tatsuyuki Ishi
3ee283e455 zink: Fix missing sparse buffer bind synchronization.
goto oopsies.

Fixes: d1456a6b0a ("zink: add semaphore handling for sparse binds")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26171>
2023-11-16 13:38:06 +00:00
Lionel Landwerlin
8b36d230bb anv: workaround XeSS for Satisfactory
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10152
Acked-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26217>
2023-11-16 13:08:01 +00:00
José Expósito
83ed419cd0 zink: fix dereference before NULL check
The `sv->image_view` pointer is dereference before checking whether it's
NULL or not.
Check for NULL before dereferencing it to avoid a possible crash.

Fixes: 9de455bc43 ("zink: check for sampler view existence during
zink_rebind_all_images()")

Reviewed-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: José Expósito <jexposit@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26140>
2023-11-16 12:22:14 +00:00
Samuel Pitoiset
ec82b42944 radv: add a missing async compute workaround for Tonga/Iceland
After digging into PAL code again, I figured that Tonga/Iceland are
both affected by a hw bug related to async compute dispatches.

The solution is to change the "threadgroup" dimension mode to the
"thread" dimension mode unconditionally.

This should fix a bunch of issues related to RADV_DEBUG=nocompute on
these GPUs.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/7551
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6334
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/4679
Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26207>
2023-11-16 11:37:43 +00:00
Rhys Perry
f695a9fed2 intel/compiler: use nir_lower_fp16_casts
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Ivan Briano <ivan.briano@intel.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25566>
2023-11-16 11:02:31 +00:00
Rhys Perry
ae30edd2a7 aco: remove f16<->f64 conversions
radeonsi and RADV now use nir_lower_fp16_casts.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25566>
2023-11-16 11:02:31 +00:00
Rhys Perry
a31c928c4f radv: use nir_lower_fp16_casts
This correctly implements RTNE f64->f16.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25566>
2023-11-16 11:02:30 +00:00
Rhys Perry
0e1e6c244b radeonsi: use nir_lower_fp16_casts
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25566>
2023-11-16 11:02:30 +00:00
Rhys Perry
288e9db053 nir/lower_fp16_casts: add option to split fp64 casts
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Ivan Briano <ivan.briano@intel.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25566>
2023-11-16 11:02:30 +00:00
Rhys Perry
fce434818a nir/lower_fp16_casts: correctly round RTNE f64->f16 casts
Based on brw_nir_lower_conversions.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Ivan Briano <ivan.briano@intel.com>
Reviewed-by: Georg Lehmann <dadschoorse@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25566>
2023-11-16 11:02:30 +00:00
Samuel Pitoiset
4239e13ff6 radv: fix a descriptor leak with debug names and host base descriptor set
vk_object_base_finish() needs to be called on the descriptor set in
order to free the debug names.

Cc: mesa-stable
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10098
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26088>
2023-11-16 09:11:06 +00:00
Vinson Lee
904015ae85 ac/surface/tests: Remove duplicate variable block_size_bits
Fix defect reported by Coverity Scan.

Evaluation order violation (EVALUATION_ORDER)
write_write_typo: In block_size_bits = block_size_bits = ((surf.u.gfx9.swizzle_mode >= ADDR_SW_256KB_Z_X) ? 18 : 16),
block_size_bits is written twice with the same value.

Fixes: 44eaf50a34 ("ac/surface/tests: cosmetic changes")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26160>
2023-11-15 19:22:06 -08:00
Juston Li
49e5b58315 venus: enable VK_EXT_extended_dynamic_state3
Signed-off-by: Juston Li <justonli@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25921>
2023-11-15 23:30:14 +00:00
Juston Li
417437c715 venus: pipeline fixes for VK_EXT_extended_dynamic_state3
- pMultisampleState->pSampleMask should be ignored when
VK_DYNAMIC_STATE_SAMPLE_MASK_EXT is used.
- pRasterizationState can be null now

Signed-off-by: Juston Li <justonli@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25921>
2023-11-15 23:30:14 +00:00
Juston Li
e3de4a9852 venus: sync protocol for VK_EXT_extended_dynamic_state3
Signed-off-by: Juston Li <justonli@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25921>
2023-11-15 23:30:14 +00:00
Eric Engestrom
d5efa3f204 docs: update calendar for 23.3.0-rc{2,3,4} and add another release candidate
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26215>
2023-11-15 21:40:21 +00:00
Chia-I Wu
c905aeb4e4 ac: be careful with stencil_offset override
Check surf->has_stencil first to avoid trashing surf->u.gfx9.color.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26106>
2023-11-15 20:29:03 +00:00
Chia-I Wu
7718bad474 radv: minor clean up to image view extent override
Use the correct image plane consistently.  Compressed formats are
single-planar unless emulated.  This makes no difference in either case
but makes the code more concise.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26106>
2023-11-15 20:29:03 +00:00
Chia-I Wu
2533d0a0e2 radv: fix image view extent override for astc
When doing ASTC decoding, the image has format VK_FORMAT_ASTC_*, the
internal plane 1 has format VK_FORMAT_R8G8B8A8_UNORM, and the view has
format VK_FORMAT_R8G8B8A8_UINT.  It does not need the override for
compressed formats.

Fixes: f97b449e9e ("radv: integrate meta astc compute decoder to radv")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26106>
2023-11-15 20:29:03 +00:00
Lionel Landwerlin
295734bf88 intel/fs: fix residency handling on Xe2
We're missing a few reg_unit() scaling when dealing with residency data.

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Rohan Garg <rohan.garg@intel.com>
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26208>
2023-11-15 20:06:12 +00:00
Faith Ekstrand
0bd23d6263 nak: Enable SM70 for Volta
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26212>
2023-11-15 13:38:04 -06:00
Tapani Pälli
01046cd6ad anv/drirc: add option to disable FCV optimization
There are rendering issues with FCV on DG2 and Unreal engine 5.1,
patch adds option to disable fcv in drirc.

Cc: mesa-stable
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Rohan Garg <rohan.garg@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26169>
2023-11-15 18:16:56 +00:00
M Henning
aedf9113c4 nak: Set "evict first" from ACCESS_NON_TEMPORAL
This matches the way ptxas sets this hint.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26201>
2023-11-15 17:48:29 +00:00
M Henning
adc3fd4c99 nak: Add encodings for cache eviction priorities
We were previously setting "evict first" everywhere, which could
possibly be a perf issue on machines that are also running shaders
compiled with codegen, which sets "evict normal" on everything.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26201>
2023-11-15 17:48:29 +00:00
David Rosca
df9a95a813 gallium/auxiliary/vl: NIR compute shaders
Remove drawn area check and instead adjust grid layout so that this check
is not needed.
Change crop_x/crop_y from int to float to avoid converting it in shaders,
also all shaders now supports cropping.

Acked-by: Thong Thai <thong.thai@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25562>
2023-11-15 16:06:38 +00:00
David Rosca
848811f98a gallium/auxiliary: NIR blit_compute_shader
Acked-by: Thong Thai <thong.thai@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25562>
2023-11-15 16:06:37 +00:00
Friedrich Vock
03a7cb2618 ac/gpu_info: Manually compute L3 size for Navi33
The firmware reports no MALL cache being present, which is wrong. We
later depend on correct L3 cache size values for choosing the attribute
ring size, so fall back to manually computing the size.

Fixes: 355242f055 ("ac/gpu_info: adjust attribute ring size for gfx11")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26147>
2023-11-15 14:09:50 +00:00
Konstantin Seurer
90f8cf0f36 radv/sqtt: Handle monolithic RT pipelines
This marks them as Unified in the RGP UI and shows the compute shader
view.

Reviewed-by: Friedrich Vock <friedrich.vock@gmx.de>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26158>
2023-11-15 13:46:50 +00:00
Konstantin Seurer
b6e09dd521 radv/sqtt: Fix tracing acceleration structure commands
ApiRayTracingSeparateCompiled can only used by trace commands.

Fixes: bfb55d0 ("ac/sqtt,radv/sqtt: Add and use marker for separate RT compilation")
Reviewed-by: Friedrich Vock <friedrich.vock@gmx.de>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26158>
2023-11-15 13:46:50 +00:00
Mark Collins
fa0476fa6e meson: Update lua wrap to 5.4.6-4
This version of the lua wrap fixes installation of the library which
was previously causing liblua SOs to be missing when Mesa was installed
using `meson install`.

Signed-off-by: Mark Collins <pixelyion@protonmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26185>
2023-11-15 13:29:20 +00:00
David Heidelberg
1eff68dd2a ci/traces: drop the freedoom-phase2-gl-high.trace
See https://gitlab.freedesktop.org/mesa/mesa/-/issues/8080#note_2154467

Fixes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8080
Cc: mesa-stable
Signed-off-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26199>
2023-11-15 12:56:01 +00:00
Georg Lehmann
b12d7f10d4 aco: validate ALU operands and defs
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
91539713bb aco: add src/def count and size for all ALU opcodes
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
d9c3ba3b90 aco: use correct operand size for int tg4 wa
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
1d167d187e aco/gfx10+: don't use v_cmpx with VCC def
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
509ce19643 aco: add missing scc def for SALU quad broadcast
Cc: mesa-stable

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
18f6c2328f aco: use lm for carry out in vsub32
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
9acd9c0100 aco/tests: use correct operand size for some 64bit ops
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
6a136b4e05 aco/tests: add some missing scc defs
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00
Georg Lehmann
2f4e53b22a aco: fix detecting sgprs read by SMEM hazard
s_waitcnt_lgkmcnt is SOPK, not SOPP and there are other SOPK instructions
that don't mitigate the hazard.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26163>
2023-11-15 12:35:32 +00:00