Commit graph

201327 commits

Author SHA1 Message Date
Eric Engestrom
a37d5dcd63 radv/ci: use deqp-vk-main in radv jobs
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
596c58b582 ci: bump image tags
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
beab815670 ci/deqp: add a deqp-vk build on the main branch
To be able to run new tests as soon as they are merged, instead of
having to wait for the next official CTS release

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
328a3de7cc ci/lava: turn the $BUILD_VK check into a proper if block
Allows us to simply add something in the block in the next commit.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
ec27d138cb ci/deqp: only print the commit list header when the list is not empty
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
044cab6751 ci/deqp: mention the deqp api in the version string
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
ffb6c3e1de ci/deqp: simplify generating the version description file
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
72a2b92e3e ci/deqp: support having commit backports and local patches for main too
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
1634ad2782 ci/deqp: fix the "is this a build on main?" check
Suggested-by: Antonio Ospite
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Eric Engestrom
601088aebb ci/deqp: simplify paths since we are already in /deqp-$deqp_api/
Some commands used relative paths, while most used complex absolute
paths; let's just avoid unnecessary complexity.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Antonio Ospite
3bdb77e378 ci/deqp: replace local android patches with upstream solution
In commit a34982063 (Support standalone executable builds on Android,
2024-09-12) upstream VK-GL-CTS added support for building deqp as an
executable command for Android, this change is included in the vulkan
branch used by build-deqp.sh so the custom patches can be dropped for
the Vulkan CTS build.

After that and by passing -DDEQP_ANDROID_EXE=ON deqp can now be built
with DEQP_API=tools.

[Eric]
Note that the upstream solution seems to be broken on EGL, so GL & GLES
continue to use the local android patches; for more details, see:
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168#note_2676128

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28168>
2024-11-27 20:38:05 +00:00
Alyssa Rosenzweig
c2973765e2 nir: add nir_lower_constant_to_temp helper
this comes up with clc.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
12cc22af4c nir: add nir_remove_entrypoints helper
opposite of nir_remove_non_entrypoint. this operation comes up with
precompiling.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
c076900360 nir: add nir_function::pass_flags
convenience, asahi will stash stuff here.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
7d6e923a4f vtn: gather workgroup size in libraries
we have multiple kernels. that's fine, gather sizes for each.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
9c37745f9d vtn: plumb through OpEntryPoint
mark nir_functions as entrypoints according to the source.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
5555769102 nir: add workgroup size to functions
for cl kernel libraries with many entrypoints. spirv can represent, nir should
be able to as well.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
ba30eb9f40 nir: add nir_foreach_entrypoint macros
for compiling libraries full of kernels.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer@gmail.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:05 +00:00
Alyssa Rosenzweig
83581b3f1f asahi/clc: switch to nir_lower_calls_to_builtins
common code has a generic version, so we don't need to handroll this.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:04 +00:00
Alyssa Rosenzweig
d8ece9bf3a nir: add nir_lower_calls_to_builtins pass
nir_builder for the GPU

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32382>
2024-11-27 20:02:04 +00:00
Pierre-Eric Pelloux-Prayer
879e8bfe6d radeonsi: use bytes units in streamout
GFX10.3 and earlier were configured to count the number of dwords written,
and VGT_STRMOUT_DRAW_OPAQUE_VERTEX_STRIDE was also configured in dw units.

GFX11+ on the other hand used nir code that would use bytes.

This commit aligns radeonsi's logic on the radv's one, and use STRMOUT_DATA_TYPE
to configure older chips to use bytes as well.

This fixes GTF-GL46.gtf40.GL3Tests.transform_feedback2.transform_feedback2_two_buffers.

It also seems to have an effect on:
  - dEQP-GLES3.functional.transform_feedback.random.separate.*
  - dEQP-GLES3.functional.transform_feedback.random_full_array_capture.separate.*
