nvk: Better advertise image format features
We now advertise the top-level features and we don't falsely claim write-without-format support per-format. In theory, NV hardware should be able to do shaderStorageImageReadWithoutFormat but codegen doesn't know how yet. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
This commit is contained in:

committed by
Marge Bot

parent
db81c26525
commit
dda149c053
@@ -36,7 +36,6 @@ nvk_get_image_format_features(struct nvk_physical_device *pdevice,
|
||||
|
||||
if (nvk_is_storage_image_format(vk_format)) {
|
||||
features |= VK_FORMAT_FEATURE_2_STORAGE_IMAGE_BIT |
|
||||
VK_FORMAT_FEATURE_2_STORAGE_READ_WITHOUT_FORMAT_BIT |
|
||||
VK_FORMAT_FEATURE_2_STORAGE_WRITE_WITHOUT_FORMAT_BIT;
|
||||
}
|
||||
|
||||
|
@@ -32,6 +32,8 @@ nvk_GetPhysicalDeviceFeatures2(VkPhysicalDevice physicalDevice,
|
||||
pFeatures->features = (VkPhysicalDeviceFeatures) {
|
||||
.robustBufferAccess = true,
|
||||
/* More features */
|
||||
.shaderStorageImageExtendedFormats = true,
|
||||
.shaderStorageImageWriteWithoutFormat = true,
|
||||
};
|
||||
|
||||
VkPhysicalDeviceVulkan11Features core_1_1 = {
|
||||
|
@@ -89,6 +89,7 @@ nvk_shader_compile_to_nir(struct nvk_device *device,
|
||||
const struct spirv_to_nir_options spirv_options = {
|
||||
.caps =
|
||||
{
|
||||
.image_write_without_format = true,
|
||||
},
|
||||
.ssbo_addr_format = nir_address_format_64bit_global_32bit_offset,
|
||||
.ubo_addr_format = nir_address_format_64bit_global_32bit_offset,
|
||||
|
Reference in New Issue
Block a user