blob: 28bf188cf870b94313fffe24074a260dc1afa451 [file] [log] [blame]
Tobin Ehlis98d109a2017-05-11 14:42:38 -06001#!/usr/bin/python -i
2
3import sys
4import xml.etree.ElementTree as etree
Mark Lobodzinski8c9633d2017-06-05 13:50:10 -06005try:
6 import urllib.request as urllib2
7except ImportError:
8 import urllib2
Tobin Ehlis98d109a2017-05-11 14:42:38 -06009import json
10
11#############################
12# vuid_mapping.py script
13#
14# VUID Mapping Details
15# The Vulkan spec creation process automatically generates string-based unique IDs for each Valid Usage statement
16# For implicit VUs, the format is VUID-<func|struct>-[<param_name>]-<type>
17# func|struct is the name of the API function or structure that the VU is under
18# param_name is an optional entry with the name of the function or struct parameter
19# type is the type of implicit check, see table below for possible values
20#
21# For explicit VUs, the format is VUID-<func|struct>-[<param_name>]-<uniqueid>
22# All fields are the same as implicit VUs except the last parameter is a globally unique integer ID instead of a string type
23#
24# The values below are used to map the strings into unique integers that are used for the unique enum values returned by debug callbacks
25# Here's how the bits of the numerical unique ID map to the ID type and values
26# 31:21 - 11 bits that map to unique value for the function/struct
27# 20:1 - 20 bits that map to param-type combo for implicit VU and uniqueid for explicit VU
28# 0 - 1 bit on for implicit VU or off for explicit VU
29#
30# For implicit VUs 20:1 is split into 20:9 for parameter and 8:1 for type
31FUNC_STRUCT_SHIFT = 21
32EXPLICIT_ID_SHIFT = 1
33IMPLICIT_TYPE_SHIFT = 1
34IMPLICIT_PARAM_SHIFT = 9
35explicit_bit0 = 0x0 # All explicit IDs are even
36implicit_bit0 = 0x1 # All implicit IDs are odd
37# Implicit type values, shifted up by ID_SHIFT bits in final ID
38implicit_type_map = {
39'parameter' : 0,
40'requiredbitmask' : 1,
41'zerobitmask' : 2,
42'parent' : 3,
43'commonparent' : 4,
44'sType' : 5,
45'pNext' : 6,
46'unique' : 7,
47'queuetype' : 8,
48'recording' : 9,
49'cmdpool' : 10,
50'renderpass' : 11,
51'bufferlevel' : 12,
52'arraylength' : 13,
53}
54# Function/struct value mappings, shifted up FUNC_STRUCT_SHIFT bits in final ID
55func_struct_id_map = {
56'VkAcquireNextImageInfoKHX' : 0,
57'VkAllocationCallbacks' : 1,
58'VkAndroidSurfaceCreateInfoKHR' : 2,
59'VkApplicationInfo' : 3,
60'VkAttachmentDescription' : 4,
61'VkAttachmentReference' : 5,
62'VkBindBufferMemoryInfoKHX' : 6,
63'VkBindImageMemoryInfoKHX' : 7,
64'VkBindImageMemorySwapchainInfoKHX' : 8,
65'VkBindSparseInfo' : 9,
66'VkBufferCreateInfo' : 10,
67'VkBufferImageCopy' : 11,
68'VkBufferMemoryBarrier' : 12,
69'VkBufferViewCreateInfo' : 13,
70'VkClearAttachment' : 14,
71'VkClearDepthStencilValue' : 15,
72'VkClearValue' : 16,
73'VkCmdProcessCommandsInfoNVX' : 17,
74'VkCmdReserveSpaceForCommandsInfoNVX' : 18,
75'VkCommandBufferAllocateInfo' : 19,
76'VkCommandBufferBeginInfo' : 20,
77'VkCommandBufferInheritanceInfo' : 21,
78'VkCommandPoolCreateInfo' : 22,
79'VkComponentMapping' : 23,
80'VkComputePipelineCreateInfo' : 24,
81'VkCopyDescriptorSet' : 25,
Mark Youngabc2d6e2017-07-07 07:59:56 -060082'VkD3D12FenceSubmitInfoKHR' : 26,
Tobin Ehlis98d109a2017-05-11 14:42:38 -060083'VkDebugMarkerMarkerInfoEXT' : 27,
84'VkDebugMarkerObjectNameInfoEXT' : 28,
85'VkDebugMarkerObjectTagInfoEXT' : 29,
86'VkDebugReportCallbackCreateInfoEXT' : 30,
87'VkDedicatedAllocationBufferCreateInfoNV' : 31,
88'VkDedicatedAllocationImageCreateInfoNV' : 32,
89'VkDedicatedAllocationMemoryAllocateInfoNV' : 33,
90'VkDescriptorBufferInfo' : 34,
91'VkDescriptorImageInfo' : 35,
92'VkDescriptorPoolCreateInfo' : 36,
93'VkDescriptorPoolSize' : 37,
94'VkDescriptorSetAllocateInfo' : 38,
95'VkDescriptorSetLayoutBinding' : 39,
96'VkDescriptorSetLayoutCreateInfo' : 40,
97'VkDescriptorUpdateTemplateCreateInfoKHR' : 41,
98'VkDescriptorUpdateTemplateEntryKHR' : 42,
99'VkDeviceCreateInfo' : 43,
100'VkDeviceEventInfoEXT' : 44,
101'VkDeviceGeneratedCommandsFeaturesNVX' : 45,
102'VkDeviceGeneratedCommandsLimitsNVX' : 46,
103'VkDeviceGroupBindSparseInfoKHX' : 47,
104'VkDeviceGroupCommandBufferBeginInfoKHX' : 48,
105'VkDeviceGroupDeviceCreateInfoKHX' : 49,
106'VkDeviceGroupPresentInfoKHX' : 50,
107'VkDeviceGroupRenderPassBeginInfoKHX' : 51,
108'VkDeviceGroupSubmitInfoKHX' : 52,
109'VkDeviceGroupSwapchainCreateInfoKHX' : 53,
110'VkDeviceQueueCreateInfo' : 54,
111'VkDispatchIndirectCommand' : 55,
112'VkDisplayEventInfoEXT' : 56,
113'VkDisplayModeCreateInfoKHR' : 57,
114'VkDisplayPowerInfoEXT' : 58,
115'VkDisplayPresentInfoKHR' : 59,
116'VkDisplaySurfaceCreateInfoKHR' : 60,
117'VkDrawIndexedIndirectCommand' : 61,
118'VkDrawIndirectCommand' : 62,
119'VkEventCreateInfo' : 63,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600120'VkExportMemoryAllocateInfoKHR' : 64,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600121'VkExportMemoryAllocateInfoNV' : 65,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600122'VkExportMemoryWin32HandleInfoKHR' : 66,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600123'VkExportMemoryWin32HandleInfoNV' : 67,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600124'VkExportSemaphoreCreateInfoKHR' : 68,
125'VkExportSemaphoreWin32HandleInfoKHR' : 69,
126'VkExternalMemoryBufferCreateInfoKHR' : 70,
127'VkExternalMemoryImageCreateInfoKHR' : 71,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600128'VkExternalMemoryImageCreateInfoNV' : 72,
129'VkFenceCreateInfo' : 73,
130'VkFramebufferCreateInfo' : 74,
131'VkGraphicsPipelineCreateInfo' : 75,
132'VkIOSSurfaceCreateInfoMVK' : 76,
133'VkImageBlit' : 77,
134'VkImageCopy' : 78,
135'VkImageCreateInfo' : 79,
136'VkImageMemoryBarrier' : 80,
137'VkImageResolve' : 81,
138'VkImageSubresource' : 82,
139'VkImageSubresourceLayers' : 83,
140'VkImageSubresourceRange' : 84,
141'VkImageSwapchainCreateInfoKHX' : 85,
142'VkImageViewCreateInfo' : 86,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600143'VkImportMemoryFdInfoKHR' : 87,
144'VkImportMemoryWin32HandleInfoKHR' : 88,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600145'VkImportMemoryWin32HandleInfoNV' : 89,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600146'VkImportSemaphoreFdInfoKHR' : 90,
147'VkImportSemaphoreWin32HandleInfoKHR' : 91,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600148'VkIndirectCommandsLayoutCreateInfoNVX' : 92,
149'VkIndirectCommandsLayoutTokenNVX' : 93,
150'VkIndirectCommandsTokenNVX' : 94,
151'VkInstanceCreateInfo' : 95,
152'VkMacOSSurfaceCreateInfoMVK' : 96,
153'VkMappedMemoryRange' : 97,
154'VkMemoryAllocateFlagsInfoKHX' : 98,
155'VkMemoryAllocateInfo' : 99,
156'VkMemoryBarrier' : 100,
157'VkMirSurfaceCreateInfoKHR' : 101,
158'VkObjectTableCreateInfoNVX' : 102,
159'VkObjectTableDescriptorSetEntryNVX' : 103,
160'VkObjectTableEntryNVX' : 104,
161'VkObjectTableIndexBufferEntryNVX' : 105,
162'VkObjectTablePipelineEntryNVX' : 106,
163'VkObjectTablePushConstantEntryNVX' : 107,
164'VkObjectTableVertexBufferEntryNVX' : 108,
165'VkPhysicalDeviceDiscardRectanglePropertiesEXT' : 109,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600166'VkPhysicalDeviceExternalBufferInfoKHR' : 110,
167'VkPhysicalDeviceExternalImageFormatInfoKHR' : 111,
168'VkPhysicalDeviceExternalSemaphoreInfoKHR' : 112,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600169'VkPhysicalDeviceFeatures' : 113,
170'VkPhysicalDeviceFeatures2KHR' : 114,
171'VkPhysicalDeviceImageFormatInfo2KHR' : 115,
172'VkPhysicalDeviceMultiviewFeaturesKHX' : 116,
173'VkPhysicalDevicePushDescriptorPropertiesKHR' : 117,
174'VkPhysicalDeviceSparseImageFormatInfo2KHR' : 118,
175'VkPhysicalDeviceSurfaceInfo2KHR' : 119,
176'VkPipelineCacheCreateInfo' : 120,
177'VkPipelineColorBlendAttachmentState' : 121,
178'VkPipelineColorBlendStateCreateInfo' : 122,
179'VkPipelineDepthStencilStateCreateInfo' : 123,
180'VkPipelineDiscardRectangleStateCreateInfoEXT' : 124,
181'VkPipelineDynamicStateCreateInfo' : 125,
182'VkPipelineInputAssemblyStateCreateInfo' : 126,
183'VkPipelineLayoutCreateInfo' : 127,
184'VkPipelineMultisampleStateCreateInfo' : 128,
185'VkPipelineRasterizationStateCreateInfo' : 129,
186'VkPipelineRasterizationStateRasterizationOrderAMD' : 130,
187'VkPipelineShaderStageCreateInfo' : 131,
188'VkPipelineTessellationStateCreateInfo' : 132,
189'VkPipelineVertexInputStateCreateInfo' : 133,
190'VkPipelineViewportStateCreateInfo' : 134,
191'VkPipelineViewportSwizzleStateCreateInfoNV' : 135,
192'VkPipelineViewportWScalingStateCreateInfoNV' : 136,
193'VkPresentInfoKHR' : 137,
194'VkPresentRegionKHR' : 138,
195'VkPresentRegionsKHR' : 139,
196'VkPresentTimesInfoGOOGLE' : 140,
197'VkPushConstantRange' : 141,
198'VkQueryPoolCreateInfo' : 142,
199'VkRectLayerKHR' : 143,
200'VkRenderPassBeginInfo' : 144,
201'VkRenderPassCreateInfo' : 145,
202'VkRenderPassMultiviewCreateInfoKHX' : 146,
203'VkSamplerCreateInfo' : 147,
204'VkSemaphoreCreateInfo' : 148,
205'VkShaderModuleCreateInfo' : 149,
206'VkSparseBufferMemoryBindInfo' : 150,
207'VkSparseImageMemoryBind' : 151,
208'VkSparseImageMemoryBindInfo' : 152,
209'VkSparseImageOpaqueMemoryBindInfo' : 153,
210'VkSparseMemoryBind' : 154,
211'VkSpecializationInfo' : 155,
212'VkSpecializationMapEntry' : 156,
213'VkStencilOpState' : 157,
214'VkSubmitInfo' : 158,
215'VkSubpassDependency' : 159,
216'VkSubpassDescription' : 160,
217'VkSurfaceCapabilities2EXT' : 161,
218'VkSwapchainCounterCreateInfoEXT' : 162,
219'VkSwapchainCreateInfoKHR' : 163,
220'VkValidationFlagsEXT' : 164,
221'VkVertexInputAttributeDescription' : 165,
222'VkVertexInputBindingDescription' : 166,
223'VkViSurfaceCreateInfoNN' : 167,
224'VkViewport' : 168,
225'VkViewportSwizzleNV' : 169,
226'VkWaylandSurfaceCreateInfoKHR' : 170,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600227'VkWin32KeyedMutexAcquireReleaseInfoKHR' : 171,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600228'VkWin32KeyedMutexAcquireReleaseInfoNV' : 172,
229'VkWin32SurfaceCreateInfoKHR' : 173,
230'VkWriteDescriptorSet' : 174,
231'VkXcbSurfaceCreateInfoKHR' : 175,
232'VkXlibSurfaceCreateInfoKHR' : 176,
233'vkAcquireNextImage2KHX' : 177,
234'vkAcquireNextImageKHR' : 178,
235'vkAcquireXlibDisplayEXT' : 179,
236'vkAllocateCommandBuffers' : 180,
237'vkAllocateDescriptorSets' : 181,
238'vkAllocateMemory' : 182,
239'vkBeginCommandBuffer' : 183,
240'vkBindBufferMemory' : 184,
241'vkBindBufferMemory2KHX' : 185,
242'vkBindImageMemory' : 186,
243'vkBindImageMemory2KHX' : 187,
244'vkCmdBeginQuery' : 188,
245'vkCmdBeginRenderPass' : 189,
246'vkCmdBindDescriptorSets' : 190,
247'vkCmdBindIndexBuffer' : 191,
248'vkCmdBindPipeline' : 192,
249'vkCmdBindVertexBuffers' : 193,
250'vkCmdBlitImage' : 194,
251'vkCmdClearAttachments' : 195,
252'vkCmdClearColorImage' : 196,
253'vkCmdClearDepthStencilImage' : 197,
254'vkCmdCopyBuffer' : 198,
255'vkCmdCopyBufferToImage' : 199,
256'vkCmdCopyImage' : 200,
257'vkCmdCopyImageToBuffer' : 201,
258'vkCmdCopyQueryPoolResults' : 202,
259'vkCmdDebugMarkerBeginEXT' : 203,
260'vkCmdDebugMarkerEndEXT' : 204,
261'vkCmdDebugMarkerInsertEXT' : 205,
262'vkCmdDispatch' : 206,
263'vkCmdDispatchBaseKHX' : 207,
264'vkCmdDispatchIndirect' : 208,
265'vkCmdDraw' : 209,
266'vkCmdDrawIndexed' : 210,
267'vkCmdDrawIndexedIndirect' : 211,
268'vkCmdDrawIndexedIndirectCountAMD' : 212,
269'vkCmdDrawIndirect' : 213,
270'vkCmdDrawIndirectCountAMD' : 214,
271'vkCmdEndQuery' : 215,
272'vkCmdEndRenderPass' : 216,
273'vkCmdExecuteCommands' : 217,
274'vkCmdFillBuffer' : 218,
275'vkCmdNextSubpass' : 219,
276'vkCmdPipelineBarrier' : 220,
277'vkCmdProcessCommandsNVX' : 221,
278'vkCmdPushConstants' : 222,
279'vkCmdPushDescriptorSetKHR' : 223,
280'vkCmdPushDescriptorSetWithTemplateKHR' : 224,
281'vkCmdReserveSpaceForCommandsNVX' : 225,
282'vkCmdResetEvent' : 226,
283'vkCmdResetQueryPool' : 227,
284'vkCmdResolveImage' : 228,
285'vkCmdSetBlendConstants' : 229,
286'vkCmdSetDepthBias' : 230,
287'vkCmdSetDepthBounds' : 231,
288'vkCmdSetDeviceMaskKHX' : 232,
289'vkCmdSetDiscardRectangleEXT' : 233,
290'vkCmdSetEvent' : 234,
291'vkCmdSetLineWidth' : 235,
292'vkCmdSetScissor' : 236,
293'vkCmdSetStencilCompareMask' : 237,
294'vkCmdSetStencilReference' : 238,
295'vkCmdSetStencilWriteMask' : 239,
296'vkCmdSetViewport' : 240,
297'vkCmdSetViewportWScalingNV' : 241,
298'vkCmdUpdateBuffer' : 242,
299'vkCmdWaitEvents' : 243,
300'vkCmdWriteTimestamp' : 244,
301'vkCreateAndroidSurfaceKHR' : 245,
302'vkCreateBuffer' : 246,
303'vkCreateBufferView' : 247,
304'vkCreateCommandPool' : 248,
305'vkCreateComputePipelines' : 249,
306'vkCreateDebugReportCallbackEXT' : 250,
307'vkCreateDescriptorPool' : 251,
308'vkCreateDescriptorSetLayout' : 252,
309'vkCreateDescriptorUpdateTemplateKHR' : 253,
310'vkCreateDevice' : 254,
311'vkCreateDisplayModeKHR' : 255,
312'vkCreateDisplayPlaneSurfaceKHR' : 256,
313'vkCreateEvent' : 257,
314'vkCreateFence' : 258,
315'vkCreateFramebuffer' : 259,
316'vkCreateGraphicsPipelines' : 260,
317'vkCreateIOSSurfaceMVK' : 261,
318'vkCreateImage' : 262,
319'vkCreateImageView' : 263,
320'vkCreateIndirectCommandsLayoutNVX' : 264,
321'vkCreateInstance' : 265,
322'vkCreateMacOSSurfaceMVK' : 266,
323'vkCreateMirSurfaceKHR' : 267,
324'vkCreateObjectTableNVX' : 268,
325'vkCreatePipelineCache' : 269,
326'vkCreatePipelineLayout' : 270,
327'vkCreateQueryPool' : 271,
328'vkCreateRenderPass' : 272,
329'vkCreateSampler' : 273,
330'vkCreateSemaphore' : 274,
331'vkCreateShaderModule' : 275,
332'vkCreateSharedSwapchainsKHR' : 276,
333'vkCreateSwapchainKHR' : 277,
334'vkCreateViSurfaceNN' : 278,
335'vkCreateWaylandSurfaceKHR' : 279,
336'vkCreateWin32SurfaceKHR' : 280,
337'vkCreateXcbSurfaceKHR' : 281,
338'vkCreateXlibSurfaceKHR' : 282,
339'vkDebugMarkerSetObjectNameEXT' : 283,
340'vkDebugMarkerSetObjectTagEXT' : 284,
341'vkDebugReportMessageEXT' : 285,
342'vkDestroyBuffer' : 286,
343'vkDestroyBufferView' : 287,
344'vkDestroyCommandPool' : 288,
345'vkDestroyDebugReportCallbackEXT' : 289,
346'vkDestroyDescriptorPool' : 290,
347'vkDestroyDescriptorSetLayout' : 291,
348'vkDestroyDescriptorUpdateTemplateKHR' : 292,
349'vkDestroyDevice' : 293,
350'vkDestroyEvent' : 294,
351'vkDestroyFence' : 295,
352'vkDestroyFramebuffer' : 296,
353'vkDestroyImage' : 297,
354'vkDestroyImageView' : 298,
355'vkDestroyIndirectCommandsLayoutNVX' : 299,
356'vkDestroyInstance' : 300,
357'vkDestroyObjectTableNVX' : 301,
358'vkDestroyPipeline' : 302,
359'vkDestroyPipelineCache' : 303,
360'vkDestroyPipelineLayout' : 304,
361'vkDestroyQueryPool' : 305,
362'vkDestroyRenderPass' : 306,
363'vkDestroySampler' : 307,
364'vkDestroySemaphore' : 308,
365'vkDestroyShaderModule' : 309,
366'vkDestroySurfaceKHR' : 310,
367'vkDestroySwapchainKHR' : 311,
368'vkDeviceWaitIdle' : 312,
369'vkDisplayPowerControlEXT' : 313,
370'vkEndCommandBuffer' : 314,
371'vkEnumerateDeviceExtensionProperties' : 315,
372'vkEnumerateDeviceLayerProperties' : 316,
373'vkEnumerateInstanceExtensionProperties' : 317,
374'vkEnumerateInstanceLayerProperties' : 318,
375'vkEnumeratePhysicalDeviceGroupsKHX' : 319,
376'vkEnumeratePhysicalDevices' : 320,
377'vkFlushMappedMemoryRanges' : 321,
378'vkFreeCommandBuffers' : 322,
379'vkFreeDescriptorSets' : 323,
380'vkFreeMemory' : 324,
381'vkGetBufferMemoryRequirements' : 325,
382'vkGetDeviceGroupPeerMemoryFeaturesKHX' : 326,
383'vkGetDeviceGroupPresentCapabilitiesKHX' : 327,
384'vkGetDeviceGroupSurfacePresentModesKHX' : 328,
385'vkGetDeviceMemoryCommitment' : 329,
386'vkGetDeviceProcAddr' : 330,
387'vkGetDeviceQueue' : 331,
388'vkGetDisplayModePropertiesKHR' : 332,
389'vkGetDisplayPlaneCapabilitiesKHR' : 333,
390'vkGetDisplayPlaneSupportedDisplaysKHR' : 334,
391'vkGetEventStatus' : 335,
392'vkGetFenceStatus' : 336,
393'vkGetImageMemoryRequirements' : 337,
394'vkGetImageSparseMemoryRequirements' : 338,
395'vkGetImageSubresourceLayout' : 339,
396'vkGetInstanceProcAddr' : 340,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600397'vkGetMemoryFdKHR' : 341,
398'vkGetMemoryFdPropertiesKHR' : 342,
399'vkGetMemoryWin32HandleKHR' : 343,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600400'vkGetMemoryWin32HandleNV' : 344,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600401'vkGetMemoryWin32HandlePropertiesKHR' : 345,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600402'vkGetPastPresentationTimingGOOGLE' : 346,
403'vkGetPhysicalDeviceDisplayPlanePropertiesKHR' : 347,
404'vkGetPhysicalDeviceDisplayPropertiesKHR' : 348,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600405'vkGetPhysicalDeviceExternalBufferPropertiesKHR' : 349,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600406'vkGetPhysicalDeviceExternalImageFormatPropertiesNV' : 350,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600407'vkGetPhysicalDeviceExternalSemaphorePropertiesKHR' : 351,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600408'vkGetPhysicalDeviceFeatures' : 352,
409'vkGetPhysicalDeviceFeatures2KHR' : 353,
410'vkGetPhysicalDeviceFormatProperties' : 354,
411'vkGetPhysicalDeviceFormatProperties2KHR' : 355,
412'vkGetPhysicalDeviceGeneratedCommandsPropertiesNVX' : 356,
413'vkGetPhysicalDeviceImageFormatProperties' : 357,
414'vkGetPhysicalDeviceImageFormatProperties2KHR' : 358,
415'vkGetPhysicalDeviceMemoryProperties' : 359,
416'vkGetPhysicalDeviceMemoryProperties2KHR' : 360,
417'vkGetPhysicalDeviceMirPresentationSupportKHR' : 361,
418'vkGetPhysicalDevicePresentRectanglesKHX' : 362,
419'vkGetPhysicalDeviceProperties' : 363,
420'vkGetPhysicalDeviceProperties2KHR' : 364,
421'vkGetPhysicalDeviceQueueFamilyProperties' : 365,
422'vkGetPhysicalDeviceQueueFamilyProperties2KHR' : 366,
423'vkGetPhysicalDeviceSparseImageFormatProperties' : 367,
424'vkGetPhysicalDeviceSparseImageFormatProperties2KHR' : 368,
425'vkGetPhysicalDeviceSurfaceCapabilities2EXT' : 369,
426'vkGetPhysicalDeviceSurfaceCapabilities2KHR' : 370,
427'vkGetPhysicalDeviceSurfaceCapabilitiesKHR' : 371,
428'vkGetPhysicalDeviceSurfaceFormats2KHR' : 372,
429'vkGetPhysicalDeviceSurfaceFormatsKHR' : 373,
430'vkGetPhysicalDeviceSurfacePresentModesKHR' : 374,
431'vkGetPhysicalDeviceSurfaceSupportKHR' : 375,
432'vkGetPhysicalDeviceWaylandPresentationSupportKHR' : 376,
433'vkGetPhysicalDeviceWin32PresentationSupportKHR' : 377,
434'vkGetPhysicalDeviceXcbPresentationSupportKHR' : 378,
435'vkGetPhysicalDeviceXlibPresentationSupportKHR' : 379,
436'vkGetPipelineCacheData' : 380,
437'vkGetQueryPoolResults' : 381,
438'vkGetRandROutputDisplayEXT' : 382,
439'vkGetRefreshCycleDurationGOOGLE' : 383,
440'vkGetRenderAreaGranularity' : 384,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600441'vkGetSemaphoreFdKHR' : 385,
442'vkGetSemaphoreWin32HandleKHR' : 386,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600443'vkGetSwapchainCounterEXT' : 387,
444'vkGetSwapchainImagesKHR' : 388,
445'vkGetSwapchainStatusKHR' : 389,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600446'vkImportSemaphoreFdKHR' : 390,
447'vkImportSemaphoreWin32HandleKHR' : 391,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600448'vkInvalidateMappedMemoryRanges' : 392,
449'vkMapMemory' : 393,
450'vkMergePipelineCaches' : 394,
451'vkQueueBindSparse' : 395,
452'vkQueuePresentKHR' : 396,
453'vkQueueSubmit' : 397,
454'vkQueueWaitIdle' : 398,
455'vkRegisterDeviceEventEXT' : 399,
456'vkRegisterDisplayEventEXT' : 400,
457'vkRegisterObjectsNVX' : 401,
458'vkReleaseDisplayEXT' : 402,
459'vkResetCommandBuffer' : 403,
460'vkResetCommandPool' : 404,
461'vkResetDescriptorPool' : 405,
462'vkResetEvent' : 406,
463'vkResetFences' : 407,
464'vkSetEvent' : 408,
465'vkSetHdrMetadataEXT' : 409,
466'vkTrimCommandPoolKHR' : 410,
467'vkUnmapMemory' : 411,
468'vkUnregisterObjectsNVX' : 412,
469'vkUpdateDescriptorSetWithTemplateKHR' : 413,
470'vkUpdateDescriptorSets' : 414,
471'vkWaitForFences' : 415,
Mark Lobodzinski52295372017-06-21 11:54:54 -0600472'VkPhysicalDeviceProperties2KHR' : 416,
473'VkFormatProperties2KHR' : 417,
474'VkImageFormatProperties2KHR' : 418,
475'VkPhysicalDeviceMemoryProperties2KHR' : 419,
476'VkSurfaceCapabilities2KHR' : 420,
477'VkDeviceGroupPresentCapabilitiesKHX' : 421,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600478'VkExternalBufferPropertiesKHR' : 422,
479'VkMemoryWin32HandlePropertiesKHR' : 423,
480'VkMemoryFdPropertiesKHR' : 424,
481'VkExternalSemaphorePropertiesKHR' : 425,
Mark Lobodzinskida9de782017-06-26 13:05:22 -0600482'VkQueueFamilyProperties2KHR' : 426,
483'VkSparseImageFormatProperties2KHR' : 427,
484'VkSurfaceFormat2KHR' : 428,
485'VkTextureLODGatherFormatPropertiesAMD' : 429,
486'VkPhysicalDeviceMultiviewPropertiesKHX' : 430,
487'VkPhysicalDeviceGroupPropertiesKHX' : 431,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600488'VkExternalImageFormatPropertiesKHR' : 432,
489'VkPhysicalDeviceIDPropertiesKHR' : 433,
Mark Lobodzinskida9de782017-06-26 13:05:22 -0600490'VkPhysicalDeviceMultiviewPerViewAttributesPropertiesNVX' : 434,
491'VkHdrMetadataEXT' : 435,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600492'VkExternalMemoryPropertiesKHR' : 436,
Mark Lobodzinski4e39cc62017-06-27 13:21:03 -0600493'VkFormatProperties' : 437,
494'VkImageFormatProperties' : 438,
495'VkPhysicalDeviceLimits' : 439,
496'VkQueueFamilyProperties' : 440,
497'VkMemoryType' : 441,
498'VkMemoryHeap' : 442,
499'VkSparseImageFormatProperties' : 443,
500'VkSurfaceCapabilitiesKHR' : 444,
501'VkDisplayPropertiesKHR' : 445,
502'VkDisplayPlaneCapabilitiesKHR' : 446,
503'VkSharedPresentSurfaceCapabilitiesKHR' : 447,
504'VkExternalImageFormatPropertiesNV' : 448,
Mark Lobodzinskie5b2b712017-06-28 14:58:27 -0600505'VkPhysicalDeviceBlendOperationAdvancedFeaturesEXT' : 449,
506'VkPhysicalDeviceBlendOperationAdvancedPropertiesEXT' : 450,
507'VkPhysicalDeviceSamplerFilterMinmaxPropertiesEXT' : 451,
508'VkPipelineColorBlendAdvancedStateCreateInfoEXT' : 452,
509'VkPipelineCoverageModulationStateCreateInfoNV' : 453,
510'VkPipelineCoverageToColorStateCreateInfoNV' : 454,
511'VkSamplerReductionModeCreateInfoEXT' : 455,
Mark Lobodzinski42eb3c32017-06-28 11:47:22 -0600512'VkPhysicalDeviceProperties' : 456,
513'VkSurfaceFormatKHR' : 457,
Mark Youngabc2d6e2017-07-07 07:59:56 -0600514'VkExportFenceCreateInfoKHR' : 458,
515'VkPhysicalDeviceExternalFenceInfoKHR' : 459,
516'VkExternalFencePropertiesKHR' : 460,
517'vkGetPhysicalDeviceExternalFencePropertiesKHR' : 461,
518'VkImportFenceFdInfoKHR' : 462,
519'VkFenceGetFdInfoKHR' : 463,
520'vkImportFenceFdKHR' : 464,
521'vkGetFenceFdKHR' : 465,
522'VkImportFenceWin32HandleInfoKHR' : 466,
523'VkExportFenceWin32HandleInfoKHR' : 467,
524'VkFenceGetWin32HandleInfoKHR' : 468,
525'vkImportFenceWin32HandleKHR' : 469,
526'vkGetFenceWin32HandleKHR' : 470,
527'VkSemaphoreGetFdInfoKHR' : 471,
528'VkSemaphoreGetWin32HandleInfoKHR' : 472,
529'VkMemoryGetFdInfoKHR' : 473,
530'VkMemoryGetWin32HandleInfoKHR' : 474,
531'VkMemoryDedicatedRequirementsKHR' : 475,
532'VkMemoryDedicatedAllocateInfoKHR' : 476,
533'VkBufferMemoryRequirementsInfo2KHR' : 477,
534'VkImageMemoryRequirementsInfo2KHR' : 478,
535'VkImageSparseMemoryRequirementsInfo2KHR' : 479,
536'VkMemoryRequirements2KHR' : 480,
537'VkSparseImageMemoryRequirements2KHR' : 481,
538'vkGetImageMemoryRequirements2KHR' : 482,
539'vkGetBufferMemoryRequirements2KHR' : 483,
540'vkGetImageSparseMemoryRequirements2KHR' : 484,
541'VkPhysicalDevice16BitStorageFeaturesKHR' : 485,
542'VkPhysicalDeviceVariablePointerFeaturesKHR' : 486,
Tobin Ehlis98d109a2017-05-11 14:42:38 -0600543### ADD New func/struct mappings above this line
544}
545# Mapping of params to unique IDs
546implicit_param_map = {
547'a' : 0,
548'addressModeU' : 1,
549'addressModeV' : 2,
550'addressModeW' : 3,
551'alphaBlendOp' : 4,
552'alphaMode' : 5,
553'aspectMask' : 6,
554'attachmentCount' : 7,
555'b' : 8,
556'back' : 9,
557'bindCount' : 10,
558'bindInfoCount' : 11,
559'bindingCount' : 12,
560'buffer' : 13,
561'bufferView' : 14,
562'callback' : 15,
563'colorBlendOp' : 16,
564'colorWriteMask' : 17,
565'commandBuffer' : 18,
566'commandBufferCount' : 19,
567'commandPool' : 20,
568'compareOp' : 21,
569'components' : 22,
570'compositeAlpha' : 23,
571'connection' : 24,
572'contents' : 25,
573'countBuffer' : 26,
574'counter' : 27,
575'createInfoCount' : 28,
576'cullMode' : 29,
577'dataSize' : 30,
578'dependencyFlags' : 31,
579'depthCompareOp' : 32,
580'depthFailOp' : 33,
581'descriptorCount' : 34,
582'descriptorPool' : 35,
583'descriptorSet' : 36,
584'descriptorSetCount' : 37,
585'descriptorSetLayout' : 38,
586'descriptorType' : 39,
587'descriptorUpdateEntryCount' : 40,
588'descriptorUpdateTemplate' : 41,
589'descriptorWriteCount' : 42,
590'device' : 43,
591'deviceEvent' : 44,
592'disabledValidationCheckCount' : 45,
593'discardRectangleCount' : 46,
594'discardRectangleMode' : 47,
595'display' : 48,
596'displayEvent' : 49,
597'displayMode' : 50,
598'dpy' : 51,
599'dstAccessMask' : 52,
600'dstAlphaBlendFactor' : 53,
601'dstBuffer' : 54,
602'dstCache' : 55,
603'dstColorBlendFactor' : 56,
604'dstImage' : 57,
605'dstImageLayout' : 58,
606'dstSet' : 59,
607'dstStageMask' : 60,
608'dstSubresource' : 61,
609'dynamicStateCount' : 62,
610'event' : 63,
611'eventCount' : 64,
612'externalHandleType' : 65,
613'faceMask' : 66,
614'failOp' : 67,
615'fence' : 68,
616'fenceCount' : 69,
617'filter' : 70,
618'finalLayout' : 71,
619'flags' : 72,
620'format' : 73,
621'framebuffer' : 74,
622'front' : 75,
623'frontFace' : 76,
624'g' : 77,
625'handleType' : 78,
626'handleTypes' : 79,
627'image' : 80,
628'imageColorSpace' : 81,
629'imageFormat' : 82,
630'imageLayout' : 83,
631'imageSharingMode' : 84,
632'imageSubresource' : 85,
633'imageType' : 86,
634'imageUsage' : 87,
635'imageView' : 88,
636'indexType' : 89,
637'indirectCommandsLayout' : 90,
638'indirectCommandsTokenCount' : 91,
639'initialLayout' : 92,
640'inputRate' : 93,
641'instance' : 94,
642'layout' : 95,
643'level' : 96,
644'loadOp' : 97,
645'magFilter' : 98,
646'memory' : 99,
647'memoryRangeCount' : 100,
648'minFilter' : 101,
649'mipmapMode' : 102,
650'mode' : 103,
651'modes' : 104,
652'module' : 105,
653'newLayout' : 106,
654'objectCount' : 107,
655'objectTable' : 108,
656'objectType' : 109,
657'oldLayout' : 110,
658'oldSwapchain' : 111,
659'pAcquireInfo' : 112,
660'pAcquireKeys' : 113,
661'pAcquireSyncs' : 114,
662'pAcquireTimeoutMilliseconds' : 115,
663'pAcquireTimeouts' : 116,
664'pAllocateInfo' : 117,
665'pAllocator' : 118,
666'pApplicationInfo' : 119,
667'pApplicationName' : 120,
668'pAttachments' : 121,
669'pAttributes' : 122,
670'pBeginInfo' : 123,
671'pBindInfo' : 124,
672'pBindInfos' : 125,
673'pBindings' : 126,
674'pBinds' : 127,
675'pBuffer' : 128,
676'pBufferBinds' : 129,
677'pBufferMemoryBarriers' : 130,
678'pBuffers' : 131,
679'pCallback' : 132,
680'pCapabilities' : 133,
681'pCode' : 134,
682'pColor' : 135,
683'pColorAttachments' : 136,
684'pCommandBufferDeviceMasks' : 137,
685'pCommandBuffers' : 138,
686'pCommandPool' : 139,
687'pCommittedMemoryInBytes' : 140,
688'pCorrelationMasks' : 141,
689'pCounterValue' : 142,
690'pCreateInfo' : 143,
691'pCreateInfos' : 144,
692'pData' : 145,
693'pDataSize' : 146,
694'pDependencies' : 147,
695'pDepthStencil' : 148,
696'pDepthStencilAttachment' : 149,
697'pDescriptorCopies' : 150,
698'pDescriptorPool' : 151,
699'pDescriptorSets' : 152,
700'pDescriptorUpdateEntries' : 153,
701'pDescriptorUpdateTemplate' : 154,
702'pDescriptorWrites' : 155,
703'pDevice' : 156,
704'pDeviceEventInfo' : 157,
705'pDeviceGroupPresentCapabilities' : 158,
706'pDeviceIndices' : 159,
707'pDeviceMasks' : 160,
708'pDeviceRenderAreas' : 161,
709'pDisabledValidationChecks' : 162,
710'pDiscardRectangles' : 163,
711'pDisplay' : 164,
712'pDisplayCount' : 165,
713'pDisplayEventInfo' : 166,
714'pDisplayPowerInfo' : 167,
715'pDisplayTimingProperties' : 168,
716'pDisplays' : 169,
717'pDynamicOffsets' : 170,
718'pDynamicState' : 171,
719'pDynamicStates' : 172,
720'pEnabledFeatures' : 173,
721'pEngineName' : 174,
722'pEvent' : 175,
723'pEvents' : 176,
724'pExternalBufferInfo' : 177,
725'pExternalBufferProperties' : 178,
726'pExternalImageFormatProperties' : 179,
727'pExternalSemaphoreInfo' : 180,
728'pExternalSemaphoreProperties' : 181,
729'pFd' : 182,
730'pFeatures' : 183,
731'pFence' : 184,
732'pFences' : 185,
733'pFormatInfo' : 186,
734'pFormatProperties' : 187,
735'pFramebuffer' : 188,
736'pGranularity' : 189,
737'pHandle' : 190,
738'pImage' : 191,
739'pImageBinds' : 192,
740'pImageFormatInfo' : 193,
741'pImageFormatProperties' : 194,
742'pImageIndex' : 195,
743'pImageIndices' : 196,
744'pImageMemoryBarriers' : 197,
745'pImageOpaqueBinds' : 198,
746'pImportSemaphoreFdInfo' : 199,
747'pImportSemaphoreWin32HandleInfo' : 200,
748'pIndirectCommandsLayout' : 201,
749'pIndirectCommandsTokens' : 202,
750'pInitialData' : 203,
751'pInputAssemblyState' : 204,
752'pInputAttachments' : 205,
753'pInstance' : 206,
754'pLayerName' : 207,
755'pLayerPrefix' : 208,
756'pLayout' : 209,
757'pLimits' : 210,
758'pMarkerInfo' : 211,
759'pMarkerName' : 212,
760'pMemory' : 213,
761'pMemoryBarriers' : 214,
762'pMemoryFdProperties' : 215,
763'pMemoryProperties' : 216,
764'pMemoryRanges' : 217,
765'pMemoryRequirements' : 218,
766'pMemoryWin32HandleProperties' : 219,
767'pMessage' : 220,
768'pMetadata' : 221,
769'pMode' : 222,
770'pModes' : 223,
771'pName' : 224,
772'pNameInfo' : 225,
773'pNext' : 226,
774'pObjectEntryCounts' : 227,
775'pObjectEntryTypes' : 228,
776'pObjectEntryUsageFlags' : 229,
777'pObjectIndices' : 230,
778'pObjectName' : 231,
779'pObjectTable' : 232,
780'pOffsets' : 233,
781'pPeerMemoryFeatures' : 234,
782'pPhysicalDeviceCount' : 235,
783'pPhysicalDeviceGroupCount' : 236,
784'pPhysicalDeviceGroupProperties' : 237,
785'pPhysicalDevices' : 238,
786'pPipelineCache' : 239,
787'pPipelineLayout' : 240,
788'pPipelines' : 241,
789'pPoolSizes' : 242,
790'pPresentInfo' : 243,
791'pPresentModeCount' : 244,
792'pPresentModes' : 245,
793'pPresentationTimingCount' : 246,
794'pPresentationTimings' : 247,
795'pPreserveAttachments' : 248,
796'pProcessCommandsInfo' : 249,
797'pProperties' : 250,
798'pPropertyCount' : 251,
799'pPushConstantRanges' : 252,
800'pQueryPool' : 253,
801'pQueue' : 254,
802'pQueueCreateInfos' : 255,
803'pQueueFamilyProperties' : 256,
804'pQueueFamilyPropertyCount' : 257,
805'pQueuePriorities' : 258,
806'pRanges' : 259,
807'pRasterizationState' : 260,
808'pRectCount' : 261,
809'pRectangles' : 262,
810'pRects' : 263,
811'pRegions' : 264,
812'pReleaseKeys' : 265,
813'pReleaseSyncs' : 266,
814'pRenderPass' : 267,
815'pRenderPassBegin' : 268,
816'pReserveSpaceInfo' : 269,
817'pResolveAttachments' : 270,
818'pResults' : 271,
819'pSFRRects' : 272,
820'pSampleMask' : 273,
821'pSampler' : 274,
822'pScissors' : 275,
823'pSemaphore' : 276,
824'pSetLayout' : 277,
825'pSetLayouts' : 278,
826'pShaderModule' : 279,
827'pSignalSemaphoreDeviceIndices' : 280,
828'pSignalSemaphoreValues' : 281,
829'pSignalSemaphores' : 282,
830'pSparseMemoryRequirementCount' : 283,
831'pSparseMemoryRequirements' : 284,
832'pSpecializationInfo' : 285,
833'pSrcCaches' : 286,
834'pStages' : 287,
835'pSubmits' : 288,
836'pSubpasses' : 289,
837'pSubresource' : 290,
838'pSupported' : 291,
839'pSurface' : 292,
840'pSurfaceCapabilities' : 293,
841'pSurfaceFormatCount' : 294,
842'pSurfaceFormats' : 295,
843'pSurfaceInfo' : 296,
844'pSwapchain' : 297,
845'pSwapchainImageCount' : 298,
846'pSwapchainImages' : 299,
847'pSwapchains' : 300,
848'pTag' : 301,
849'pTagInfo' : 302,
850'pTimes' : 303,
851'pTokens' : 304,
852'pValues' : 305,
853'pVertexAttributeDescriptions' : 306,
854'pVertexBindingDescriptions' : 307,
855'pVertexInputState' : 308,
856'pView' : 309,
857'pViewMasks' : 310,
858'pViewOffsets' : 311,
859'pWaitDstStageMask' : 312,
860'pWaitSemaphoreDeviceIndices' : 313,
861'pWaitSemaphoreValues' : 314,
862'pWaitSemaphores' : 315,
863'passOp' : 316,
864'physicalDevice' : 317,
865'pipeline' : 318,
866'pipelineBindPoint' : 319,
867'pipelineCache' : 320,
868'pipelineLayout' : 321,
869'pipelineStage' : 322,
870'polygonMode' : 323,
871'poolSizeCount' : 324,
872'powerState' : 325,
873'ppData' : 326,
874'ppEnabledExtensionNames' : 327,
875'ppEnabledLayerNames' : 328,
876'ppObjectTableEntries' : 329,
877'preTransform' : 330,
878'presentMode' : 331,
879'queryPool' : 332,
880'queryType' : 333,
881'queue' : 334,
882'queueCount' : 335,
883'queueCreateInfoCount' : 336,
884'r' : 337,
885'rangeCount' : 338,
886'rasterizationOrder' : 339,
887'rasterizationSamples' : 340,
888'rectCount' : 341,
889'regionCount' : 342,
890'renderPass' : 343,
891'sType' : 344,
892'sampler' : 345,
893'samples' : 346,
894'scissorCount' : 347,
895'semaphore' : 348,
896'sequencesCountBuffer' : 349,
897'sequencesIndexBuffer' : 350,
898'shaderModule' : 351,
899'sharingMode' : 352,
900'size' : 353,
901'srcAccessMask' : 354,
902'srcAlphaBlendFactor' : 355,
903'srcBuffer' : 356,
904'srcCacheCount' : 357,
905'srcColorBlendFactor' : 358,
906'srcImage' : 359,
907'srcImageLayout' : 360,
908'srcSet' : 361,
909'srcStageMask' : 362,
910'srcSubresource' : 363,
911'stage' : 364,
912'stageCount' : 365,
913'stageFlags' : 366,
914'stageMask' : 367,
915'stencilLoadOp' : 368,
916'stencilStoreOp' : 369,
917'storeOp' : 370,
918'subpassCount' : 371,
919'subresource' : 372,
920'subresourceRange' : 373,
921'surface' : 374,
922'surfaceCounters' : 375,
923'swapchain' : 376,
924'swapchainCount' : 377,
925'tagSize' : 378,
926'targetCommandBuffer' : 379,
927'templateType' : 380,
928'tiling' : 381,
929'tokenCount' : 382,
930'tokenType' : 383,
931'topology' : 384,
932'transform' : 385,
933'type' : 386,
934'usage' : 387,
935'viewType' : 388,
936'viewportCount' : 389,
937'w' : 390,
938'window' : 391,
939'x' : 392,
940'y' : 393,
941'z' : 394,
Mark Lobodzinskicb6f56f2017-06-26 16:04:27 -0600942'externalMemoryFeatures' : 395,
943'compatibleHandleTypes' : 396,
944'exportFromImportedHandleTypes' : 397,
Mark Lobodzinski4e39cc62017-06-27 13:21:03 -0600945'linearTilingFeatures' : 398,
946'optimalTilingFeatures' : 399,
947'bufferFeatures' : 400,
948'sampleCounts' : 401,
949'framebufferColorSampleCounts' : 402,
950'framebufferDepthSampleCounts' : 403,
951'framebufferStencilSampleCounts' : 404,
952'framebufferNoAttachmentsSampleCounts' : 405,
953'sampledImageColorSampleCounts' : 406,
954'sampledImageIntegerSampleCounts' : 407,
955'sampledImageDepthSampleCounts' : 408,
956'sampledImageStencilSampleCounts' : 409,
957'storageImageSampleCounts' : 410,
958'queueFlags' : 411,
959'propertyFlags' : 412,
960'supportedTransforms' : 413,
961'currentTransform' : 414,
962'supportedCompositeAlpha' : 415,
963'supportedUsageFlags' : 416,
964'supportedAlpha' : 417,
965'sharedPresentSupportedUsageFlags' : 418,
966'externalSemaphoreFeatures' : 419,
967'supportedSurfaceCounters' : 420,
Mark Lobodzinskie5b2b712017-06-28 14:58:27 -0600968'blendOverlap' : 421,
969'coverageModulationMode' : 422,
970'coverageModulationTableCount' : 423,
971'reductionMode' : 424,
Mark Lobodzinski63aebd32017-06-28 10:54:26 -0600972'enabledLayerCount' : 425,
973'enabledExtensionCount' : 426,
974'waitSemaphoreCount' : 427,
975'signalSemaphoreCount' : 428,
976'bufferBindCount' : 429,
977'imageOpaqueBindCount' : 430,
978'imageBindCount' : 431,
979'codeSize' : 432,
980'initialDataSize' : 433,
981'vertexBindingDescriptionCount' : 434,
982'vertexAttributeDescriptionCount' : 435,
983'setLayoutCount' : 436,
984'pushConstantRangeCount' : 437,
985'inputAttachmentCount' : 438,
986'colorAttachmentCount' : 439,
987'preserveAttachmentCount' : 440,
988'dependencyCount' : 441,
989'dynamicOffsetCount' : 442,
990'rectangleCount' : 443,
991'correlationMaskCount' : 444,
992'acquireCount' : 445,
993'releaseCount' : 446,
994'deviceIndexCount' : 447,
995'SFRRectCount' : 448,
996'deviceRenderAreaCount' : 449,
997'physicalDeviceCount' : 450,
998'waitSemaphoreValuesCount' : 451,
999'signalSemaphoreValuesCount' : 452,
Mark Lobodzinski42eb3c32017-06-28 11:47:22 -06001000'deviceType' : 453,
1001'colorSpace' : 454,
Mark Lobodzinskie1cce092017-06-28 13:21:27 -06001002'pfnAllocation' : 455,
1003'pfnReallocation' : 556,
1004'pfnFree' : 457,
1005'blendConstants' : 458,
1006'displayName' : 459,
1007'pfnCallback' : 460,
Mark Youngabc2d6e2017-07-07 07:59:56 -06001008'externalFenceFeatures' : 461,
1009'pInfo' : 462,
1010'pGetFdInfo' : 463,
1011'pGetWin32HandleInfo' : 464,
1012'pExternalFenceInfo' : 465,
1013'pExternalFenceProperties' : 466,
1014'pImportFenceProperties' : 467,
1015'pImportFenceFdInfo' : 468,
1016'pImportFenceWin32HandleInfo' : 469,
Mark Lobodzinski92df8b42017-07-20 10:38:46 -06001017'basePipelineHandle' : 470,
1018'pImmutableSamplers' : 471,
1019'pTexelBufferView' : 472,
Tobin Ehlis98d109a2017-05-11 14:42:38 -06001020### ADD New implicit param mappings above this line
1021}
1022
1023uniqueid_set = set() # store uniqueid to make sure we don't have duplicates
1024
1025# Convert a string VUID into numerical value
1026# See "VUID Mapping Details" comment above for more info
1027def convertVUID(vuid_string):
1028 """Convert a string-based VUID into a numberical value"""
1029 #func_struct_update = False
1030 #imp_param_update = False
1031 if vuid_string in ['', None]:
1032 return -1
1033 vuid_parts = vuid_string.split('-')
1034 if vuid_parts[1] not in func_struct_id_map:
1035 print ("ERROR: Missing func/struct map value for '%s'!" % (vuid_parts[1]))
1036 print (" TODO: Need to add mapping for this to end of func_struct_id_map")
1037 print (" replace '### ADD New func/struct mappings above this line' line with \"'%s' : %d,\"" % (vuid_parts[1], len(func_struct_id_map)))
1038 func_struct_id_map[vuid_parts[1]] = len(func_struct_id_map)
1039 #func_struct_update = True
1040 sys.exit()
1041 uniqueid = func_struct_id_map[vuid_parts[1]] << FUNC_STRUCT_SHIFT
1042 if vuid_parts[-1].isdigit(): # explit VUID has int on the end
1043 explicit_id = int(vuid_parts[-1])
1044 # For explicit case, id is explicit_base + func/struct mapping + unique id
1045 uniqueid = uniqueid + (explicit_id << EXPLICIT_ID_SHIFT) + explicit_bit0
1046 else: # implicit case
1047 if vuid_parts[-1] not in implicit_type_map:
1048 print("ERROR: Missing mapping for implicit type '%s'!\nTODO: Please add new mapping." % (vuid_parts[-1]))
1049 sys.exit()
1050 else:
1051 param_id = 0 # Default when no param is available
1052 if vuid_parts[-2] != vuid_parts[1]: # we have a parameter
1053 if vuid_parts[-2] in implicit_param_map:
1054 param_id = implicit_param_map[vuid_parts[-2]]
1055 else:
1056 print ("ERROR: Missing param '%s' from implicit_param_map\n TODO: Please add new mapping." % (vuid_parts[-2]))
1057 print (" replace '### ADD New implicit param mappings above this line' line with \"'%s' : %d,\"" % (vuid_parts[-2], len(implicit_param_map)))
1058 implicit_param_map[vuid_parts[-2]] = len(implicit_param_map)
1059 #imp_param_update = True
1060 sys.exit()
1061 uniqueid = uniqueid + (param_id << IMPLICIT_PARAM_SHIFT) + (implicit_type_map[vuid_parts[-1]] << IMPLICIT_TYPE_SHIFT) + implicit_bit0
1062 else: # No parameter so that field is 0
1063 uniqueid = uniqueid + (implicit_type_map[vuid_parts[-1]] << IMPLICIT_TYPE_SHIFT) + implicit_bit0
Tobin Ehlis3c37fb32017-05-24 09:31:13 -06001064# if uniqueid in uniqueid_set:
1065# print ("ERROR: Uniqueid %d for string id %s is a duplicate!" % (uniqueid, vuid_string))
1066# print (" TODO: Figure out what caused the dupe and fix it")
1067 #sys.exit()
Mark Lobodzinskifb842d52017-06-21 12:21:34 -06001068 # print ("Storing uniqueid %d for unique string %s" % (uniqueid, vuid_string))
Tobin Ehlis98d109a2017-05-11 14:42:38 -06001069 uniqueid_set.add(uniqueid)
1070# if func_struct_update:
1071# print ("func_struct_id_map updated, here's new structure")
1072# print ("func_struct_id_map = {")
1073# fs_id = 0
1074# for fs in sorted(func_struct_id_map):
1075# print ("'%s' : %d," % (fs, fs_id))
1076# fs_id = fs_id + 1
1077# print ("### ADD New func/struct mappings above this line")
1078# print ("}")
1079# if imp_param_update:
1080# print ("implicit_param_map updated, here's new structure")
1081# print ("implicit_param_map = {")
1082# ip_id = 0
1083# for ip in sorted(implicit_param_map):
1084# print ("'%s' : %d," % (ip, ip_id))
1085# ip_id = ip_id + 1
1086# print ("### ADD New implicit param mappings above this line")
1087# print ("}")
1088
1089 return uniqueid