but the results seem flaky so need further investigation.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32281>
2024-11-27 19:00:20 +00:00
Pierre-Eric Pelloux-Prayer
272addc672 ac/nir: remove prim_stride_ret arg from ngg_build_streamout_buffer_info
This is not used outside of this function, so declare it as a local
variable instead.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32281>
2024-11-27 19:00:20 +00:00
Pierre-Eric Pelloux-Prayer
9f4ab06842 glx: return BadMatch for invalid reset notification strategy
The specification doesn't say which error should be reported, but
piglit expects BadMatch:

   /* The GLX_ARB_create_context_robustness spec does not say what error
    * code should be generated.  However, similar cases (e.g., valid GL
    * versions) specify BadMatch.  This is also the behavior of NVIDIA's
    * closed-source driver.
    */

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32281>
2024-11-27 19:00:20 +00:00
Pierre-Eric Pelloux-Prayer
d3798130ad radeonsi: disable DCC for PIPE_BIND_USE_FRONT_RENDERING
Front rendering and (display) DCC are causing artifacts on screen.

si_texture_get_handle deals with this problem by disabling dcc, but
we can make it simpler by not allocating DCC at all when this flag
is set.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32281>
2024-11-27 19:00:20 +00:00
Pierre-Eric Pelloux-Prayer
666a6eb871 radeonsi/gfx12: disable display dcc for front buffer rendering
Same logic as other chips, except we need to reallocate the texture
as we can't disable dcc.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32281>
2024-11-27 19:00:20 +00:00
Pierre-Eric Pelloux-Prayer
df7bb6bfd2 dri: Remove unused function
This function is unused so get rid of it.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32281>
2024-11-27 19:00:20 +00:00
Zan Dobersek
be9f2e5189 tu/a7xx: support 8x MSAA
a7xx hardware has 8x MSAA capabilities we can expose. The 8-bit sample
count flag is included in the supported sample counts when computing image
format properties for MSAA-capable image creation conditions, with the
exception of 128-bit formats that don't support 8x MSAA.

UBWC blocksize logic is updated to cover cases of 16-bit and 32-bit formats
that support 8x MSAA. The per-cpp blocksize array is adjusted to also cover
128-byte values for which UBWC has to be disabled anyway.

VK_EXT_sample_locations implementation is adjusted to support sampling in
up to 8 locations, achieved by writing into additional sample location
registers.

Signed-off-by: Zan Dobersek <zdobersek@igalia.com>
Reviewed-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32180>
2024-11-27 17:26:02 +00:00
Lionel Landwerlin
292c6a5156 anv: avoid using cmd_buffer for flushing runtime
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32372>
2024-11-27 16:51:57 +00:00
Lionel Landwerlin
ce4f884fcc anv: avoid using cmd_buffer for TBIMR state computation
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32372>
2024-11-27 16:51:57 +00:00
Lionel Landwerlin
6096586893 anv: rework Wa_18038825448 to track state on anv_gfx_dynamic_state
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32372>
2024-11-27 16:51:57 +00:00
Lionel Landwerlin
337763f461 anv: reuse device local variable in hw state emission
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32372>
2024-11-27 16:51:57 +00:00
Lionel Landwerlin
fc404c962c anv: try to avoid using cmd_buffer in gfx runtime flushing
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32372>
2024-11-27 16:51:57 +00:00
Lionel Landwerlin
560ce4ba1d anv: move primitive_topology to anv_gfx_dynamic_state
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32372>
2024-11-27 16:51:57 +00:00
Georg Lehmann
fd669fa69d aco/optimizer: label fcanonicalize like a copy if there is nothing to flush
Allows copy propagation into non alu instructions like phis.

