Mesa (main): radv: only init acceleration structure if RT is enabled
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed May 4 17:17:06 UTC 2022
Module: Mesa
Branch: main
Commit: 665a671c7d88f9a4941b07099c875b16245e0ac6
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=665a671c7d88f9a4941b07099c875b16245e0ac6
Author: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Date: Tue May 3 18:22:36 2022 +0200
radv: only init acceleration structure if RT is enabled
This is to fix a LLVM crash with 13.0 because ATOMIC_FMAX is only
supported on 14.0+, so RADV_DEBUG=llvm was just completely broken.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Reviewed-by: Konstantin Seurer <konstantin.seurer at gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16305>
---
src/amd/vulkan/radv_meta.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/amd/vulkan/radv_meta.c b/src/amd/vulkan/radv_meta.c
index 9ce6619a0b6..f9abd3735a7 100644
--- a/src/amd/vulkan/radv_meta.c
+++ b/src/amd/vulkan/radv_meta.c
@@ -587,9 +587,11 @@ radv_device_init_meta(struct radv_device *device)
if (result != VK_SUCCESS)
goto fail_fmask_expand;
- result = radv_device_init_accel_struct_build_state(device);
- if (result != VK_SUCCESS)
- goto fail_accel_struct_build;
+ if (radv_enable_rt(device->physical_device)) {
+ result = radv_device_init_accel_struct_build_state(device);
+ if (result != VK_SUCCESS)
+ goto fail_accel_struct_build;
+ }
result = radv_device_init_meta_fmask_copy_state(device);
if (result != VK_SUCCESS)
More information about the mesa-commit
mailing list