tu: Expose Vulkan 1.4 on a7xx

Vulkan 1.4 can only be exposed on a7xx devices due to a number of bumps
in the required limits, including bumping maxDescriptorSets to 7. a7xx
bumped the number of bindless bases from 5 to 8, with one reserved for
the driver.

I've followed what we've already done and exposed a conformanceVersion
of 1.4.0.0 for all a7xx devices, even though I've only submitted
conformance for X1-85. I'm not sure if we want to change this, but at
least for now a618 on Chromebooks and X1-85 on laptops are the only
cases where turnip is being "shipped" to users in some official
capacity, so it shouldn't be a huge deal.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32437>
This commit is contained in:
Connor Abbott
2024-10-17 14:18:50 -04:00
committed by Marge Bot
parent 21838dcbb6
commit 0c55770b3e
2 changed files with 21 additions and 10 deletions

View File

@@ -208,7 +208,7 @@ freedreno_icd = custom_target(
output : 'freedreno_icd.@0@.json'.format(host_machine.cpu()),
command : [
prog_python, '@INPUT0@',
'--api-version', '1.1', '--xml', '@INPUT1@',
'--api-version', '1.4', '--xml', '@INPUT1@',
'--lib-path', join_paths(get_option('prefix'), get_option('libdir'),
'libvulkan_freedreno.so'),
'--out', '@OUTPUT@',
@@ -226,7 +226,7 @@ _dev_icd = custom_target(
output : _dev_icdname,
command : [
prog_python, '@INPUT0@',
'--api-version', '1.1', '--xml', '@INPUT1@',
'--api-version', '1.4', '--xml', '@INPUT1@',
'--lib-path', meson.current_build_dir() / 'libvulkan_freedreno.so',
'--out', '@OUTPUT@',
],

View File

@@ -76,7 +76,7 @@ tu_device_get_cache_uuid(struct tu_physical_device *device, void *uuid)
return 0;
}
#define TU_API_VERSION VK_MAKE_VERSION(1, 3, VK_HEADER_VERSION)
#define TU_API_VERSION VK_MAKE_VERSION(1, 4, VK_HEADER_VERSION)
VKAPI_ATTR VkResult VKAPI_CALL
tu_EnumerateInstanceVersion(uint32_t *pApiVersion)
@@ -770,12 +770,21 @@ tu_get_physical_device_properties_1_2(struct tu_physical_device *pdevice,
memset(p->driverInfo, 0, sizeof(p->driverInfo));
snprintf(p->driverInfo, VK_MAX_DRIVER_INFO_SIZE,
"Mesa " PACKAGE_VERSION MESA_GIT_SHA1);
p->conformanceVersion = (VkConformanceVersion) {
.major = 1,
.minor = 2,
.subminor = 7,
.patch = 1,
};
if (pdevice->info->chip >= 7) {
p->conformanceVersion = (VkConformanceVersion) {
.major = 1,
.minor = 4,
.subminor = 0,
.patch = 0,
};
} else {
p->conformanceVersion = (VkConformanceVersion) {
.major = 1,
.minor = 2,
.subminor = 7,
.patch = 1,
};
}
p->denormBehaviorIndependence =
VK_SHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL;
@@ -1034,7 +1043,9 @@ tu_get_properties(struct tu_physical_device *pdevice,
props->apiVersion =
(pdevice->info->a6xx.has_hw_multiview || TU_DEBUG(NOCONFORM)) ?
TU_API_VERSION : VK_MAKE_VERSION(1, 0, VK_HEADER_VERSION);
((pdevice->info->chip >= 7) ? TU_API_VERSION :
VK_MAKE_VERSION(1, 3, VK_HEADER_VERSION))
: VK_MAKE_VERSION(1, 0, VK_HEADER_VERSION);
props->driverVersion = vk_get_driver_version();
props->vendorID = 0x5143;
props->deviceID = pdevice->dev_id.chip_id;