Foz-DB Navi21:
Totals from 138 (0.17% of 79395) affected shaders:
Instrs: 308135 -> 307792 (-0.11%); split: -0.12%, +0.01%
CodeSize: 1567924 -> 1566484 (-0.09%); split: -0.10%, +0.01%
VGPRs: 9696 -> 9720 (+0.25%)
Latency: 1162719 -> 1161663 (-0.09%); split: -0.10%, +0.00%
InvThroughput: 256944 -> 256590 (-0.14%); split: -0.15%, +0.01%
VClause: 5631 -> 5626 (-0.09%); split: -0.14%, +0.05%
Copies: 29962 -> 30028 (+0.22%); split: -0.10%, +0.32%
Branches: 8241 -> 8237 (-0.05%)
PreVGPRs: 7800 -> 7797 (-0.04%)
VALU: 216243 -> 215898 (-0.16%); split: -0.17%, +0.01%
SALU: 30768 -> 30767 (-0.00%)

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32355>
2024-11-27 15:14:31 +00:00
Konstantin
8197d744f5 radv: Do not overwrite VRS rates when doing fast clears
Fixes a whole bunch of VRS tests on navi24.

cc: mesa-stable

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32318>
2024-11-27 14:45:31 +00:00
Konstantin
1a3f6c586c radv/printf: Guard against helper invocations
Helper invocations can allocate printf buffer space but they do not
write any data which can cause crashes in radv_dump_printf_data.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32318>
2024-11-27 14:45:31 +00:00
Eric R. Smith
5bc4d33fa5 panvk: fix depth bias calculation
We don't need to multiply the depth bias constant by 2.0. This brings
panvk in line with other vulkan implementations (like asahi and nvk)
and fixes the one failing CTS test while still passing the other
CTS depth_bias tests.

Signed-off-by: Eric R. Smith <eric.smith@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32358>
2024-11-27 13:22:02 +00:00
Mary Guillemard
e1a8fd80d4 panvk: Use vk_zalloc for queue array allocation
No need to call memset that way.

Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32368>
2024-11-27 09:42:03 +01:00
Mary Guillemard
e5877cefc4 panvk: Call vk_free on queue array instead of vk_object_free
This is allocated using vk_alloc and isn't a vk_object.
This fixes an invalid free that could manifest as a double free error.

Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com>
Fixes: 5b0ff2643f ("panvk: Make the device creation/destruction per-arch")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32368>
2024-11-27 09:41:58 +01:00
Samuel Pitoiset
4308668a25 radv: allow shaders caching with RADV_DEBUG=hang and the trap handler
When debugging a game that compiles a ton of shaders at beginning, it
can be very very slow because shaders cache was disabled by default
with RADV_DEBUG=hang.

To make debugging such a game faster, let's cache shaders with
RADV_DEBUG=hang. Note that only the backend IR (ACO or LLVM) and the
disassembly are stored in the cache. To get SPIR-V and NIR, you might
need RADV_DEBUG=hang,nocache.

This also handles the trap handler.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32246>
2024-11-27 08:04:59 +00:00
Samuel Pitoiset
f1d103f7de radv: capture shader executable info at shader creation time
This doesn't need to be delayed and it will allow us to support
caching with eg. RADV_DEBUG=hang.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32246>
2024-11-27 08:04:59 +00:00
Samuel Pitoiset
acc84133f1 radv: only pass relevant stages when emitting DGC push constants
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32346>
2024-11-27 07:35:40 +00:00
Vignesh Raman
aa8cd5ea7b ci: Uprev crosvm
With Linux kernel 6.12-rc2, crosvm crashes in drm-ci
with the following error,
[ERROR crosvm::sys::linux::panic_hook] thread 'crosvm_vcpu0' panicked at devices/src/virtio/gpu/mod.rs:1761:14:
[ERROR crosvm::sys::linux::panic_hook] failed to send activation resources to worker thread: SendError { .. }

Uprev crosvm to fix this issue.

Signed-off-by: Vignesh Raman <vignesh.raman@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31900>
2024-11-27 03:07:02 +00:00
Mauro Rossi
b192c6927b nvk/android: Add support for ANDROID_native_buffer
ANB implementation aims to rely as much as possible on 'ANB common' code in vulkan/runtime
and vk_common_* entry points automatically handled by mesa at build time.

(v1) Initial Vulkan HAL skeleton with vk_android_{init,destroy}_ugralloc() in nvk_open_hal()

