xref: /aosp_15_r20/external/mesa3d/src/gfxstream/codegen/xml/vk_gfxstream.xml (revision 6104692788411f58d303aa86923a9ff6ecaded22)
1<?xml version="1.0" encoding="UTF-8"?>
2<registry>
3    <comment>
4Copyright 2023 Google LLC
5SPDX-License-Identifier: MIT
6    </comment>
7
8    <comment>
9This file, vk_gfxstream.xml, is the Vulkan API Registry for gfxstream
10specific entries.
11    </comment>
12        <types comment="Vulkan type definitions">
13        <!-- b/295587347 VkNativeBufferANDROID diverged from upstream -->
14        <type category="struct" name="VkNativeBufferANDROID" structextends="VkImageCreateInfo">
15            <member values="VK_STRUCTURE_TYPE_NATIVE_BUFFER_ANDROID"><type>VkStructureType</type> <name>sType</name></member>
16            <member optional="true">const <type>void</type>* <name>pNext</name></member>
17            <member noautovalidity="true">const <type>uint32_t</type>* <name>handle</name></member>
18            <member><type>int</type> <name>stride</name></member>
19            <member><type>int</type> <name>format</name></member>
20            <member><type>int</type> <name>usage</name></member>
21            <member><type>VkNativeBufferUsage2ANDROID</type> <name>usage2</name></member>
22        </type>
23        <type category="struct" name="VkImportColorBufferGOOGLE" structextends="VkMemoryAllocateInfo">
24            <member values="VK_STRUCTURE_TYPE_IMPORT_COLOR_BUFFER_GOOGLE"><type>VkStructureType</type> <name>sType</name></member>
25            <member><type>void</type>*                  <name>pNext</name></member>
26            <member><type>uint32_t</type>   <name>colorBuffer</name></member>
27        </type>
28        <type category="struct" name="VkImportBufferGOOGLE" structextends="VkMemoryAllocateInfo">
29            <member values="VK_STRUCTURE_TYPE_IMPORT_BUFFER_GOOGLE"><type>VkStructureType</type> <name>sType</name></member>
30            <member><type>void</type>*                  <name>pNext</name></member>
31            <member><type>uint32_t</type>   <name>buffer</name></member>
32        </type>
33        <type category="struct" name="VkCreateBlobGOOGLE" structextends="VkMemoryAllocateInfo">
34            <member values="VK_STRUCTURE_TYPE_CREATE_BLOB_GOOGLE"><type>VkStructureType</type> <name>sType</name></member>
35            <member><type>void</type>*                  <name>pNext</name></member>
36            <member><type>uint32_t</type>   <name>blobMem</name></member>
37            <member><type>uint32_t</type>   <name>blobFlags</name></member>
38            <member><type>uint64_t</type>   <name>blobId</name></member>
39        </type>
40    </types>
41
42    <commands comment="Vulkan command definitions">
43        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY,VK_ERROR_OUT_OF_DEVICE_MEMORY,VK_ERROR_MEMORY_MAP_FAILED">
44            <proto><type>VkResult</type> <name>vkMapMemoryIntoAddressSpaceGOOGLE</name></proto>
45            <param><type>VkDevice</type> <name>device</name></param>
46            <param externsync="true"><type>VkDeviceMemory</type> <name>memory</name></param>
47            <param optional="false,true"><type>uint64_t</type>* <name>pAddress</name></param>
48        </command>
49        <command>
50            <proto><type>void</type> <name>vkUpdateDescriptorSetWithTemplateSizedGOOGLE</name></proto>
51            <param><type>VkDevice</type> <name>device</name></param>
52            <param externsync="true"><type>VkDescriptorSet</type> <name>descriptorSet</name></param>
53            <param><type>VkDescriptorUpdateTemplate</type> <name>descriptorUpdateTemplate</name></param>
54            <param><type>uint32_t</type> <name>imageInfoCount</name></param>
55            <param><type>uint32_t</type> <name>bufferInfoCount</name></param>
56            <param><type>uint32_t</type> <name>bufferViewCount</name></param>
57            <param optional="true" len="imageInfoCount">const <type>uint32_t</type>* <name>pImageInfoEntryIndices</name></param>
58            <param optional="true" len="bufferInfoCount">const <type>uint32_t</type>* <name>pBufferInfoEntryIndices</name></param>
59            <param optional="true" len="bufferViewCount">const <type>uint32_t</type>* <name>pBufferViewEntryIndices</name></param>
60            <param optional="true" len="imageInfoCount">const <type>VkDescriptorImageInfo</type>* <name>pImageInfos</name></param>
61            <param optional="true" len="bufferInfoCount">const <type>VkDescriptorBufferInfo</type>* <name>pBufferInfos</name></param>
62            <param optional="true" len="bufferViewCount">const <type>VkBufferView</type>* <name>pBufferViews</name></param>
63        </command>
64        <command>
65            <proto><type>void</type> <name>vkUpdateDescriptorSetWithTemplateSized2GOOGLE</name></proto>
66            <param><type>VkDevice</type> <name>device</name></param>
67            <param externsync="true"><type>VkDescriptorSet</type> <name>descriptorSet</name></param>
68            <param><type>VkDescriptorUpdateTemplate</type> <name>descriptorUpdateTemplate</name></param>
69            <param><type>uint32_t</type> <name>imageInfoCount</name></param>
70            <param><type>uint32_t</type> <name>bufferInfoCount</name></param>
71            <param><type>uint32_t</type> <name>bufferViewCount</name></param>
72            <param><type>uint32_t</type> <name>inlineUniformBlockCount</name></param>
73            <param optional="true" len="imageInfoCount">const <type>uint32_t</type>* <name>pImageInfoEntryIndices</name></param>
74            <param optional="true" len="bufferInfoCount">const <type>uint32_t</type>* <name>pBufferInfoEntryIndices</name></param>
75            <param optional="true" len="bufferViewCount">const <type>uint32_t</type>* <name>pBufferViewEntryIndices</name></param>
76            <param optional="true" len="imageInfoCount">const <type>VkDescriptorImageInfo</type>* <name>pImageInfos</name></param>
77            <param optional="true" len="bufferInfoCount">const <type>VkDescriptorBufferInfo</type>* <name>pBufferInfos</name></param>
78            <param optional="true" len="bufferViewCount">const <type>VkBufferView</type>* <name>pBufferViews</name></param>
79            <param optional="true" len="inlineUniformBlockCount">const <type>uint8_t</type>* <name>pInlineUniformBlockData</name></param>
80        </command>
81        <command>
82            <proto><type>void</type> <name>vkBeginCommandBufferAsyncGOOGLE</name></proto>
83            <param externsync="true"><type>VkCommandBuffer</type> <name>commandBuffer</name></param>
84            <param>const <type>VkCommandBufferBeginInfo</type>* <name>pBeginInfo</name></param>
85            <implicitexternsyncparams>
86                <param>the sname:VkCommandPool that pname:commandBuffer was allocated from</param>
87            </implicitexternsyncparams>
88        </command>
89        <command>
90            <proto><type>void</type> <name>vkEndCommandBufferAsyncGOOGLE</name></proto>
91            <param externsync="true"><type>VkCommandBuffer</type> <name>commandBuffer</name></param>
92            <implicitexternsyncparams>
93                <param>the sname:VkCommandPool that pname:commandBuffer was allocated from</param>
94            </implicitexternsyncparams>
95        </command>
96        <command>
97            <proto><type>void</type> <name>vkResetCommandBufferAsyncGOOGLE</name></proto>
98            <param externsync="true"><type>VkCommandBuffer</type> <name>commandBuffer</name></param>
99            <param optional="true"><type>VkCommandBufferResetFlags</type> <name>flags</name></param>
100        </command>
101        <command>
102            <proto><type>void</type> <name>vkCommandBufferHostSyncGOOGLE</name></proto>
103            <param externsync="true"><type>VkCommandBuffer</type> <name>commandBuffer</name></param>
104            <param><type>uint32_t</type> <name>needHostSync</name></param>
105            <param><type>uint32_t</type> <name>sequenceNumber</name></param>
106        </command>
107        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY,VK_ERROR_OUT_OF_DEVICE_MEMORY">
108            <proto><type>VkResult</type> <name>vkCreateImageWithRequirementsGOOGLE</name></proto>
109            <param><type>VkDevice</type> <name>device</name></param>
110            <param>const <type>VkImageCreateInfo</type>* <name>pCreateInfo</name></param>
111            <param optional="true">const <type>VkAllocationCallbacks</type>* <name>pAllocator</name></param>
112            <param><type>VkImage</type>* <name>pImage</name></param>
113            <param><type>VkMemoryRequirements</type>* <name>pMemoryRequirements</name></param>
114        </command>
115        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY,VK_ERROR_OUT_OF_DEVICE_MEMORY">
116            <proto><type>VkResult</type> <name>vkCreateBufferWithRequirementsGOOGLE</name></proto>
117            <param><type>VkDevice</type> <name>device</name></param>
118            <param>const <type>VkBufferCreateInfo</type>* <name>pCreateInfo</name></param>
119            <param optional="true">const <type>VkAllocationCallbacks</type>* <name>pAllocator</name></param>
120            <param><type>VkBuffer</type>* <name>pBuffer</name></param>
121            <param><type>VkMemoryRequirements</type>* <name>pMemoryRequirements</name></param>
122        </command>
123        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY">
124            <proto><type>VkResult</type> <name>vkGetMemoryHostAddressInfoGOOGLE</name></proto>
125            <param><type>VkDevice</type> <name>device</name></param>
126            <param externsync="true"><type>VkDeviceMemory</type> <name>memory</name></param>
127            <param optional="false,true"><type>uint64_t</type>* <name>pAddress</name></param>
128            <param optional="false,true"><type>uint64_t</type>* <name>pSize</name></param>
129            <param optional="false,true"><type>uint64_t</type>* <name>pHostmemId</name></param>
130        </command>
131        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY,VK_ERROR_OUT_OF_DEVICE_MEMORY">
132            <proto><type>VkResult</type> <name>vkFreeMemorySyncGOOGLE</name></proto>
133            <param><type>VkDevice</type> <name>device</name></param>
134            <param optional="true" externsync="true"><type>VkDeviceMemory</type> <name>memory</name></param>
135            <param optional="true">const <type>VkAllocationCallbacks</type>* <name>pAllocator</name></param>
136        </command>
137        <command>
138            <proto><type>void</type> <name>vkQueueHostSyncGOOGLE</name></proto>
139            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
140            <param><type>uint32_t</type> <name>needHostSync</name></param>
141            <param><type>uint32_t</type> <name>sequenceNumber</name></param>
142        </command>
143        <command>
144            <proto><type>void</type> <name>vkQueueSubmitAsyncGOOGLE</name></proto>
145            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
146            <param optional="true"><type>uint32_t</type> <name>submitCount</name></param>
147            <param len="submitCount" externsync="pSubmits[].pWaitSemaphores[],pSubmits[].pSignalSemaphores[]">const <type>VkSubmitInfo</type>* <name>pSubmits</name></param>
148            <param optional="true" externsync="true"><type>VkFence</type> <name>fence</name></param>
149        </command>
150        <command>
151            <proto><type>void</type> <name>vkQueueSubmitAsync2GOOGLE</name></proto>
152            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
153            <param optional="true"><type>uint32_t</type> <name>submitCount</name></param>
154            <param len="submitCount" externsync="pSubmits[].pWaitSemaphores[],pSubmits[].pSignalSemaphores[]">const <type>VkSubmitInfo2</type>* <name>pSubmits</name></param>
155            <param optional="true" externsync="true"><type>VkFence</type> <name>fence</name></param>
156        </command>
157        <command>
158            <proto><type>void</type> <name>vkQueueWaitIdleAsyncGOOGLE</name></proto>
159            <param><type>VkQueue</type> <name>queue</name></param>
160        </command>
161        <command queues="sparse_binding">
162            <proto><type>void</type> <name>vkQueueBindSparseAsyncGOOGLE</name></proto>
163            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
164            <param optional="true"><type>uint32_t</type> <name>bindInfoCount</name></param>
165            <param len="bindInfoCount" externsync="pBindInfo[].pWaitSemaphores[],pBindInfo[].pSignalSemaphores[],pBindInfo[].pBufferBinds[].buffer,pBindInfo[].pImageOpaqueBinds[].image,pBindInfo[].pImageBinds[].image">const <type>VkBindSparseInfo</type>* <name>pBindInfo</name></param>
166            <param optional="true" externsync="true"><type>VkFence</type> <name>fence</name></param>
167        </command>
168        <command>
169            <proto><type>void</type> <name>vkGetLinearImageLayoutGOOGLE</name></proto>
170            <param><type>VkDevice</type> <name>device</name></param>
171            <param><type>VkFormat</type> <name>format</name></param>
172            <param><type>VkDeviceSize</type>* <name>pOffset</name></param>
173            <param><type>VkDeviceSize</type>* <name>pRowPitchAlignment</name></param>
174        </command>
175        <command>
176            <proto><type>void</type> <name>vkGetLinearImageLayout2GOOGLE</name></proto>
177            <param><type>VkDevice</type> <name>device</name></param>
178            <param>const <type>VkImageCreateInfo</type>* <name>pCreateInfo</name></param>
179            <param><type>VkDeviceSize</type>* <name>pOffset</name></param>
180            <param><type>VkDeviceSize</type>* <name>pRowPitchAlignment</name></param>
181        </command>
182        <command>
183            <proto><type>void</type> <name>vkQueueFlushCommandsGOOGLE</name></proto>
184            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
185            <param externsync="true"><type>VkCommandBuffer</type> <name>commandBuffer</name></param>
186            <param><type>VkDeviceSize</type> <name>dataSize</name></param>
187            <param len="dataSize">const <type>void</type>* <name>pData</name></param>
188        </command>
189        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY">
190            <proto><type>VkResult</type> <name>vkGetBlobGOOGLE</name></proto>
191            <param><type>VkDevice</type> <name>device</name></param>
192            <param externsync="true"><type>VkDeviceMemory</type> <name>memory</name></param>
193        </command>
194        <command>
195            <proto><type>void</type> <name>vkQueueCommitDescriptorSetUpdatesGOOGLE</name></proto>
196            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
197            <param externsync="true"><type>uint32_t</type> <name>descriptorPoolCount</name></param>
198            <param len="descriptorPoolCount" externsync="true">const <type>VkDescriptorPool</type>* <name>pDescriptorPools</name></param>
199            <param externsync="true"><type>uint32_t</type> <name>descriptorSetCount</name></param>
200            <param len="descriptorSetCount" externsync="true">const <type>VkDescriptorSetLayout</type>* <name>pSetLayouts</name></param>
201            <param len="descriptorSetCount" externsync="true">const <type>uint64_t</type>* <name>pDescriptorSetPoolIds</name></param>
202            <param len="descriptorSetCount" externsync="true">const <type>uint32_t</type>* <name>pDescriptorSetWhichPool</name></param>
203            <param len="descriptorSetCount" externsync="true">const <type>uint32_t</type>* <name>pDescriptorSetPendingAllocation</name></param>
204            <param len="descriptorSetCount" externsync="true">const <type>uint32_t</type>* <name>pDescriptorWriteStartingIndices</name></param>
205            <param externsync="true"><type>uint32_t</type> <name>pendingDescriptorWriteCount</name></param>
206            <param len="pendingDescriptorWriteCount" externsync="true">const <type>VkWriteDescriptorSet</type>* <name>pPendingDescriptorWrites</name></param>
207        </command>
208        <command>
209            <proto><type>void</type> <name>vkCollectDescriptorPoolIdsGOOGLE</name></proto>
210            <param><type>VkDevice</type> <name>device</name></param>
211            <param externsync="true"><type>VkDescriptorPool</type> <name>descriptorPool</name></param>
212            <param optiona="false,true"><type>uint32_t</type>* <name>pPoolIdCount</name></param>
213            <param optional="true" len="pPoolIdCount"><type>uint64_t</type>* <name>pPoolIds</name></param>
214        </command>
215        <command>
216            <proto><type>void</type> <name>vkQueueSignalReleaseImageANDROIDAsyncGOOGLE</name></proto>
217            <param><type>VkQueue</type> <name>queue</name></param>
218            <param optional="true"><type>uint32_t</type> <name>waitSemaphoreCount</name></param>
219            <param noautovalidity="true" len="waitSemaphoreCount">const <type>VkSemaphore</type>* <name>pWaitSemaphores</name></param>
220            <param><type>VkImage</type> <name>image</name></param>
221        </command>
222        <command>
223            <proto><type>VkResult</type> <name>vkQueueSignalReleaseImageANDROID</name></proto>
224            <param><type>VkQueue</type> <name>queue</name></param>
225            <param optional="true"><type>uint32_t</type> <name>waitSemaphoreCount</name></param>
226            <param noautovalidity="true" len="waitSemaphoreCount">const <type>VkSemaphore</type>* <name>pWaitSemaphores</name></param>
227            <param><type>VkImage</type> <name>image</name></param>
228            <param><type>int</type>* <name>pNativeFenceFd</name></param>
229        </command>
230        <command>
231            <proto><type>void</type> <name>vkQueueFlushCommandsFromAuxMemoryGOOGLE</name></proto>
232            <param externsync="true"><type>VkQueue</type> <name>queue</name></param>
233            <param externsync="true"><type>VkCommandBuffer</type> <name>commandBuffer</name></param>
234            <param><type>VkDeviceMemory</type> <name>deviceMemory</name></param>
235            <param><type>VkDeviceSize</type> <name>dataOffset</name></param>
236            <param><type>VkDeviceSize</type> <name>dataSize</name></param>
237        </command>
238        <command successcodes="VK_SUCCESS" errorcodes="VK_ERROR_OUT_OF_HOST_MEMORY">
239            <proto><type>VkResult</type> <name>vkGetSemaphoreGOOGLE</name></proto>
240            <param><type>VkDevice</type> <name>device</name></param>
241            <param><type>VkSemaphore</type> <name>semaphore</name></param>
242	    <param><type>uint64_t</type> <name>syncId</name></param>
243        </command>
244    </commands>
245    <extensions comment="Vulkan extension interface definitions">
246        <extension name="VK_ANDROID_native_buffer" supported="vulkan"/>
247        <extension name="VK_GOOGLE_gfxstream" number="386" author="GOOGLE" contact="Lingfeng Yang @frank,Roman Kiryanov @rkir,Yilong Li @liyl_google" supported="vulkan" type="instance">
248            <require>
249                <enum value="0"                                             name="VK_GOOGLE_GFXSTREAM_SPEC_VERSION"/>
250                <enum value="386"                                           name="VK_GOOGLE_GFXSTREAM_NUMBER"/>
251                <enum value="&quot;VK_GOOGLE_gfxstream&quot;"               name="VK_GOOGLE_GFXSTREAM_EXTENSION_NAME"/>
252                <enum offset="0" extends="VkStructureType"                  name="VK_STRUCTURE_TYPE_IMPORT_COLOR_BUFFER_GOOGLE"/>
253                <enum offset="1" extends="VkStructureType"                  name="VK_STRUCTURE_TYPE_IMPORT_BUFFER_GOOGLE"/>
254                <enum offset="2" extends="VkStructureType"                  name="VK_STRUCTURE_TYPE_CREATE_BLOB_GOOGLE"/>
255                <type name="VkImportColorBufferGOOGLE"/>
256                <type name="VkImportBufferGOOGLE"/>
257                <type name="VkCreateBlobGOOGLE"/>
258                <command name="vkMapMemoryIntoAddressSpaceGOOGLE"/>
259                <command name="vkUpdateDescriptorSetWithTemplateSizedGOOGLE"/>
260                <command name="vkBeginCommandBufferAsyncGOOGLE"/>
261                <command name="vkEndCommandBufferAsyncGOOGLE"/>
262                <command name="vkResetCommandBufferAsyncGOOGLE"/>
263                <command name="vkCommandBufferHostSyncGOOGLE"/>
264                <command name="vkCreateImageWithRequirementsGOOGLE"/>
265                <command name="vkCreateBufferWithRequirementsGOOGLE"/>
266                <command name="vkGetMemoryHostAddressInfoGOOGLE"/>
267                <command name="vkFreeMemorySyncGOOGLE"/>
268                <command name="vkQueueHostSyncGOOGLE"/>
269                <command name="vkQueueSubmitAsyncGOOGLE"/>
270                <command name="vkQueueWaitIdleAsyncGOOGLE"/>
271                <command name="vkQueueBindSparseAsyncGOOGLE"/>
272                <command name="vkGetLinearImageLayoutGOOGLE"/>
273                <command name="vkGetLinearImageLayout2GOOGLE"/>
274                <command name="vkQueueFlushCommandsGOOGLE"/>
275                <command name="vkQueueCommitDescriptorSetUpdatesGOOGLE"/>
276                <command name="vkCollectDescriptorPoolIdsGOOGLE"/>
277                <command name="vkQueueSignalReleaseImageANDROIDAsyncGOOGLE"/>
278                <command name="vkQueueFlushCommandsFromAuxMemoryGOOGLE"/>
279                <command name="vkGetBlobGOOGLE"/>
280                <command name="vkUpdateDescriptorSetWithTemplateSized2GOOGLE"/>
281                <command name="vkQueueSubmitAsync2GOOGLE"/>
282                <command name="vkGetSemaphoreGOOGLE"/>
283            </require>
284        </extension>
285    </extensions>
286</registry>
287