Skip to content

Commit

Permalink
Update supported Vulkan spec to 1.3.281
Browse files Browse the repository at this point in the history
  • Loading branch information
per-mathisen-arm committed Apr 2, 2024
1 parent 42e9380 commit 9acc288
Show file tree
Hide file tree
Showing 8 changed files with 33 additions and 12 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 Arm Software
Copyright (c) 2022 - 2024 Arm Limited

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion external/Vulkan-Headers
Submodule Vulkan-Headers updated 71 files
+0 −1 .github/ISSUE_TEMPLATE/bug_report.md
+12 −0 .github/dependabot.yml
+0 −1 .github/pull_request_template.md
+16 −64 .github/workflows/ci.yml
+4 −4 .reuse/dep5
+9 −1 BUILD.gn
+1 −0 CMakeLists.txt
+0 −1 CONTRIBUTING.md
+0 −105 INTEGRATION.md
+2 −4 README.md
+392 −0 include/vk_video/vulkan_video_codec_av1std.h
+109 −0 include/vk_video/vulkan_video_codec_av1std_decode.h
+1 −1 include/vk_video/vulkan_video_codec_h264std.h
+1 −1 include/vk_video/vulkan_video_codec_h264std_decode.h
+4 −4 include/vk_video/vulkan_video_codec_h264std_encode.h
+1 −1 include/vk_video/vulkan_video_codec_h265std.h
+1 −1 include/vk_video/vulkan_video_codec_h265std_decode.h
+4 −4 include/vk_video/vulkan_video_codec_h265std_encode.h
+1 −1 include/vk_video/vulkan_video_codecs_common.h
+1 −1 include/vulkan/vk_platform.h
+1,898 −254 include/vulkan/vulkan.cppm
+1 −1 include/vulkan/vulkan.h
+4,505 −1,230 include/vulkan/vulkan.hpp
+1 −1 include/vulkan/vulkan_android.h
+1 −598 include/vulkan/vulkan_beta.h
+1,472 −260 include/vulkan/vulkan_core.h
+1 −1 include/vulkan/vulkan_directfb.h
+1,429 −1,394 include/vulkan/vulkan_enums.hpp
+2,331 −802 include/vulkan/vulkan_extension_inspection.hpp
+2 −1 include/vulkan/vulkan_format_traits.hpp
+1 −1 include/vulkan/vulkan_fuchsia.h
+5,947 −2,592 include/vulkan/vulkan_funcs.hpp
+1 −1 include/vulkan/vulkan_ggp.h
+1,517 −490 include/vulkan/vulkan_handles.hpp
+1,133 −444 include/vulkan/vulkan_hash.hpp
+33 −5 include/vulkan/vulkan_hpp_macros.hpp
+1 −1 include/vulkan/vulkan_ios.h
+1 −1 include/vulkan/vulkan_macos.h
+1 −1 include/vulkan/vulkan_metal.h
+4,943 −2,871 include/vulkan/vulkan_raii.hpp
+1 −1 include/vulkan/vulkan_screen.h
+131 −32 include/vulkan/vulkan_shared.hpp
+585 −206 include/vulkan/vulkan_static_assertions.hpp
+10,146 −3,892 include/vulkan/vulkan_structs.hpp
+476 −402 include/vulkan/vulkan_to_string.hpp
+1 −1 include/vulkan/vulkan_vi.h
+1,018 −1 include/vulkan/vulkan_video.hpp
+1 −1 include/vulkan/vulkan_wayland.h
+1 −1 include/vulkan/vulkan_win32.h
+1 −1 include/vulkan/vulkan_xcb.h
+1 −1 include/vulkan/vulkan_xlib.h
+1 −1 include/vulkan/vulkan_xlib_xrandr.h
+1 −1 registry/apiconventions.py
+1 −1 registry/cgenerator.py
+3 −4 registry/generator.py
+0 −1,117 registry/genvk.py
+11 −32 registry/parse_dependency.py
+149 −140 registry/profiles/VP_KHR_roadmap.json
+1 −1 registry/reg.py
+87 −5 registry/spec_tools/conventions.py
+1 −2 registry/spec_tools/util.py
+7,174 −2,952 registry/validusage.json
+494 −9 registry/video.xml
+1,664 −794 registry/vk.xml
+16 −3 registry/vkconventions.py
+25 −38 tests/CMakeLists.txt
+0 −30 tests/add_subdirectory/CMakeLists.txt
+0 −30 tests/find_package/CMakeLists.txt
+73 −0 tests/integration/CMakeLists.txt
+2 −2 tests/vk_icd.c
+2 −2 tests/vk_layer.c
7 changes: 6 additions & 1 deletion scripts/struct.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@
'VkVideoDecodeH264CapabilitiesKHR', 'VkVideoDecodeH264SessionParametersAddInfoKHR', 'VkVideoDecodeH264ProfileInfoKHR', 'VkVideoDecodeH264SessionParametersCreateInfoKHR',
'VkVideoDecodeH264PictureInfoKHR', 'VkVideoDecodeH264DpbSlotInfoKHR', 'VkVideoDecodeH265ProfileInfoKHR', 'VkVideoDecodeH265SessionParametersAddInfoKHR',
'VkVideoDecodeH265CapabilitiesKHR', 'VkVideoDecodeH265SessionParametersCreateInfoKHR', 'VkVideoDecodeH265PictureInfoKHR', 'VkVideoDecodeH265DpbSlotInfoKHR',
'VkOpaqueCaptureDescriptorDataCreateInfoEXT' ]
'VkOpaqueCaptureDescriptorDataCreateInfoEXT',
'VkPushDescriptorSetWithTemplateInfoKHR',
'VkMemoryMapPlacedInfoEXT',
'VkBindMemoryStatusKHR',
'VkRenderingInputAttachmentIndexInfoKHR',
]