Changelog:

nvk_android.{c,h}: skeleton nvk_open_hal()/nvk_close_hal() and meson.build changes
nvk_instance.h: nvk_*() functions declaration required by nvk_android.c
nvk_device.c: add ANB support
nvk_image.c: add ANB code paths
nvk_physical_device.c: enable ANB extension support

NOTE: Avoid including any AHB code/headers <vndk/hardware_buffer.h>
use only <vulkan/vk_android_native_buffer.h>

Achievements:

Vulkan HAL is detected by Android build, but no Vulkan application is rendering
Android libvulkan.so loader performs dlopen() of /vendor/lib64/hw/vulkan.nouveau.so
Sascha Willems vulkanCapsViewer App detects the Vulkan HAL in Android builds on RTX2060
Android CTS 11 dEQP-VK can be run and completed, but com.drawelements.deqp app shows black surface

dEQP Test Results:

Module		Passed	Failed	Total
dEQP-VK		568738	   161	568899

(v2) Further replication of other using 'ANB common' implementation

Changelog:

Move vk_android_{init,destroy}_ugralloc() from nvk_open_hal() to nvk_CreateInstance()
Remove nvk_GetPhysicalDeviceProperties2() and rely on vk_common_GetPhysicalDeviceProperties2()

Achievements:

Improvements in dEQP-VK test results, but many dEQP.wsi.android.* tests are still failing

dEQP Test Results:

Module		Passed	Failed	Total
dEQP-VK		568783	   115	568899

(v3) Get inspiration from lavapipe recent llvmpipe ANB implementation and cleanups

nvk_physical_device.c: brace nvk_init_wsi,nvk_finish_wsi with #ifdef NVK_USE_WSI_PLATFORM/#endif
nvk_image.c: if (!mem) return VK_SUCCESS in DETECT_OS_ANDROID path
nvk_android.h: remove nvk_ahb_format_for_vk_format() and add vk_format_from_android()

Achievements:

