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