From 1e4bd1de9897d05c39deb483a29fbb2a477374f7 Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Sun, 5 Apr 2020 09:33:43 +0200 Subject: [PATCH] radv: only expose storageInputOutput16 for chips with double rate fp16 MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This feature allows to use both 16-bit integers and 16-bit floats as inputs/outputs. This disables storageInputOutput16 on GFX8 because only GFX9+ supports double rate packed math. This improves consistency regarding other AMD Vulkan drivers. Signed-off-by: Samuel Pitoiset Acked-by: Daniel Schürmann Reviewed-by: Bas Nieuwenhuizen Part-of: --- src/amd/vulkan/radv_device.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c index 097f54931b9..db992d6867a 100644 --- a/src/amd/vulkan/radv_device.c +++ b/src/amd/vulkan/radv_device.c @@ -1000,7 +1000,7 @@ void radv_GetPhysicalDeviceFeatures2( features->storageBuffer16BitAccess = !pdevice->use_aco; features->uniformAndStorageBuffer16BitAccess = !pdevice->use_aco; features->storagePushConstant16 = !pdevice->use_aco; - features->storageInputOutput16 = pdevice->rad_info.chip_class >= GFX8 && !pdevice->use_aco && LLVM_VERSION_MAJOR >= 9; + features->storageInputOutput16 = pdevice->rad_info.has_double_rate_fp16 && !pdevice->use_aco && LLVM_VERSION_MAJOR >= 9; break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SAMPLER_YCBCR_CONVERSION_FEATURES: { @@ -1218,7 +1218,7 @@ void radv_GetPhysicalDeviceFeatures2( features->storageBuffer16BitAccess = !pdevice->use_aco; features->uniformAndStorageBuffer16BitAccess = !pdevice->use_aco; features->storagePushConstant16 = !pdevice->use_aco; - features->storageInputOutput16 = pdevice->rad_info.chip_class >= GFX8 && !pdevice->use_aco && LLVM_VERSION_MAJOR >= 9; + features->storageInputOutput16 = pdevice->rad_info.has_double_rate_fp16 && !pdevice->use_aco && LLVM_VERSION_MAJOR >= 9; features->multiview = true; features->multiviewGeometryShader = true; features->multiviewTessellationShader = true; -- 2.30.2