Improvement in dEQP.wsi.android.* test results, only dEQP.wsi.android.swapchain.simulae_oom.* are failing.
Most of Vulkan Apps generate these errors in logcat:
... E BufferQueueConsumer: [tech.incr.vulkanandroid/tech.incr.vulkanandroid.MinimalNativeActivity#0](id:85900000010,api:1,p:5060,c:2137) acquireBuffer: max acquired buffer count reached: 2 (max 1)
... E BufferLayerConsumer: [tech.incr.vulkanandroid/tech.incr.vulkanandroid.MinimalNativeActivity#0] updateTexImage: acquire failed: Function not implemented (-38)
while some other apps (vkCube and GearsVK) generate these errors:
... E RenderEngine: failed to wait on fence fd
... E Layer   : [Surface(name=Task=136)/@0x832783c - animation-leash#0] No local sync point found
... E Layer   : [Surface(name=Task=1)/@0xd82067 - animation-leash#0] No local sync point found

dEQP Test Results:

Module		Passed	Failed	Total
dEQP-VK		568820	    79	568899

(v4) Vulkan HAL implement nvk specific ANB gralloc and synchronization, inspired by llvmpipe ANB

Changelog:

nvk_android.c: nvk_GetSwapchainGrallocUsageANDROID, nvk_AcquireImageANDROID, nvk_QueueSignalReleaseImageANDROID
               implemented as porting of llvmpipe commit 0dce939e with 's/lvp_/nvk_/g' for functions rename

NOTE: at this stage nvk_GetSwapchainGrallocUsageANDROID is only setting gralloc SW usage flags
nvk_image.h: NVK_MAX_PLANE_COUNT 1 - NOTE: I don' know how many max planes are supported by NVK

Achievements:

GearsVK working
dEQP-VK tests produce colored output on screen
3DMARK API Overhead, Slingshot Extreme: running but meshes are not rendered
Other Vulkan API enabled Android Apps (Sascha Willems vulkanTriangle) are showing black surface,
which is due to basic gralloc SW usage flags implemented in nvk_GetSwapchainGrallocUsageANDROID()

dEQP Test Results:

Module		Passed	Failed	Total
dEQP-VK		568820	    79	568899

The failed tests are in the following modules/test:

dEQP-VK.api.driver_properties#driver_id_match					 1
dEQP-VK.pipeline.multisample.min_sample_shading_enabled.*			 9
dEQP-VK.pipeline.multisample.min_sample_shading.*				56
dEQP-VK.sparse_resources.image_sparse_binding.cube_array.rgba32i#256_256_6	 1
dEQP-VK.sparse_resources.image_sparse_binding.cube_array.rgba32ui#256_256_6	 1
dEQP-VK.ssbo.layout.random.all_shared_buffer#5					 1
dEQP-VK.wsi.android.swapchain.simulate_oom					10

(v5) use ANB common code for GetSwapchainGrallocUsage*ANDROID

Changelog:

Replace the "SW usage only" nvk_GetSwapchainGrallocUsage{,2}ANDROID
and rely on vk_common_GetSwapchainGrallocUsage{,2}ANDROID

Achievements:

Vulkan Apps are rendering on screen
Tested on Android 11 with Vulkan 1.1 API

Android apps working:

Khronos Vulkan-Samples
Sacha Willems Vulkan Examples
Vulkan Android Test
vkCube
GearsVK
PPSSPP
3DMARK API Overhead, Slingshot Extreme - Still with meshes issue

dEQP Test Results:

Module		Passed	Failed	Total
dEQP-VK		568820	    79	568899

The failed tests are in the following modules/test (same as per previous iteration):

dEQP-VK.api.driver_properties#driver_id_match					 1
dEQP-VK.pipeline.multisample.min_sample_shading_enabled.*			 9
dEQP-VK.pipeline.multisample.min_sample_shading.*				56
dEQP-VK.sparse_resources.image_sparse_binding.cube_array.rgba32i#256_256_6	 1
dEQP-VK.sparse_resources.image_sparse_binding.cube_array.rgba32ui#256_256_6	 1
dEQP-VK.ssbo.layout.random.all_shared_buffer#5					 1
dEQP-VK.wsi.android.swapchain.simulate_oom#					10

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30833>
2024-11-26 21:45:16 +00:00
Mauro Rossi
63fa21334f nvk/android: Advertise Vulkan 1.1 for Android 12L and lower
Vulkan 1.3 is supported starting from Android 13

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30833>
2024-11-26 21:45:16 +00:00
Mauro Rossi
07e60fb255 nvk/android: Avoid building error in nak bindings
Required to compile nvk for android

Fixes the following building error:

FAILED: src/nouveau/compiler/nak_bindings.rs
...
/usr/include/xf86drm.h:40:10: fatal error: 'drm.h' file not found
panicked at 'Unable to generate bindings: ClangDiagnostic("/usr/include/xf86drm.h:40:10:
fatal error: 'drm.h' file not found\n")', main.rs:52:36

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30833>
2024-11-26 21:45:16 +00:00
Marek Olšák
9223528059 winsys/amdgpu: fix FD mismatch
The original fd was only used like this. Importing the ioctl wrappers
started using it for calling ioctls, which was incorrect.

Fixes: 049641ca54 - amd: import libdrm_amdgpu ioctl wrappers
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/12208

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32356>
2024-11-26 21:21:29 +00:00
Marek Olšák
733e0ebf19 radeonsi: handle a failure to create gfx_cs
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32356>
2024-11-26 21:21:29 +00:00
Marek Olšák
b23161ace1 radeonsi: don't call set_framebuffer_state in si_destroy_context
si_set_framebuffer_state can allocate a buffer for sample positions,
and we don't want to create new buffers in si_destroy_context because
it might not work.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32356>
2024-11-26 21:21:29 +00:00
Eric Engestrom
ffd02b8ad8 meson/megadriver: support various lib suffixes
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32333>
2024-11-26 20:45:41 +00:00