Merge remote-tracking branch 'mesa-public/master' into vulkan
[mesa.git] / src / glsl / nir / spirv.h
1 /*
2 ** Copyright (c) 2014-2015 The Khronos Group Inc.
3 **
4 ** Permission is hereby granted, free of charge, to any person obtaining a copy
5 ** of this software and/or associated documentation files (the "Materials"),
6 ** to deal in the Materials without restriction, including without limitation
7 ** the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 ** and/or sell copies of the Materials, and to permit persons to whom the
9 ** Materials are furnished to do so, subject to the following conditions:
10 **
11 ** The above copyright notice and this permission notice shall be included in
12 ** all copies or substantial portions of the Materials.
13 **
14 ** MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS KHRONOS
15 ** STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS SPECIFICATIONS AND
16 ** HEADER INFORMATION ARE LOCATED AT https://www.khronos.org/registry/
17 **
18 ** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19 ** OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 ** FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21 ** THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 ** LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23 ** FROM,OUT OF OR IN CONNECTION WITH THE MATERIALS OR THE USE OR OTHER DEALINGS
24 ** IN THE MATERIALS.
25 */
26
27 /*
28 ** This header is automatically generated by the same tool that creates
29 ** the Binary Section of the SPIR-V specification.
30 */
31
32 /*
33 ** Specification revision 31.
34 ** Enumeration tokens for SPIR-V, in various styles:
35 ** C, C++, C++11, JSON, Lua, Python
36 **
37 ** - C will have tokens with a "Spv" prefix, e.g.: SpvSourceLanguageGLSL
38 ** - C++ will have tokens in the "spv" name space, e.g.: spv::SourceLanguageGLSL
39 ** - C++11 will use enum classes in the spv namespace, e.g.: spv::SourceLanguage::GLSL
40 ** - Lua will use tables, e.g.: spv.SourceLanguage.GLSL
41 ** - Python will use dictionaries, e.g.: spv['SourceLanguage']['GLSL']
42 **
43 ** Some tokens act like mask values, which can be OR'd together,
44 ** while others are mutually exclusive. The mask-like ones have
45 ** "Mask" in their name, and a parallel enum that has the shift
46 ** amount (1 << x) for each corresponding enumerant.
47 */
48
49 #ifndef spirv_H
50 #define spirv_H
51
52 typedef unsigned int SpvId;
53
54 static const unsigned int SpvMagicNumber = 0x07230203;
55 static const unsigned int SpvVersion = 99;
56 static const unsigned int SpvRevision = 31;
57 static const unsigned int SpvOpCodeMask = 0xffff;
58 static const unsigned int SpvWordCountShift = 16;
59
60 typedef enum SpvSourceLanguage_ {
61 SpvSourceLanguageUnknown = 0,
62 SpvSourceLanguageESSL = 1,
63 SpvSourceLanguageGLSL = 2,
64 SpvSourceLanguageOpenCL = 3,
65 } SpvSourceLanguage;
66
67 typedef enum SpvExecutionModel_ {
68 SpvExecutionModelVertex = 0,
69 SpvExecutionModelTessellationControl = 1,
70 SpvExecutionModelTessellationEvaluation = 2,
71 SpvExecutionModelGeometry = 3,
72 SpvExecutionModelFragment = 4,
73 SpvExecutionModelGLCompute = 5,
74 SpvExecutionModelKernel = 6,
75 } SpvExecutionModel;
76
77 typedef enum SpvAddressingModel_ {
78 SpvAddressingModelLogical = 0,
79 SpvAddressingModelPhysical32 = 1,
80 SpvAddressingModelPhysical64 = 2,
81 } SpvAddressingModel;
82
83 typedef enum SpvMemoryModel_ {
84 SpvMemoryModelSimple = 0,
85 SpvMemoryModelGLSL450 = 1,
86 SpvMemoryModelOpenCL = 2,
87 } SpvMemoryModel;
88
89 typedef enum SpvExecutionMode_ {
90 SpvExecutionModeInvocations = 0,
91 SpvExecutionModeSpacingEqual = 1,
92 SpvExecutionModeSpacingFractionalEven = 2,
93 SpvExecutionModeSpacingFractionalOdd = 3,
94 SpvExecutionModeVertexOrderCw = 4,
95 SpvExecutionModeVertexOrderCcw = 5,
96 SpvExecutionModePixelCenterInteger = 6,
97 SpvExecutionModeOriginUpperLeft = 7,
98 SpvExecutionModeOriginLowerLeft = 8,
99 SpvExecutionModeEarlyFragmentTests = 9,
100 SpvExecutionModePointMode = 10,
101 SpvExecutionModeXfb = 11,
102 SpvExecutionModeDepthReplacing = 12,
103 SpvExecutionModeDepthAny = 13,
104 SpvExecutionModeDepthGreater = 14,
105 SpvExecutionModeDepthLess = 15,
106 SpvExecutionModeDepthUnchanged = 16,
107 SpvExecutionModeLocalSize = 17,
108 SpvExecutionModeLocalSizeHint = 18,
109 SpvExecutionModeInputPoints = 19,
110 SpvExecutionModeInputLines = 20,
111 SpvExecutionModeInputLinesAdjacency = 21,
112 SpvExecutionModeInputTriangles = 22,
113 SpvExecutionModeInputTrianglesAdjacency = 23,
114 SpvExecutionModeInputQuads = 24,
115 SpvExecutionModeInputIsolines = 25,
116 SpvExecutionModeOutputVertices = 26,
117 SpvExecutionModeOutputPoints = 27,
118 SpvExecutionModeOutputLineStrip = 28,
119 SpvExecutionModeOutputTriangleStrip = 29,
120 SpvExecutionModeVecTypeHint = 30,
121 SpvExecutionModeContractionOff = 31,
122 } SpvExecutionMode;
123
124 typedef enum SpvStorageClass_ {
125 SpvStorageClassUniformConstant = 0,
126 SpvStorageClassInput = 1,
127 SpvStorageClassUniform = 2,
128 SpvStorageClassOutput = 3,
129 SpvStorageClassWorkgroupLocal = 4,
130 SpvStorageClassWorkgroupGlobal = 5,
131 SpvStorageClassPrivateGlobal = 6,
132 SpvStorageClassFunction = 7,
133 SpvStorageClassGeneric = 8,
134 SpvStorageClassAtomicCounter = 10,
135 SpvStorageClassImage = 11,
136 } SpvStorageClass;
137
138 typedef enum SpvDim_ {
139 SpvDim1D = 0,
140 SpvDim2D = 1,
141 SpvDim3D = 2,
142 SpvDimCube = 3,
143 SpvDimRect = 4,
144 SpvDimBuffer = 5,
145 } SpvDim;
146
147 typedef enum SpvSamplerAddressingMode_ {
148 SpvSamplerAddressingModeNone = 0,
149 SpvSamplerAddressingModeClampToEdge = 1,
150 SpvSamplerAddressingModeClamp = 2,
151 SpvSamplerAddressingModeRepeat = 3,
152 SpvSamplerAddressingModeRepeatMirrored = 4,
153 } SpvSamplerAddressingMode;
154
155 typedef enum SpvSamplerFilterMode_ {
156 SpvSamplerFilterModeNearest = 0,
157 SpvSamplerFilterModeLinear = 1,
158 } SpvSamplerFilterMode;
159
160 typedef enum SpvImageFormat_ {
161 SpvImageFormatUnknown = 0,
162 SpvImageFormatRgba32f = 1,
163 SpvImageFormatRgba16f = 2,
164 SpvImageFormatR32f = 3,
165 SpvImageFormatRgba8 = 4,
166 SpvImageFormatRgba8Snorm = 5,
167 SpvImageFormatRg32f = 6,
168 SpvImageFormatRg16f = 7,
169 SpvImageFormatR11fG11fB10f = 8,
170 SpvImageFormatR16f = 9,
171 SpvImageFormatRgba16 = 10,
172 SpvImageFormatRgb10A2 = 11,
173 SpvImageFormatRg16 = 12,
174 SpvImageFormatRg8 = 13,
175 SpvImageFormatR16 = 14,
176 SpvImageFormatR8 = 15,
177 SpvImageFormatRgba16Snorm = 16,
178 SpvImageFormatRg16Snorm = 17,
179 SpvImageFormatRg8Snorm = 18,
180 SpvImageFormatR16Snorm = 19,
181 SpvImageFormatR8Snorm = 20,
182 SpvImageFormatRgba32i = 21,
183 SpvImageFormatRgba16i = 22,
184 SpvImageFormatRgba8i = 23,
185 SpvImageFormatR32i = 24,
186 SpvImageFormatRg32i = 25,
187 SpvImageFormatRg16i = 26,
188 SpvImageFormatRg8i = 27,
189 SpvImageFormatR16i = 28,
190 SpvImageFormatR8i = 29,
191 SpvImageFormatRgba32ui = 30,
192 SpvImageFormatRgba16ui = 31,
193 SpvImageFormatRgba8ui = 32,
194 SpvImageFormatR32ui = 33,
195 SpvImageFormatRgb10a2ui = 34,
196 SpvImageFormatRg32ui = 35,
197 SpvImageFormatRg16ui = 36,
198 SpvImageFormatRg8ui = 37,
199 SpvImageFormatR16ui = 38,
200 SpvImageFormatR8ui = 39,
201 } SpvImageFormat;
202
203 typedef enum SpvImageChannelOrder_ {
204 SpvImageChannelOrderR = 0,
205 SpvImageChannelOrderA = 1,
206 SpvImageChannelOrderRG = 2,
207 SpvImageChannelOrderRA = 3,
208 SpvImageChannelOrderRGB = 4,
209 SpvImageChannelOrderRGBA = 5,
210 SpvImageChannelOrderBGRA = 6,
211 SpvImageChannelOrderARGB = 7,
212 SpvImageChannelOrderIntensity = 8,
213 SpvImageChannelOrderLuminance = 9,
214 SpvImageChannelOrderRx = 10,
215 SpvImageChannelOrderRGx = 11,
216 SpvImageChannelOrderRGBx = 12,
217 SpvImageChannelOrderDepth = 13,
218 SpvImageChannelOrderDepthStencil = 14,
219 SpvImageChannelOrdersRGB = 15,
220 SpvImageChannelOrdersRGBx = 16,
221 SpvImageChannelOrdersRGBA = 17,
222 SpvImageChannelOrdersBGRA = 18,
223 } SpvImageChannelOrder;
224
225 typedef enum SpvImageChannelDataType_ {
226 SpvImageChannelDataTypeSnormInt8 = 0,
227 SpvImageChannelDataTypeSnormInt16 = 1,
228 SpvImageChannelDataTypeUnormInt8 = 2,
229 SpvImageChannelDataTypeUnormInt16 = 3,
230 SpvImageChannelDataTypeUnormShort565 = 4,
231 SpvImageChannelDataTypeUnormShort555 = 5,
232 SpvImageChannelDataTypeUnormInt101010 = 6,
233 SpvImageChannelDataTypeSignedInt8 = 7,
234 SpvImageChannelDataTypeSignedInt16 = 8,
235 SpvImageChannelDataTypeSignedInt32 = 9,
236 SpvImageChannelDataTypeUnsignedInt8 = 10,
237 SpvImageChannelDataTypeUnsignedInt16 = 11,
238 SpvImageChannelDataTypeUnsignedInt32 = 12,
239 SpvImageChannelDataTypeHalfFloat = 13,
240 SpvImageChannelDataTypeFloat = 14,
241 SpvImageChannelDataTypeUnormInt24 = 15,
242 } SpvImageChannelDataType;
243
244 typedef enum SpvImageOperandsShift_ {
245 SpvImageOperandsBiasShift = 0,
246 SpvImageOperandsLodShift = 1,
247 SpvImageOperandsGradShift = 2,
248 SpvImageOperandsConstOffsetShift = 3,
249 SpvImageOperandsOffsetShift = 4,
250 SpvImageOperandsConstOffsetsShift = 5,
251 SpvImageOperandsSampleShift = 6,
252 } SpvImageOperandsShift;
253
254 typedef enum SpvImageOperandsMask_ {
255 SpvImageOperandsMaskNone = 0,
256 SpvImageOperandsBiasMask = 0x00000001,
257 SpvImageOperandsLodMask = 0x00000002,
258 SpvImageOperandsGradMask = 0x00000004,
259 SpvImageOperandsConstOffsetMask = 0x00000008,
260 SpvImageOperandsOffsetMask = 0x00000010,
261 SpvImageOperandsConstOffsetsMask = 0x00000020,
262 SpvImageOperandsSampleMask = 0x00000040,
263 } SpvImageOperandsMask;
264
265 typedef enum SpvFPFastMathModeShift_ {
266 SpvFPFastMathModeNotNaNShift = 0,
267 SpvFPFastMathModeNotInfShift = 1,
268 SpvFPFastMathModeNSZShift = 2,
269 SpvFPFastMathModeAllowRecipShift = 3,
270 SpvFPFastMathModeFastShift = 4,
271 } SpvFPFastMathModeShift;
272
273 typedef enum SpvFPFastMathModeMask_ {
274 SpvFPFastMathModeMaskNone = 0,
275 SpvFPFastMathModeNotNaNMask = 0x00000001,
276 SpvFPFastMathModeNotInfMask = 0x00000002,
277 SpvFPFastMathModeNSZMask = 0x00000004,
278 SpvFPFastMathModeAllowRecipMask = 0x00000008,
279 SpvFPFastMathModeFastMask = 0x00000010,
280 } SpvFPFastMathModeMask;
281
282 typedef enum SpvFPRoundingMode_ {
283 SpvFPRoundingModeRTE = 0,
284 SpvFPRoundingModeRTZ = 1,
285 SpvFPRoundingModeRTP = 2,
286 SpvFPRoundingModeRTN = 3,
287 } SpvFPRoundingMode;
288
289 typedef enum SpvLinkageType_ {
290 SpvLinkageTypeExport = 0,
291 SpvLinkageTypeImport = 1,
292 } SpvLinkageType;
293
294 typedef enum SpvAccessQualifier_ {
295 SpvAccessQualifierReadOnly = 0,
296 SpvAccessQualifierWriteOnly = 1,
297 SpvAccessQualifierReadWrite = 2,
298 } SpvAccessQualifier;
299
300 typedef enum SpvFunctionParameterAttribute_ {
301 SpvFunctionParameterAttributeZext = 0,
302 SpvFunctionParameterAttributeSext = 1,
303 SpvFunctionParameterAttributeByVal = 2,
304 SpvFunctionParameterAttributeSret = 3,
305 SpvFunctionParameterAttributeNoAlias = 4,
306 SpvFunctionParameterAttributeNoCapture = 5,
307 SpvFunctionParameterAttributeNoWrite = 6,
308 SpvFunctionParameterAttributeNoReadWrite = 7,
309 } SpvFunctionParameterAttribute;
310
311 typedef enum SpvDecoration_ {
312 SpvDecorationRelaxedPrecision = 0,
313 SpvDecorationSpecId = 1,
314 SpvDecorationBlock = 2,
315 SpvDecorationBufferBlock = 3,
316 SpvDecorationRowMajor = 4,
317 SpvDecorationColMajor = 5,
318 SpvDecorationArrayStride = 6,
319 SpvDecorationMatrixStride = 7,
320 SpvDecorationGLSLShared = 8,
321 SpvDecorationGLSLPacked = 9,
322 SpvDecorationCPacked = 10,
323 SpvDecorationBuiltIn = 11,
324 SpvDecorationSmooth = 12,
325 SpvDecorationNoperspective = 13,
326 SpvDecorationFlat = 14,
327 SpvDecorationPatch = 15,
328 SpvDecorationCentroid = 16,
329 SpvDecorationSample = 17,
330 SpvDecorationInvariant = 18,
331 SpvDecorationRestrict = 19,
332 SpvDecorationAliased = 20,
333 SpvDecorationVolatile = 21,
334 SpvDecorationConstant = 22,
335 SpvDecorationCoherent = 23,
336 SpvDecorationNonwritable = 24,
337 SpvDecorationNonreadable = 25,
338 SpvDecorationUniform = 26,
339 SpvDecorationNoStaticUse = 27,
340 SpvDecorationSaturatedConversion = 28,
341 SpvDecorationStream = 29,
342 SpvDecorationLocation = 30,
343 SpvDecorationComponent = 31,
344 SpvDecorationIndex = 32,
345 SpvDecorationBinding = 33,
346 SpvDecorationDescriptorSet = 34,
347 SpvDecorationOffset = 35,
348 SpvDecorationXfbBuffer = 36,
349 SpvDecorationXfbStride = 37,
350 SpvDecorationFuncParamAttr = 38,
351 SpvDecorationFPRoundingMode = 39,
352 SpvDecorationFPFastMathMode = 40,
353 SpvDecorationLinkageAttributes = 41,
354 } SpvDecoration;
355
356 typedef enum SpvBuiltIn_ {
357 SpvBuiltInPosition = 0,
358 SpvBuiltInPointSize = 1,
359 SpvBuiltInClipDistance = 3,
360 SpvBuiltInCullDistance = 4,
361 SpvBuiltInVertexId = 5,
362 SpvBuiltInInstanceId = 6,
363 SpvBuiltInPrimitiveId = 7,
364 SpvBuiltInInvocationId = 8,
365 SpvBuiltInLayer = 9,
366 SpvBuiltInViewportIndex = 10,
367 SpvBuiltInTessLevelOuter = 11,
368 SpvBuiltInTessLevelInner = 12,
369 SpvBuiltInTessCoord = 13,
370 SpvBuiltInPatchVertices = 14,
371 SpvBuiltInFragCoord = 15,
372 SpvBuiltInPointCoord = 16,
373 SpvBuiltInFrontFacing = 17,
374 SpvBuiltInSampleId = 18,
375 SpvBuiltInSamplePosition = 19,
376 SpvBuiltInSampleMask = 20,
377 SpvBuiltInFragColor = 21,
378 SpvBuiltInFragDepth = 22,
379 SpvBuiltInHelperInvocation = 23,
380 SpvBuiltInNumWorkgroups = 24,
381 SpvBuiltInWorkgroupSize = 25,
382 SpvBuiltInWorkgroupId = 26,
383 SpvBuiltInLocalInvocationId = 27,
384 SpvBuiltInGlobalInvocationId = 28,
385 SpvBuiltInLocalInvocationIndex = 29,
386 SpvBuiltInWorkDim = 30,
387 SpvBuiltInGlobalSize = 31,
388 SpvBuiltInEnqueuedWorkgroupSize = 32,
389 SpvBuiltInGlobalOffset = 33,
390 SpvBuiltInGlobalLinearId = 34,
391 SpvBuiltInWorkgroupLinearId = 35,
392 SpvBuiltInSubgroupSize = 36,
393 SpvBuiltInSubgroupMaxSize = 37,
394 SpvBuiltInNumSubgroups = 38,
395 SpvBuiltInNumEnqueuedSubgroups = 39,
396 SpvBuiltInSubgroupId = 40,
397 SpvBuiltInSubgroupLocalInvocationId = 41,
398 } SpvBuiltIn;
399
400 typedef enum SpvSelectionControlShift_ {
401 SpvSelectionControlFlattenShift = 0,
402 SpvSelectionControlDontFlattenShift = 1,
403 } SpvSelectionControlShift;
404
405 typedef enum SpvSelectionControlMask_ {
406 SpvSelectionControlMaskNone = 0,
407 SpvSelectionControlFlattenMask = 0x00000001,
408 SpvSelectionControlDontFlattenMask = 0x00000002,
409 } SpvSelectionControlMask;
410
411 typedef enum SpvLoopControlShift_ {
412 SpvLoopControlUnrollShift = 0,
413 SpvLoopControlDontUnrollShift = 1,
414 } SpvLoopControlShift;
415
416 typedef enum SpvLoopControlMask_ {
417 SpvLoopControlMaskNone = 0,
418 SpvLoopControlUnrollMask = 0x00000001,
419 SpvLoopControlDontUnrollMask = 0x00000002,
420 } SpvLoopControlMask;
421
422 typedef enum SpvFunctionControlShift_ {
423 SpvFunctionControlInlineShift = 0,
424 SpvFunctionControlDontInlineShift = 1,
425 SpvFunctionControlPureShift = 2,
426 SpvFunctionControlConstShift = 3,
427 } SpvFunctionControlShift;
428
429 typedef enum SpvFunctionControlMask_ {
430 SpvFunctionControlMaskNone = 0,
431 SpvFunctionControlInlineMask = 0x00000001,
432 SpvFunctionControlDontInlineMask = 0x00000002,
433 SpvFunctionControlPureMask = 0x00000004,
434 SpvFunctionControlConstMask = 0x00000008,
435 } SpvFunctionControlMask;
436
437 typedef enum SpvMemorySemanticsShift_ {
438 SpvMemorySemanticsRelaxedShift = 0,
439 SpvMemorySemanticsSequentiallyConsistentShift = 1,
440 SpvMemorySemanticsAcquireShift = 2,
441 SpvMemorySemanticsReleaseShift = 3,
442 SpvMemorySemanticsUniformMemoryShift = 4,
443 SpvMemorySemanticsSubgroupMemoryShift = 5,
444 SpvMemorySemanticsWorkgroupLocalMemoryShift = 6,
445 SpvMemorySemanticsWorkgroupGlobalMemoryShift = 7,
446 SpvMemorySemanticsAtomicCounterMemoryShift = 8,
447 SpvMemorySemanticsImageMemoryShift = 9,
448 } SpvMemorySemanticsShift;
449
450 typedef enum SpvMemorySemanticsMask_ {
451 SpvMemorySemanticsMaskNone = 0,
452 SpvMemorySemanticsRelaxedMask = 0x00000001,
453 SpvMemorySemanticsSequentiallyConsistentMask = 0x00000002,
454 SpvMemorySemanticsAcquireMask = 0x00000004,
455 SpvMemorySemanticsReleaseMask = 0x00000008,
456 SpvMemorySemanticsUniformMemoryMask = 0x00000010,
457 SpvMemorySemanticsSubgroupMemoryMask = 0x00000020,
458 SpvMemorySemanticsWorkgroupLocalMemoryMask = 0x00000040,
459 SpvMemorySemanticsWorkgroupGlobalMemoryMask = 0x00000080,
460 SpvMemorySemanticsAtomicCounterMemoryMask = 0x00000100,
461 SpvMemorySemanticsImageMemoryMask = 0x00000200,
462 } SpvMemorySemanticsMask;
463
464 typedef enum SpvMemoryAccessShift_ {
465 SpvMemoryAccessVolatileShift = 0,
466 SpvMemoryAccessAlignedShift = 1,
467 } SpvMemoryAccessShift;
468
469 typedef enum SpvMemoryAccessMask_ {
470 SpvMemoryAccessMaskNone = 0,
471 SpvMemoryAccessVolatileMask = 0x00000001,
472 SpvMemoryAccessAlignedMask = 0x00000002,
473 } SpvMemoryAccessMask;
474
475 typedef enum SpvScope_ {
476 SpvScopeCrossDevice = 0,
477 SpvScopeDevice = 1,
478 SpvScopeWorkgroup = 2,
479 SpvScopeSubgroup = 3,
480 SpvScopeInvocation = 4,
481 } SpvScope;
482
483 typedef enum SpvGroupOperation_ {
484 SpvGroupOperationReduce = 0,
485 SpvGroupOperationInclusiveScan = 1,
486 SpvGroupOperationExclusiveScan = 2,
487 } SpvGroupOperation;
488
489 typedef enum SpvKernelEnqueueFlags_ {
490 SpvKernelEnqueueFlagsNoWait = 0,
491 SpvKernelEnqueueFlagsWaitKernel = 1,
492 SpvKernelEnqueueFlagsWaitWorkGroup = 2,
493 } SpvKernelEnqueueFlags;
494
495 typedef enum SpvKernelProfilingInfoShift_ {
496 SpvKernelProfilingInfoCmdExecTimeShift = 0,
497 } SpvKernelProfilingInfoShift;
498
499 typedef enum SpvKernelProfilingInfoMask_ {
500 SpvKernelProfilingInfoMaskNone = 0,
501 SpvKernelProfilingInfoCmdExecTimeMask = 0x00000001,
502 } SpvKernelProfilingInfoMask;
503
504 typedef enum SpvCapability_ {
505 SpvCapabilityMatrix = 0,
506 SpvCapabilityShader = 1,
507 SpvCapabilityGeometry = 2,
508 SpvCapabilityTessellation = 3,
509 SpvCapabilityAddresses = 4,
510 SpvCapabilityLinkage = 5,
511 SpvCapabilityKernel = 6,
512 SpvCapabilityVector16 = 7,
513 SpvCapabilityFloat16Buffer = 8,
514 SpvCapabilityFloat16 = 9,
515 SpvCapabilityFloat64 = 10,
516 SpvCapabilityInt64 = 11,
517 SpvCapabilityInt64Atomics = 12,
518 SpvCapabilityImageBasic = 13,
519 SpvCapabilityImageReadWrite = 14,
520 SpvCapabilityImageMipmap = 15,
521 SpvCapabilityImageSRGBWrite = 16,
522 SpvCapabilityPipes = 17,
523 SpvCapabilityGroups = 18,
524 SpvCapabilityDeviceEnqueue = 19,
525 SpvCapabilityLiteralSampler = 20,
526 SpvCapabilityAtomicStorage = 21,
527 SpvCapabilityInt16 = 22,
528 SpvCapabilityTessellationPointSize = 23,
529 SpvCapabilityGeometryPointSize = 24,
530 SpvCapabilityImageGatherExtended = 25,
531 SpvCapabilityStorageImageExtendedFormats = 26,
532 SpvCapabilityStorageImageMultisample = 27,
533 SpvCapabilityUniformBufferArrayDynamicIndexing = 28,
534 SpvCapabilitySampledImageArrayDynamicIndexing = 29,
535 SpvCapabilityStorageBufferArrayDynamicIndexing = 30,
536 SpvCapabilityStorageImageArrayDynamicIndexing = 31,
537 SpvCapabilityClipDistance = 32,
538 SpvCapabilityCullDistance = 33,
539 SpvCapabilityImageCubeArray = 34,
540 SpvCapabilitySampleRateShading = 35,
541 } SpvCapability;
542
543 typedef enum SpvOp_ {
544 SpvOpNop = 0,
545 SpvOpUndef = 1,
546 SpvOpSource = 3,
547 SpvOpSourceExtension = 4,
548 SpvOpName = 5,
549 SpvOpMemberName = 6,
550 SpvOpString = 7,
551 SpvOpLine = 8,
552 SpvOpExtension = 10,
553 SpvOpExtInstImport = 11,
554 SpvOpExtInst = 12,
555 SpvOpMemoryModel = 14,
556 SpvOpEntryPoint = 15,
557 SpvOpExecutionMode = 16,
558 SpvOpCapability = 17,
559 SpvOpTypeVoid = 19,
560 SpvOpTypeBool = 20,
561 SpvOpTypeInt = 21,
562 SpvOpTypeFloat = 22,
563 SpvOpTypeVector = 23,
564 SpvOpTypeMatrix = 24,
565 SpvOpTypeImage = 25,
566 SpvOpTypeSampler = 26,
567 SpvOpTypeSampledImage = 27,
568 SpvOpTypeArray = 28,
569 SpvOpTypeRuntimeArray = 29,
570 SpvOpTypeStruct = 30,
571 SpvOpTypeOpaque = 31,
572 SpvOpTypePointer = 32,
573 SpvOpTypeFunction = 33,
574 SpvOpTypeEvent = 34,
575 SpvOpTypeDeviceEvent = 35,
576 SpvOpTypeReserveId = 36,
577 SpvOpTypeQueue = 37,
578 SpvOpTypePipe = 38,
579 SpvOpConstantTrue = 41,
580 SpvOpConstantFalse = 42,
581 SpvOpConstant = 43,
582 SpvOpConstantComposite = 44,
583 SpvOpConstantSampler = 45,
584 SpvOpConstantNull = 46,
585 SpvOpSpecConstantTrue = 48,
586 SpvOpSpecConstantFalse = 49,
587 SpvOpSpecConstant = 50,
588 SpvOpSpecConstantComposite = 51,
589 SpvOpSpecConstantOp = 52,
590 SpvOpFunction = 54,
591 SpvOpFunctionParameter = 55,
592 SpvOpFunctionEnd = 56,
593 SpvOpFunctionCall = 57,
594 SpvOpVariable = 59,
595 SpvOpImageTexelPointer = 60,
596 SpvOpLoad = 61,
597 SpvOpStore = 62,
598 SpvOpCopyMemory = 63,
599 SpvOpCopyMemorySized = 64,
600 SpvOpAccessChain = 65,
601 SpvOpInBoundsAccessChain = 66,
602 SpvOpPtrAccessChain = 67,
603 SpvOpArrayLength = 68,
604 SpvOpGenericPtrMemSemantics = 69,
605 SpvOpDecorate = 71,
606 SpvOpMemberDecorate = 72,
607 SpvOpDecorationGroup = 73,
608 SpvOpGroupDecorate = 74,
609 SpvOpGroupMemberDecorate = 75,
610 SpvOpVectorExtractDynamic = 77,
611 SpvOpVectorInsertDynamic = 78,
612 SpvOpVectorShuffle = 79,
613 SpvOpCompositeConstruct = 80,
614 SpvOpCompositeExtract = 81,
615 SpvOpCompositeInsert = 82,
616 SpvOpCopyObject = 83,
617 SpvOpTranspose = 84,
618 SpvOpSampledImage = 86,
619 SpvOpImageSampleImplicitLod = 87,
620 SpvOpImageSampleExplicitLod = 88,
621 SpvOpImageSampleDrefImplicitLod = 89,
622 SpvOpImageSampleDrefExplicitLod = 90,
623 SpvOpImageSampleProjImplicitLod = 91,
624 SpvOpImageSampleProjExplicitLod = 92,
625 SpvOpImageSampleProjDrefImplicitLod = 93,
626 SpvOpImageSampleProjDrefExplicitLod = 94,
627 SpvOpImageFetch = 95,
628 SpvOpImageGather = 96,
629 SpvOpImageDrefGather = 97,
630 SpvOpImageRead = 98,
631 SpvOpImageWrite = 99,
632 SpvOpImageQueryDim = 100,
633 SpvOpImageQueryFormat = 101,
634 SpvOpImageQueryOrder = 102,
635 SpvOpImageQuerySizeLod = 103,
636 SpvOpImageQuerySize = 104,
637 SpvOpImageQueryLod = 105,
638 SpvOpImageQueryLevels = 106,
639 SpvOpImageQuerySamples = 107,
640 SpvOpConvertFToU = 109,
641 SpvOpConvertFToS = 110,
642 SpvOpConvertSToF = 111,
643 SpvOpConvertUToF = 112,
644 SpvOpUConvert = 113,
645 SpvOpSConvert = 114,
646 SpvOpFConvert = 115,
647 SpvOpQuantizeToF16 = 116,
648 SpvOpConvertPtrToU = 117,
649 SpvOpSatConvertSToU = 118,
650 SpvOpSatConvertUToS = 119,
651 SpvOpConvertUToPtr = 120,
652 SpvOpPtrCastToGeneric = 121,
653 SpvOpGenericCastToPtr = 122,
654 SpvOpGenericCastToPtrExplicit = 123,
655 SpvOpBitcast = 124,
656 SpvOpSNegate = 126,
657 SpvOpFNegate = 127,
658 SpvOpIAdd = 128,
659 SpvOpFAdd = 129,
660 SpvOpISub = 130,
661 SpvOpFSub = 131,
662 SpvOpIMul = 132,
663 SpvOpFMul = 133,
664 SpvOpUDiv = 134,
665 SpvOpSDiv = 135,
666 SpvOpFDiv = 136,
667 SpvOpUMod = 137,
668 SpvOpSRem = 138,
669 SpvOpSMod = 139,
670 SpvOpFRem = 140,
671 SpvOpFMod = 141,
672 SpvOpVectorTimesScalar = 142,
673 SpvOpMatrixTimesScalar = 143,
674 SpvOpVectorTimesMatrix = 144,
675 SpvOpMatrixTimesVector = 145,
676 SpvOpMatrixTimesMatrix = 146,
677 SpvOpOuterProduct = 147,
678 SpvOpDot = 148,
679 SpvOpIAddCarry = 149,
680 SpvOpISubBorrow = 150,
681 SpvOpIMulExtended = 151,
682 SpvOpAny = 154,
683 SpvOpAll = 155,
684 SpvOpIsNan = 156,
685 SpvOpIsInf = 157,
686 SpvOpIsFinite = 158,
687 SpvOpIsNormal = 159,
688 SpvOpSignBitSet = 160,
689 SpvOpLessOrGreater = 161,
690 SpvOpOrdered = 162,
691 SpvOpUnordered = 163,
692 SpvOpLogicalEqual = 164,
693 SpvOpLogicalNotEqual = 165,
694 SpvOpLogicalOr = 166,
695 SpvOpLogicalAnd = 167,
696 SpvOpLogicalNot = 168,
697 SpvOpSelect = 169,
698 SpvOpIEqual = 170,
699 SpvOpINotEqual = 171,
700 SpvOpUGreaterThan = 172,
701 SpvOpSGreaterThan = 173,
702 SpvOpUGreaterThanEqual = 174,
703 SpvOpSGreaterThanEqual = 175,
704 SpvOpULessThan = 176,
705 SpvOpSLessThan = 177,
706 SpvOpULessThanEqual = 178,
707 SpvOpSLessThanEqual = 179,
708 SpvOpFOrdEqual = 180,
709 SpvOpFUnordEqual = 181,
710 SpvOpFOrdNotEqual = 182,
711 SpvOpFUnordNotEqual = 183,
712 SpvOpFOrdLessThan = 184,
713 SpvOpFUnordLessThan = 185,
714 SpvOpFOrdGreaterThan = 186,
715 SpvOpFUnordGreaterThan = 187,
716 SpvOpFOrdLessThanEqual = 188,
717 SpvOpFUnordLessThanEqual = 189,
718 SpvOpFOrdGreaterThanEqual = 190,
719 SpvOpFUnordGreaterThanEqual = 191,
720 SpvOpShiftRightLogical = 194,
721 SpvOpShiftRightArithmetic = 195,
722 SpvOpShiftLeftLogical = 196,
723 SpvOpBitwiseOr = 197,
724 SpvOpBitwiseXor = 198,
725 SpvOpBitwiseAnd = 199,
726 SpvOpNot = 200,
727 SpvOpBitFieldInsert = 201,
728 SpvOpBitFieldSExtract = 202,
729 SpvOpBitFieldUExtract = 203,
730 SpvOpBitReverse = 204,
731 SpvOpBitCount = 205,
732 SpvOpDPdx = 207,
733 SpvOpDPdy = 208,
734 SpvOpFwidth = 209,
735 SpvOpDPdxFine = 210,
736 SpvOpDPdyFine = 211,
737 SpvOpFwidthFine = 212,
738 SpvOpDPdxCoarse = 213,
739 SpvOpDPdyCoarse = 214,
740 SpvOpFwidthCoarse = 215,
741 SpvOpEmitVertex = 218,
742 SpvOpEndPrimitive = 219,
743 SpvOpEmitStreamVertex = 220,
744 SpvOpEndStreamPrimitive = 221,
745 SpvOpControlBarrier = 224,
746 SpvOpMemoryBarrier = 225,
747 SpvOpAtomicLoad = 227,
748 SpvOpAtomicStore = 228,
749 SpvOpAtomicExchange = 229,
750 SpvOpAtomicCompareExchange = 230,
751 SpvOpAtomicCompareExchangeWeak = 231,
752 SpvOpAtomicIIncrement = 232,
753 SpvOpAtomicIDecrement = 233,
754 SpvOpAtomicIAdd = 234,
755 SpvOpAtomicISub = 235,
756 SpvOpAtomicSMin = 236,
757 SpvOpAtomicUMin = 237,
758 SpvOpAtomicSMax = 238,
759 SpvOpAtomicUMax = 239,
760 SpvOpAtomicAnd = 240,
761 SpvOpAtomicOr = 241,
762 SpvOpAtomicXor = 242,
763 SpvOpPhi = 245,
764 SpvOpLoopMerge = 246,
765 SpvOpSelectionMerge = 247,
766 SpvOpLabel = 248,
767 SpvOpBranch = 249,
768 SpvOpBranchConditional = 250,
769 SpvOpSwitch = 251,
770 SpvOpKill = 252,
771 SpvOpReturn = 253,
772 SpvOpReturnValue = 254,
773 SpvOpUnreachable = 255,
774 SpvOpLifetimeStart = 256,
775 SpvOpLifetimeStop = 257,
776 SpvOpAsyncGroupCopy = 259,
777 SpvOpWaitGroupEvents = 260,
778 SpvOpGroupAll = 261,
779 SpvOpGroupAny = 262,
780 SpvOpGroupBroadcast = 263,
781 SpvOpGroupIAdd = 264,
782 SpvOpGroupFAdd = 265,
783 SpvOpGroupFMin = 266,
784 SpvOpGroupUMin = 267,
785 SpvOpGroupSMin = 268,
786 SpvOpGroupFMax = 269,
787 SpvOpGroupUMax = 270,
788 SpvOpGroupSMax = 271,
789 SpvOpReadPipe = 274,
790 SpvOpWritePipe = 275,
791 SpvOpReservedReadPipe = 276,
792 SpvOpReservedWritePipe = 277,
793 SpvOpReserveReadPipePackets = 278,
794 SpvOpReserveWritePipePackets = 279,
795 SpvOpCommitReadPipe = 280,
796 SpvOpCommitWritePipe = 281,
797 SpvOpIsValidReserveId = 282,
798 SpvOpGetNumPipePackets = 283,
799 SpvOpGetMaxPipePackets = 284,
800 SpvOpGroupReserveReadPipePackets = 285,
801 SpvOpGroupReserveWritePipePackets = 286,
802 SpvOpGroupCommitReadPipe = 287,
803 SpvOpGroupCommitWritePipe = 288,
804 SpvOpEnqueueMarker = 291,
805 SpvOpEnqueueKernel = 292,
806 SpvOpGetKernelNDrangeSubGroupCount = 293,
807 SpvOpGetKernelNDrangeMaxSubGroupSize = 294,
808 SpvOpGetKernelWorkGroupSize = 295,
809 SpvOpGetKernelPreferredWorkGroupSizeMultiple = 296,
810 SpvOpRetainEvent = 297,
811 SpvOpReleaseEvent = 298,
812 SpvOpCreateUserEvent = 299,
813 SpvOpIsValidEvent = 300,
814 SpvOpSetUserEventStatus = 301,
815 SpvOpCaptureEventProfilingInfo = 302,
816 SpvOpGetDefaultQueue = 303,
817 SpvOpBuildNDRange = 304,
818 } SpvOp;
819
820 #endif // #ifndef spirv_H