hardcoded_read = [ 'VkAccelerationStructureBuildGeometryInfoKHR' ]
hardcoded_write = []
Expand Down
21 changes: 13 additions & 8 deletions scripts/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@
'vkGetPipelinePropertiesEXT', 'vkUpdateDescriptorSetWithTemplate', 'vkCmdUpdateBuffer', 'vkGetBufferOpaqueCaptureDescriptorDataEXT',
'vkCmdBuildMicromapsEXT', 'vkBuildMicromapsEXT', 'vkGetMicromapBuildSizesEXT', 'vkGetImageOpaqueCaptureDescriptorDataEXT', 'vkGetSamplerOpaqueCaptureDescriptorDataEXT',
'vkGetDeviceFaultInfoEXT', # we never want to trace this, but rather inject it during tracing if device loss happens, print the info, then abort
'vkGetAccelerationStructureOpaqueCaptureDescriptorDataEXT'
'vkGetAccelerationStructureOpaqueCaptureDescriptorDataEXT', 'vkCmdPushDescriptorSetWithTemplate2KHR', 'vkCmdSetRenderingInputAttachmentIndicesKHR',
'vkGetEncodedVideoSessionParametersKHR',
]
struct_noop = []

Expand Down Expand Up @@ -391,20 +392,18 @@ def __init__(self, node, read, funcname, transitiveConst = False):
self.length = self.length.replace(',1', '')
if self.length and '::' in self.length:
self.length = self.length.replace('::','->')
if not self.length and '[' in raw: # ie fixed length array
length = node.find('enum')
if length is not None:
self.length = length.text
else: # naked numeral
self.length = getsize(raw)
if '[' in raw: # fixed length array?
enum_length = node.find('enum')
if enum_length: self.length = length.text # an enum define
else: self.length = getsize(raw) # a numeric value
if self.length and (self.length.isdigit() or self.length.isupper()):
self.fixedsize = True # fixed length array
self.structure = self.type in spec.structures
self.disphandle = self.type in spec.disp_handles
self.nondisphandle = self.type in spec.nondisp_handles
self.inparam = (not self.ptr or self.const) # else out parameter
self.string_array = self.length and ',null-terminated' in self.length and self.type == 'char'
self.string = self.length == 'null-terminated' and self.type == 'char'
self.string = self.length == 'null-terminated' and self.type == 'char' and not self.string_array and not self.fixedsize
self.read = read

