diff --git a/chapters/VK_KHR_display/display.txt b/chapters/VK_KHR_display/display.txt
index a41de9ed..0b3f43aa 100644
--- a/chapters/VK_KHR_display/display.txt
+++ b/chapters/VK_KHR_display/display.txt
@@ -411,6 +411,13 @@ include::../../api/structs/VkDisplayModeParametersKHR.txt[]
For example, a 60Hz display mode would report a pname:refreshRate of 60,000.
====
+.Valid Usage
+****
+ * The pname:width member of pname:visibleRegion must: be greater than `0`
+ * The pname:height member of pname:visibleRegion must: be greater than `0`
+ * pname:refreshRate must: be greater than `0`
+****
+
include::../../validity/structs/VkDisplayModeParametersKHR.txt[]
--
@@ -449,16 +456,6 @@ include::../../api/structs/VkDisplayModeCreateInfoKHR.txt[]
If the parameters are not compatible with the specified display, the
implementation must: return ename:VK_ERROR_INITIALIZATION_FAILED.
-.Valid Usage
-****
- * [[VUID-VkDisplayModeCreateInfoKHR-width-01250]]
- The pname:width and pname:height members of the pname:visibleRegion
- member of pname:parameters must: be greater than `0`
- * [[VUID-VkDisplayModeCreateInfoKHR-refreshRate-01251]]
- The pname:refreshRate member of pname:parameters must: be greater than
- `0`
-****
-
include::../../validity/structs/VkDisplayModeCreateInfoKHR.txt[]
--
diff --git a/chapters/clears.txt b/chapters/clears.txt
index 558f6b35..0e2d6dcf 100644
--- a/chapters/clears.txt
+++ b/chapters/clears.txt
@@ -465,13 +465,6 @@ This union is used where part of the API requires either color or
depth/stencil clear values, depending on the attachment, and defines the
initial clear values in the slink:VkRenderPassBeginInfo structure.
-.Valid Usage
-****
- * [[VUID-VkClearValue-depthStencil-00023]]
- pname:depthStencil must: be a valid sname:VkClearDepthStencilValue
- structure
-****
-
include::../validity/structs/VkClearValue.txt[]
--
diff --git a/chapters/copies.txt b/chapters/copies.txt
index cb0369b5..6db93f7c 100644
--- a/chapters/copies.txt
+++ b/chapters/copies.txt
@@ -107,9 +107,6 @@ memory.
.Valid Usage
****
- * [[VUID-vkCmdCopyBuffer-size-00112]]
- The pname:size member of each element of pname:pRegions must: be greater
- than `0`
* [[VUID-vkCmdCopyBuffer-srcOffset-00113]]
The pname:srcOffset member of each element of pname:pRegions must: be
less than the size of pname:srcBuffer
@@ -167,6 +164,11 @@ include::../api/structs/VkBufferCopy.txt[]
pname:dstBuffer.
* pname:size is the number of bytes to copy.
+.Valid Usage
+****
+ * The pname:size must: be greater than `0`
+****
+
include::../validity/structs/VkBufferCopy.txt[]
--
diff --git a/chapters/pipelines.txt b/chapters/pipelines.txt
index 67e59737..4b914732 100644
--- a/chapters/pipelines.txt
+++ b/chapters/pipelines.txt
@@ -648,7 +648,8 @@ endif::VK_VERSION_1_1,VK_KHR_maintenance2[]
If no element of the pname:pDynamicStates member of pname:pDynamicState
is ename:VK_DYNAMIC_STATE_VIEWPORT, the pname:pViewports member of
pname:pViewportState must: be a valid pointer to an array of
- pname:pViewportState::pname:viewportCount sname:VkViewport structures
+ pname:pViewportState::pname:viewportCount valid sname:VkViewport
+ structures
* [[VUID-VkGraphicsPipelineCreateInfo-pDynamicStates-00748]]
If no element of the pname:pDynamicStates member of pname:pDynamicState
is ename:VK_DYNAMIC_STATE_SCISSOR, the pname:pScissors member of
@@ -1466,10 +1467,6 @@ slink:VkSpecializationMapEntry.
* [[VUID-VkSpecializationInfo-pMapEntries-00774]]
The pname:size member of each element of pname:pMapEntries must: be less
than or equal to pname:dataSize minus pname:offset
- * [[VUID-VkSpecializationInfo-mapEntryCount-00775]]
- If pname:mapEntryCount is not `0`, pname:pMapEntries must: be a valid
- pointer to an array of pname:mapEntryCount valid
- sname:VkSpecializationMapEntry structures
****
include::../validity/structs/VkSpecializationInfo.txt[]
diff --git a/registry.txt b/registry.txt
index 4ee37613..01c8b4cf 100644
--- a/registry.txt
+++ b/registry.txt
@@ -501,6 +501,8 @@ member.
* attr:noautovalidity - prevents automatic validity language being
generated for the tagged item. Only suppresses item-specific
validity - parenting issues etc. are still captured.
+ It must also be used for structures that have no implicit validity when
+ such structure has explicit validity.
==== Contents of tag:member tags
diff --git a/xml/validitygenerator.py b/xml/validitygenerator.py
index 57f612f7..5c88f8a7 100644
--- a/xml/validitygenerator.py
+++ b/xml/validitygenerator.py
@@ -466,11 +466,14 @@ class ValidityOutputGenerator(OutputGenerator):
return asciidoc
- # Try to do check if a structure is always considered valid (i.e. there's no rules to its acceptance)
+ # Check if a structure is always considered valid (i.e. there are no rules to its acceptance)
def isStructAlwaysValid(self, blockname, structname):
struct = self.registry.tree.find("types/type[@name='" + structname + "']")
+ if struct.attrib.get('returnedonly') is not None:
+ return True
+
params = struct.findall('member')
for param in params:
@@ -484,6 +487,9 @@ class ValidityOutputGenerator(OutputGenerator):
if paramname.text == 'sType':
return False
+ if param.attrib.get('noautovalidity') is not None:
+ return False
+
if paramtype.text == 'void' or paramtype.text == 'char' or self.paramIsArray(param) or self.paramIsPointer(param):
if self.makeAsciiDocLineForParameter(blockname, param, params, '') != '':
return False
diff --git a/xml/vk.xml b/xml/vk.xml
index 4419c6fb..6e8606af 100644
--- a/xml/vk.xml
+++ b/xml/vk.xml
@@ -588,12 +588,12 @@ server.
uint32_t depth
- float x
- float y
- float width
- float height
- float minDepth
- float maxDepth
+ float x
+ float y
+ float width
+ float height
+ float minDepth
+ float maxDepth
VkOffset2D offset
@@ -642,11 +642,11 @@ server.
void* pUserData
- PFN_vkAllocationFunction pfnAllocation
- PFN_vkReallocationFunction pfnReallocation
- PFN_vkFreeFunction pfnFree
- PFN_vkInternalAllocationNotification pfnInternalAllocation
- PFN_vkInternalFreeNotification pfnInternalFree
+ PFN_vkAllocationFunction pfnAllocation
+ PFN_vkReallocationFunction pfnReallocation
+ PFN_vkFreeFunction pfnFree
+ PFN_vkInternalAllocationNotification pfnInternalAllocation
+ PFN_vkInternalFreeNotification pfnInternalFree
VkStructureType sType
@@ -874,9 +874,9 @@ server.
VkImageSubresourceRange subresourceRange
- VkDeviceSize srcOffsetSpecified in bytes
- VkDeviceSize dstOffsetSpecified in bytes
- VkDeviceSize sizeSpecified in bytes
+ VkDeviceSize srcOffsetSpecified in bytes
+ VkDeviceSize dstOffsetSpecified in bytes
+ VkDeviceSize sizeSpecified in bytes
VkDeviceSize resourceOffsetSpecified in bytes
@@ -991,13 +991,13 @@ server.
const VkDescriptorSetLayout* pSetLayouts
- uint32_t constantIDThe SpecConstant ID specified in the BIL
- uint32_t offsetOffset of the value in the data block
- size_t sizeSize in bytes of the SpecConstant
+ uint32_t constantIDThe SpecConstant ID specified in the BIL
+ uint32_t offsetOffset of the value in the data block
+ size_t sizeSize in bytes of the SpecConstant
uint32_t mapEntryCountNumber of entries in the map
- const VkSpecializationMapEntry* pMapEntriesArray of map entries
+ const VkSpecializationMapEntry* pMapEntriesArray of map entries
size_t dataSizeSize in bytes of pData
const void* pDataPointer to SpecConstant data
@@ -1518,22 +1518,22 @@ server.
uint32_t layers
- uint32_t vertexCount
- uint32_t instanceCount
- uint32_t firstVertex
- uint32_t firstInstance
+ uint32_t vertexCount
+ uint32_t instanceCount
+ uint32_t firstVertex
+ uint32_t firstInstance
- uint32_t indexCount
- uint32_t instanceCount
- uint32_t firstIndex
- int32_t vertexOffset
- uint32_t firstInstance
+ uint32_t indexCount
+ uint32_t instanceCount
+ uint32_t firstIndex
+ int32_t vertexOffset
+ uint32_t firstInstance
- uint32_t x
- uint32_t y
- uint32_t z
+ uint32_t x
+ uint32_t y
+ uint32_t z
VkStructureType sType
@@ -1562,7 +1562,7 @@ server.
VkExtent2D visibleRegionVisible scanout region.
- uint32_t refreshRateNumber of times per second the display is updated.
+ uint32_t refreshRateNumber of times per second the display is updated.
VkDisplayModeKHR displayModeHandle of this display mode.
@@ -1708,7 +1708,7 @@ server.
VkStructureType sTypeMust be VK_STRUCTURE_TYPE_VALIDATION_FLAGS_EXT
const void* pNext
uint32_t disabledValidationCheckCountNumber of validation checks to disable
- VkValidationCheckEXT* pDisabledValidationChecksValidation checks to disable
+ const VkValidationCheckEXT* pDisabledValidationChecksValidation checks to disable
VkStructureType sType
@@ -1971,7 +1971,7 @@ server.
VkOffset2D offsetupper-left corner of a rectangle that has not changed, in pixels of a presentation images
- VkExtent2D extentDimensions of a rectangle that has not changed, in pixels of a presentation images
+ VkExtent2D extentDimensions of a rectangle that has not changed, in pixels of a presentation images
uint32_t layerLayer of a swapchain's image(s), for stereoscopic-3D images
@@ -2440,10 +2440,10 @@ server.
float maxContentLightLevelContent maximum luminance
float maxFrameAverageLightLevel
-
+
uint64_t refreshDurationNumber of nanoseconds from the start of one refresh cycle to the next
-
+
uint32_t presentIDApplication-provided identifier, previously given to vkQueuePresentKHR
uint64_t desiredPresentTimeEarliest time an image should have been presented, previously given to vkQueuePresentKHR
uint64_t actualPresentTimeTime the image was actually displayed