# We need to be really defensive and treat all pointers as potentially optional. We cannot trust the optional XML
Expand Down Expand Up @@ -646,6 +645,9 @@ def print_load(self, name, owner): # called for each parameter
storedname = z.tmpmem('float', '%s * 4' % self.length)
z.do('reader.read_array(%s, %s * 4); // read VkClearValue into temporary' % (storedname, self.length))
z.do('%s = reinterpret_cast<VkClearValue*>(%s);' % (varname, storedname))
elif self.type in spec.packed_bitfields:
storedtype = spec.type_mappings[self.type]
z.do('%s = (%s)reader.read_%s_t();' % (self.type, varname, storedtype))
elif self.type in spec.type_mappings:
storedtype = spec.type_mappings[self.type]
nativetype = self.type if self.type != 'void' else 'char'
Expand Down Expand Up @@ -970,6 +972,9 @@ def print_save(self, name, owner): # called for each parameter
z.do('for (unsigned s = 0; s < (unsigned)(%s); s++) writer.write_%s(%s[s]);' % (self.length, spec.type_mappings[self.type], varname))
else: # no, just write out as is
z.do('writer.write_array(reinterpret_cast<const char*>(%s), %s * sizeof(%s));' % (varname, self.length, self.type if self.type != 'void' else 'char'))
elif self.type in spec.packed_bitfields:
storedtype = spec.type_mappings[self.type]
z.do('writer.write_%s_t((%s)%s);' % (storedtype, storedtype, varname))
elif self.ptr and self.type in spec.type_mappings:
z.do('writer.write_%s(*%s);' % (spec.type_mappings[self.type], varname))
elif self.ptr:
Expand Down
4 changes: 4 additions & 0 deletions src/hardcode_read.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@ static uint64_t debug_object_lookup(VkDebugReportObjectTypeEXT type, uint32_t in
case VK_DEBUG_REPORT_OBJECT_TYPE_VALIDATION_CACHE_EXT: return (uint64_t)index_to_VkValidationCacheEXT.at(index);
case VK_DEBUG_REPORT_OBJECT_TYPE_SAMPLER_YCBCR_CONVERSION_KHR_EXT: return (uint64_t)index_to_VkSamplerYcbcrConversion.at(index);
// these are not supported:
case VK_DEBUG_REPORT_OBJECT_TYPE_CUDA_MODULE_NV_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_CUDA_FUNCTION_NV_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_DEBUG_REPORT_CALLBACK_EXT_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_CU_MODULE_NVX_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_CU_FUNCTION_NVX_EXT:
Expand Down Expand Up @@ -150,6 +152,8 @@ static uint64_t object_lookup(VkObjectType type, uint32_t index)
case VK_OBJECT_TYPE_DEBUG_REPORT_CALLBACK_EXT: return (uint64_t)index_to_VkDebugReportCallbackEXT.at(index);
case VK_OBJECT_TYPE_DEBUG_UTILS_MESSENGER_EXT: return (uint64_t)index_to_VkDebugUtilsMessengerEXT.at(index);
// these are not supported:
case VK_OBJECT_TYPE_CUDA_MODULE_NV:
case VK_OBJECT_TYPE_CUDA_FUNCTION_NV:
case VK_OBJECT_TYPE_OPTICAL_FLOW_SESSION_NV:
case VK_OBJECT_TYPE_BUFFER_COLLECTION_FUCHSIA:
case VK_OBJECT_TYPE_INDIRECT_COMMANDS_LAYOUT_NV:
Expand Down
4 changes: 4 additions & 0 deletions src/hardcode_write.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ static trackable* debug_object_trackable(trace_records& r, VkDebugReportObjectTy
case VK_DEBUG_REPORT_OBJECT_TYPE_CU_MODULE_NVX_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_BUFFER_COLLECTION_FUCHSIA_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_UNKNOWN_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_CUDA_MODULE_NV_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_CUDA_FUNCTION_NV_EXT:
case VK_DEBUG_REPORT_OBJECT_TYPE_MAX_ENUM_EXT: assert(false); return nullptr;
}
return nullptr;
Expand Down Expand Up @@ -122,6 +124,8 @@ static trackable* object_trackable(const trace_records& r, VkObjectType type, ui
case VK_OBJECT_TYPE_DEBUG_REPORT_CALLBACK_EXT: return r.VkDebugReportCallbackEXT_index.at((const VkDebugReportCallbackEXT)object);
case VK_OBJECT_TYPE_DEBUG_UTILS_MESSENGER_EXT: return r.VkDebugUtilsMessengerEXT_index.at((const VkDebugUtilsMessengerEXT)object);
// not supported:
case VK_OBJECT_TYPE_CUDA_MODULE_NV:
case VK_OBJECT_TYPE_CUDA_FUNCTION_NV:
case VK_OBJECT_TYPE_CU_MODULE_NVX:
case VK_OBJECT_TYPE_CU_FUNCTION_NVX:
case VK_OBJECT_TYPE_ACCELERATION_STRUCTURE_NV:
Expand Down
3 changes: 3 additions & 0 deletions src/util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ const char* errorString(const VkResult errorCode)
STR(ERROR_VIDEO_PROFILE_CODEC_NOT_SUPPORTED_KHR);
STR(ERROR_VIDEO_STD_VERSION_NOT_SUPPORTED_KHR);
STR(ERROR_INCOMPATIBLE_SHADER_BINARY_EXT);
STR(ERROR_INVALID_VIDEO_STD_PARAMETERS_KHR);
#undef STR
case VK_RESULT_MAX_ENUM:
return "(bad error code)";
Expand Down Expand Up @@ -386,6 +387,8 @@ const char* pretty_print_VkObjectType(VkObjectType val)
case VK_OBJECT_TYPE_VIDEO_SESSION_KHR: return "VideoSession";
case VK_OBJECT_TYPE_VIDEO_SESSION_PARAMETERS_KHR: return "VideoSessionParameters";
case VK_OBJECT_TYPE_SHADER_EXT: return "Shader";
case VK_OBJECT_TYPE_CUDA_MODULE_NV: return "CudaModule";
case VK_OBJECT_TYPE_CUDA_FUNCTION_NV: return "CudaFunction";
}
return "Error";
}

0 comments on commit 9acc288

Please sign in to comment.