Publish SPIR-V Registry files: SPIR-V 1.0 Revision 4
[platform/upstream/SPIRV-Headers.git] / include / spirv / 1.0 / spirv.hpp
1 // Copyright (c) 2014-2016 The Khronos Group Inc.
2 // 
3 // Permission is hereby granted, free of charge, to any person obtaining a copy
4 // of this software and/or associated documentation files (the "Materials"),
5 // to deal in the Materials without restriction, including without limitation
6 // the rights to use, copy, modify, merge, publish, distribute, sublicense,
7 // and/or sell copies of the Materials, and to permit persons to whom the
8 // Materials are furnished to do so, subject to the following conditions:
9 // 
10 // The above copyright notice and this permission notice shall be included in
11 // all copies or substantial portions of the Materials.
12 // 
13 // MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS KHRONOS
14 // STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS SPECIFICATIONS AND
15 // HEADER INFORMATION ARE LOCATED AT https://www.khronos.org/registry/ 
16 // 
17 // THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
18 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
20 // THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
22 // FROM,OUT OF OR IN CONNECTION WITH THE MATERIALS OR THE USE OR OTHER DEALINGS
23 // IN THE MATERIALS.
24
25 // This header is automatically generated by the same tool that creates
26 // the Binary Section of the SPIR-V specification.
27
28 // Enumeration tokens for SPIR-V, in various styles:
29 //   C, C++, C++11, JSON, Lua, Python
30 // 
31 // - C will have tokens with a "Spv" prefix, e.g.: SpvSourceLanguageGLSL
32 // - C++ will have tokens in the "spv" name space, e.g.: spv::SourceLanguageGLSL
33 // - C++11 will use enum classes in the spv namespace, e.g.: spv::SourceLanguage::GLSL
34 // - Lua will use tables, e.g.: spv.SourceLanguage.GLSL
35 // - Python will use dictionaries, e.g.: spv['SourceLanguage']['GLSL']
36 // 
37 // Some tokens act like mask values, which can be OR'd together,
38 // while others are mutually exclusive.  The mask-like ones have
39 // "Mask" in their name, and a parallel enum that has the shift
40 // amount (1 << x) for each corresponding enumerant.
41
42 #ifndef spirv_HPP
43 #define spirv_HPP
44
45 namespace spv {
46
47 typedef unsigned int Id;
48
49 #define SPV_VERSION 0x10000
50 #define SPV_REVISION 4
51
52 static const unsigned int MagicNumber = 0x07230203;
53 static const unsigned int Version = 0x00010000;
54 static const unsigned int Revision = 4;
55 static const unsigned int OpCodeMask = 0xffff;
56 static const unsigned int WordCountShift = 16;
57
58 enum SourceLanguage {
59     SourceLanguageUnknown = 0,
60     SourceLanguageESSL = 1,
61     SourceLanguageGLSL = 2,
62     SourceLanguageOpenCL_C = 3,
63     SourceLanguageOpenCL_CPP = 4,
64 };
65
66 enum ExecutionModel {
67     ExecutionModelVertex = 0,
68     ExecutionModelTessellationControl = 1,
69     ExecutionModelTessellationEvaluation = 2,
70     ExecutionModelGeometry = 3,
71     ExecutionModelFragment = 4,
72     ExecutionModelGLCompute = 5,
73     ExecutionModelKernel = 6,
74 };
75
76 enum AddressingModel {
77     AddressingModelLogical = 0,
78     AddressingModelPhysical32 = 1,
79     AddressingModelPhysical64 = 2,
80 };
81
82 enum MemoryModel {
83     MemoryModelSimple = 0,
84     MemoryModelGLSL450 = 1,
85     MemoryModelOpenCL = 2,
86 };
87
88 enum ExecutionMode {
89     ExecutionModeInvocations = 0,
90     ExecutionModeSpacingEqual = 1,
91     ExecutionModeSpacingFractionalEven = 2,
92     ExecutionModeSpacingFractionalOdd = 3,
93     ExecutionModeVertexOrderCw = 4,
94     ExecutionModeVertexOrderCcw = 5,
95     ExecutionModePixelCenterInteger = 6,
96     ExecutionModeOriginUpperLeft = 7,
97     ExecutionModeOriginLowerLeft = 8,
98     ExecutionModeEarlyFragmentTests = 9,
99     ExecutionModePointMode = 10,
100     ExecutionModeXfb = 11,
101     ExecutionModeDepthReplacing = 12,
102     ExecutionModeDepthGreater = 14,
103     ExecutionModeDepthLess = 15,
104     ExecutionModeDepthUnchanged = 16,
105     ExecutionModeLocalSize = 17,
106     ExecutionModeLocalSizeHint = 18,
107     ExecutionModeInputPoints = 19,
108     ExecutionModeInputLines = 20,
109     ExecutionModeInputLinesAdjacency = 21,
110     ExecutionModeTriangles = 22,
111     ExecutionModeInputTrianglesAdjacency = 23,
112     ExecutionModeQuads = 24,
113     ExecutionModeIsolines = 25,
114     ExecutionModeOutputVertices = 26,
115     ExecutionModeOutputPoints = 27,
116     ExecutionModeOutputLineStrip = 28,
117     ExecutionModeOutputTriangleStrip = 29,
118     ExecutionModeVecTypeHint = 30,
119     ExecutionModeContractionOff = 31,
120 };
121
122 enum StorageClass {
123     StorageClassUniformConstant = 0,
124     StorageClassInput = 1,
125     StorageClassUniform = 2,
126     StorageClassOutput = 3,
127     StorageClassWorkgroup = 4,
128     StorageClassCrossWorkgroup = 5,
129     StorageClassPrivate = 6,
130     StorageClassFunction = 7,
131     StorageClassGeneric = 8,
132     StorageClassPushConstant = 9,
133     StorageClassAtomicCounter = 10,
134     StorageClassImage = 11,
135 };
136
137 enum Dim {
138     Dim1D = 0,
139     Dim2D = 1,
140     Dim3D = 2,
141     DimCube = 3,
142     DimRect = 4,
143     DimBuffer = 5,
144     DimSubpassData = 6,
145 };
146
147 enum SamplerAddressingMode {
148     SamplerAddressingModeNone = 0,
149     SamplerAddressingModeClampToEdge = 1,
150     SamplerAddressingModeClamp = 2,
151     SamplerAddressingModeRepeat = 3,
152     SamplerAddressingModeRepeatMirrored = 4,
153 };
154
155 enum SamplerFilterMode {
156     SamplerFilterModeNearest = 0,
157     SamplerFilterModeLinear = 1,
158 };
159
160 enum ImageFormat {
161     ImageFormatUnknown = 0,
162     ImageFormatRgba32f = 1,
163     ImageFormatRgba16f = 2,
164     ImageFormatR32f = 3,
165     ImageFormatRgba8 = 4,
166     ImageFormatRgba8Snorm = 5,
167     ImageFormatRg32f = 6,
168     ImageFormatRg16f = 7,
169     ImageFormatR11fG11fB10f = 8,
170     ImageFormatR16f = 9,
171     ImageFormatRgba16 = 10,
172     ImageFormatRgb10A2 = 11,
173     ImageFormatRg16 = 12,
174     ImageFormatRg8 = 13,
175     ImageFormatR16 = 14,
176     ImageFormatR8 = 15,
177     ImageFormatRgba16Snorm = 16,
178     ImageFormatRg16Snorm = 17,
179     ImageFormatRg8Snorm = 18,
180     ImageFormatR16Snorm = 19,
181     ImageFormatR8Snorm = 20,
182     ImageFormatRgba32i = 21,
183     ImageFormatRgba16i = 22,
184     ImageFormatRgba8i = 23,
185     ImageFormatR32i = 24,
186     ImageFormatRg32i = 25,
187     ImageFormatRg16i = 26,
188     ImageFormatRg8i = 27,
189     ImageFormatR16i = 28,
190     ImageFormatR8i = 29,
191     ImageFormatRgba32ui = 30,
192     ImageFormatRgba16ui = 31,
193     ImageFormatRgba8ui = 32,
194     ImageFormatR32ui = 33,
195     ImageFormatRgb10a2ui = 34,
196     ImageFormatRg32ui = 35,
197     ImageFormatRg16ui = 36,
198     ImageFormatRg8ui = 37,
199     ImageFormatR16ui = 38,
200     ImageFormatR8ui = 39,
201 };
202
203 enum ImageChannelOrder {
204     ImageChannelOrderR = 0,
205     ImageChannelOrderA = 1,
206     ImageChannelOrderRG = 2,
207     ImageChannelOrderRA = 3,
208     ImageChannelOrderRGB = 4,
209     ImageChannelOrderRGBA = 5,
210     ImageChannelOrderBGRA = 6,
211     ImageChannelOrderARGB = 7,
212     ImageChannelOrderIntensity = 8,
213     ImageChannelOrderLuminance = 9,
214     ImageChannelOrderRx = 10,
215     ImageChannelOrderRGx = 11,
216     ImageChannelOrderRGBx = 12,
217     ImageChannelOrderDepth = 13,
218     ImageChannelOrderDepthStencil = 14,
219     ImageChannelOrdersRGB = 15,
220     ImageChannelOrdersRGBx = 16,
221     ImageChannelOrdersRGBA = 17,
222     ImageChannelOrdersBGRA = 18,
223 };
224
225 enum ImageChannelDataType {
226     ImageChannelDataTypeSnormInt8 = 0,
227     ImageChannelDataTypeSnormInt16 = 1,
228     ImageChannelDataTypeUnormInt8 = 2,
229     ImageChannelDataTypeUnormInt16 = 3,
230     ImageChannelDataTypeUnormShort565 = 4,
231     ImageChannelDataTypeUnormShort555 = 5,
232     ImageChannelDataTypeUnormInt101010 = 6,
233     ImageChannelDataTypeSignedInt8 = 7,
234     ImageChannelDataTypeSignedInt16 = 8,
235     ImageChannelDataTypeSignedInt32 = 9,
236     ImageChannelDataTypeUnsignedInt8 = 10,
237     ImageChannelDataTypeUnsignedInt16 = 11,
238     ImageChannelDataTypeUnsignedInt32 = 12,
239     ImageChannelDataTypeHalfFloat = 13,
240     ImageChannelDataTypeFloat = 14,
241     ImageChannelDataTypeUnormInt24 = 15,
242     ImageChannelDataTypeUnormInt101010_2 = 16,
243 };
244
245 enum ImageOperandsShift {
246     ImageOperandsBiasShift = 0,
247     ImageOperandsLodShift = 1,
248     ImageOperandsGradShift = 2,
249     ImageOperandsConstOffsetShift = 3,
250     ImageOperandsOffsetShift = 4,
251     ImageOperandsConstOffsetsShift = 5,
252     ImageOperandsSampleShift = 6,
253     ImageOperandsMinLodShift = 7,
254 };
255
256 enum ImageOperandsMask {
257     ImageOperandsMaskNone = 0,
258     ImageOperandsBiasMask = 0x00000001,
259     ImageOperandsLodMask = 0x00000002,
260     ImageOperandsGradMask = 0x00000004,
261     ImageOperandsConstOffsetMask = 0x00000008,
262     ImageOperandsOffsetMask = 0x00000010,
263     ImageOperandsConstOffsetsMask = 0x00000020,
264     ImageOperandsSampleMask = 0x00000040,
265     ImageOperandsMinLodMask = 0x00000080,
266 };
267
268 enum FPFastMathModeShift {
269     FPFastMathModeNotNaNShift = 0,
270     FPFastMathModeNotInfShift = 1,
271     FPFastMathModeNSZShift = 2,
272     FPFastMathModeAllowRecipShift = 3,
273     FPFastMathModeFastShift = 4,
274 };
275
276 enum FPFastMathModeMask {
277     FPFastMathModeMaskNone = 0,
278     FPFastMathModeNotNaNMask = 0x00000001,
279     FPFastMathModeNotInfMask = 0x00000002,
280     FPFastMathModeNSZMask = 0x00000004,
281     FPFastMathModeAllowRecipMask = 0x00000008,
282     FPFastMathModeFastMask = 0x00000010,
283 };
284
285 enum FPRoundingMode {
286     FPRoundingModeRTE = 0,
287     FPRoundingModeRTZ = 1,
288     FPRoundingModeRTP = 2,
289     FPRoundingModeRTN = 3,
290 };
291
292 enum LinkageType {
293     LinkageTypeExport = 0,
294     LinkageTypeImport = 1,
295 };
296
297 enum AccessQualifier {
298     AccessQualifierReadOnly = 0,
299     AccessQualifierWriteOnly = 1,
300     AccessQualifierReadWrite = 2,
301 };
302
303 enum FunctionParameterAttribute {
304     FunctionParameterAttributeZext = 0,
305     FunctionParameterAttributeSext = 1,
306     FunctionParameterAttributeByVal = 2,
307     FunctionParameterAttributeSret = 3,
308     FunctionParameterAttributeNoAlias = 4,
309     FunctionParameterAttributeNoCapture = 5,
310     FunctionParameterAttributeNoWrite = 6,
311     FunctionParameterAttributeNoReadWrite = 7,
312 };
313
314 enum Decoration {
315     DecorationRelaxedPrecision = 0,
316     DecorationSpecId = 1,
317     DecorationBlock = 2,
318     DecorationBufferBlock = 3,
319     DecorationRowMajor = 4,
320     DecorationColMajor = 5,
321     DecorationArrayStride = 6,
322     DecorationMatrixStride = 7,
323     DecorationGLSLShared = 8,
324     DecorationGLSLPacked = 9,
325     DecorationCPacked = 10,
326     DecorationBuiltIn = 11,
327     DecorationNoPerspective = 13,
328     DecorationFlat = 14,
329     DecorationPatch = 15,
330     DecorationCentroid = 16,
331     DecorationSample = 17,
332     DecorationInvariant = 18,
333     DecorationRestrict = 19,
334     DecorationAliased = 20,
335     DecorationVolatile = 21,
336     DecorationConstant = 22,
337     DecorationCoherent = 23,
338     DecorationNonWritable = 24,
339     DecorationNonReadable = 25,
340     DecorationUniform = 26,
341     DecorationSaturatedConversion = 28,
342     DecorationStream = 29,
343     DecorationLocation = 30,
344     DecorationComponent = 31,
345     DecorationIndex = 32,
346     DecorationBinding = 33,
347     DecorationDescriptorSet = 34,
348     DecorationOffset = 35,
349     DecorationXfbBuffer = 36,
350     DecorationXfbStride = 37,
351     DecorationFuncParamAttr = 38,
352     DecorationFPRoundingMode = 39,
353     DecorationFPFastMathMode = 40,
354     DecorationLinkageAttributes = 41,
355     DecorationNoContraction = 42,
356     DecorationInputAttachmentIndex = 43,
357     DecorationAlignment = 44,
358 };
359
360 enum BuiltIn {
361     BuiltInPosition = 0,
362     BuiltInPointSize = 1,
363     BuiltInClipDistance = 3,
364     BuiltInCullDistance = 4,
365     BuiltInVertexId = 5,
366     BuiltInInstanceId = 6,
367     BuiltInPrimitiveId = 7,
368     BuiltInInvocationId = 8,
369     BuiltInLayer = 9,
370     BuiltInViewportIndex = 10,
371     BuiltInTessLevelOuter = 11,
372     BuiltInTessLevelInner = 12,
373     BuiltInTessCoord = 13,
374     BuiltInPatchVertices = 14,
375     BuiltInFragCoord = 15,
376     BuiltInPointCoord = 16,
377     BuiltInFrontFacing = 17,
378     BuiltInSampleId = 18,
379     BuiltInSamplePosition = 19,
380     BuiltInSampleMask = 20,
381     BuiltInFragDepth = 22,
382     BuiltInHelperInvocation = 23,
383     BuiltInNumWorkgroups = 24,
384     BuiltInWorkgroupSize = 25,
385     BuiltInWorkgroupId = 26,
386     BuiltInLocalInvocationId = 27,
387     BuiltInGlobalInvocationId = 28,
388     BuiltInLocalInvocationIndex = 29,
389     BuiltInWorkDim = 30,
390     BuiltInGlobalSize = 31,
391     BuiltInEnqueuedWorkgroupSize = 32,
392     BuiltInGlobalOffset = 33,
393     BuiltInGlobalLinearId = 34,
394     BuiltInSubgroupSize = 36,
395     BuiltInSubgroupMaxSize = 37,
396     BuiltInNumSubgroups = 38,
397     BuiltInNumEnqueuedSubgroups = 39,
398     BuiltInSubgroupId = 40,
399     BuiltInSubgroupLocalInvocationId = 41,
400     BuiltInVertexIndex = 42,
401     BuiltInInstanceIndex = 43,
402 };
403
404 enum SelectionControlShift {
405     SelectionControlFlattenShift = 0,
406     SelectionControlDontFlattenShift = 1,
407 };
408
409 enum SelectionControlMask {
410     SelectionControlMaskNone = 0,
411     SelectionControlFlattenMask = 0x00000001,
412     SelectionControlDontFlattenMask = 0x00000002,
413 };
414
415 enum LoopControlShift {
416     LoopControlUnrollShift = 0,
417     LoopControlDontUnrollShift = 1,
418 };
419
420 enum LoopControlMask {
421     LoopControlMaskNone = 0,
422     LoopControlUnrollMask = 0x00000001,
423     LoopControlDontUnrollMask = 0x00000002,
424 };
425
426 enum FunctionControlShift {
427     FunctionControlInlineShift = 0,
428     FunctionControlDontInlineShift = 1,
429     FunctionControlPureShift = 2,
430     FunctionControlConstShift = 3,
431 };
432
433 enum FunctionControlMask {
434     FunctionControlMaskNone = 0,
435     FunctionControlInlineMask = 0x00000001,
436     FunctionControlDontInlineMask = 0x00000002,
437     FunctionControlPureMask = 0x00000004,
438     FunctionControlConstMask = 0x00000008,
439 };
440
441 enum MemorySemanticsShift {
442     MemorySemanticsAcquireShift = 1,
443     MemorySemanticsReleaseShift = 2,
444     MemorySemanticsAcquireReleaseShift = 3,
445     MemorySemanticsSequentiallyConsistentShift = 4,
446     MemorySemanticsUniformMemoryShift = 6,
447     MemorySemanticsSubgroupMemoryShift = 7,
448     MemorySemanticsWorkgroupMemoryShift = 8,
449     MemorySemanticsCrossWorkgroupMemoryShift = 9,
450     MemorySemanticsAtomicCounterMemoryShift = 10,
451     MemorySemanticsImageMemoryShift = 11,
452 };
453
454 enum MemorySemanticsMask {
455     MemorySemanticsMaskNone = 0,
456     MemorySemanticsAcquireMask = 0x00000002,
457     MemorySemanticsReleaseMask = 0x00000004,
458     MemorySemanticsAcquireReleaseMask = 0x00000008,
459     MemorySemanticsSequentiallyConsistentMask = 0x00000010,
460     MemorySemanticsUniformMemoryMask = 0x00000040,
461     MemorySemanticsSubgroupMemoryMask = 0x00000080,
462     MemorySemanticsWorkgroupMemoryMask = 0x00000100,
463     MemorySemanticsCrossWorkgroupMemoryMask = 0x00000200,
464     MemorySemanticsAtomicCounterMemoryMask = 0x00000400,
465     MemorySemanticsImageMemoryMask = 0x00000800,
466 };
467
468 enum MemoryAccessShift {
469     MemoryAccessVolatileShift = 0,
470     MemoryAccessAlignedShift = 1,
471     MemoryAccessNontemporalShift = 2,
472 };
473
474 enum MemoryAccessMask {
475     MemoryAccessMaskNone = 0,
476     MemoryAccessVolatileMask = 0x00000001,
477     MemoryAccessAlignedMask = 0x00000002,
478     MemoryAccessNontemporalMask = 0x00000004,
479 };
480
481 enum Scope {
482     ScopeCrossDevice = 0,
483     ScopeDevice = 1,
484     ScopeWorkgroup = 2,
485     ScopeSubgroup = 3,
486     ScopeInvocation = 4,
487 };
488
489 enum GroupOperation {
490     GroupOperationReduce = 0,
491     GroupOperationInclusiveScan = 1,
492     GroupOperationExclusiveScan = 2,
493 };
494
495 enum KernelEnqueueFlags {
496     KernelEnqueueFlagsNoWait = 0,
497     KernelEnqueueFlagsWaitKernel = 1,
498     KernelEnqueueFlagsWaitWorkGroup = 2,
499 };
500
501 enum KernelProfilingInfoShift {
502     KernelProfilingInfoCmdExecTimeShift = 0,
503 };
504
505 enum KernelProfilingInfoMask {
506     KernelProfilingInfoMaskNone = 0,
507     KernelProfilingInfoCmdExecTimeMask = 0x00000001,
508 };
509
510 enum Capability {
511     CapabilityMatrix = 0,
512     CapabilityShader = 1,
513     CapabilityGeometry = 2,
514     CapabilityTessellation = 3,
515     CapabilityAddresses = 4,
516     CapabilityLinkage = 5,
517     CapabilityKernel = 6,
518     CapabilityVector16 = 7,
519     CapabilityFloat16Buffer = 8,
520     CapabilityFloat16 = 9,
521     CapabilityFloat64 = 10,
522     CapabilityInt64 = 11,
523     CapabilityInt64Atomics = 12,
524     CapabilityImageBasic = 13,
525     CapabilityImageReadWrite = 14,
526     CapabilityImageMipmap = 15,
527     CapabilityPipes = 17,
528     CapabilityGroups = 18,
529     CapabilityDeviceEnqueue = 19,
530     CapabilityLiteralSampler = 20,
531     CapabilityAtomicStorage = 21,
532     CapabilityInt16 = 22,
533     CapabilityTessellationPointSize = 23,
534     CapabilityGeometryPointSize = 24,
535     CapabilityImageGatherExtended = 25,
536     CapabilityStorageImageMultisample = 27,
537     CapabilityUniformBufferArrayDynamicIndexing = 28,
538     CapabilitySampledImageArrayDynamicIndexing = 29,
539     CapabilityStorageBufferArrayDynamicIndexing = 30,
540     CapabilityStorageImageArrayDynamicIndexing = 31,
541     CapabilityClipDistance = 32,
542     CapabilityCullDistance = 33,
543     CapabilityImageCubeArray = 34,
544     CapabilitySampleRateShading = 35,
545     CapabilityImageRect = 36,
546     CapabilitySampledRect = 37,
547     CapabilityGenericPointer = 38,
548     CapabilityInt8 = 39,
549     CapabilityInputAttachment = 40,
550     CapabilitySparseResidency = 41,
551     CapabilityMinLod = 42,
552     CapabilitySampled1D = 43,
553     CapabilityImage1D = 44,
554     CapabilitySampledCubeArray = 45,
555     CapabilitySampledBuffer = 46,
556     CapabilityImageBuffer = 47,
557     CapabilityImageMSArray = 48,
558     CapabilityStorageImageExtendedFormats = 49,
559     CapabilityImageQuery = 50,
560     CapabilityDerivativeControl = 51,
561     CapabilityInterpolationFunction = 52,
562     CapabilityTransformFeedback = 53,
563     CapabilityGeometryStreams = 54,
564     CapabilityStorageImageReadWithoutFormat = 55,
565     CapabilityStorageImageWriteWithoutFormat = 56,
566     CapabilityMultiViewport = 57,
567 };
568
569 enum Op {
570     OpNop = 0,
571     OpUndef = 1,
572     OpSourceContinued = 2,
573     OpSource = 3,
574     OpSourceExtension = 4,
575     OpName = 5,
576     OpMemberName = 6,
577     OpString = 7,
578     OpLine = 8,
579     OpExtension = 10,
580     OpExtInstImport = 11,
581     OpExtInst = 12,
582     OpMemoryModel = 14,
583     OpEntryPoint = 15,
584     OpExecutionMode = 16,
585     OpCapability = 17,
586     OpTypeVoid = 19,
587     OpTypeBool = 20,
588     OpTypeInt = 21,
589     OpTypeFloat = 22,
590     OpTypeVector = 23,
591     OpTypeMatrix = 24,
592     OpTypeImage = 25,
593     OpTypeSampler = 26,
594     OpTypeSampledImage = 27,
595     OpTypeArray = 28,
596     OpTypeRuntimeArray = 29,
597     OpTypeStruct = 30,
598     OpTypeOpaque = 31,
599     OpTypePointer = 32,
600     OpTypeFunction = 33,
601     OpTypeEvent = 34,
602     OpTypeDeviceEvent = 35,
603     OpTypeReserveId = 36,
604     OpTypeQueue = 37,
605     OpTypePipe = 38,
606     OpTypeForwardPointer = 39,
607     OpConstantTrue = 41,
608     OpConstantFalse = 42,
609     OpConstant = 43,
610     OpConstantComposite = 44,
611     OpConstantSampler = 45,
612     OpConstantNull = 46,
613     OpSpecConstantTrue = 48,
614     OpSpecConstantFalse = 49,
615     OpSpecConstant = 50,
616     OpSpecConstantComposite = 51,
617     OpSpecConstantOp = 52,
618     OpFunction = 54,
619     OpFunctionParameter = 55,
620     OpFunctionEnd = 56,
621     OpFunctionCall = 57,
622     OpVariable = 59,
623     OpImageTexelPointer = 60,
624     OpLoad = 61,
625     OpStore = 62,
626     OpCopyMemory = 63,
627     OpCopyMemorySized = 64,
628     OpAccessChain = 65,
629     OpInBoundsAccessChain = 66,
630     OpPtrAccessChain = 67,
631     OpArrayLength = 68,
632     OpGenericPtrMemSemantics = 69,
633     OpInBoundsPtrAccessChain = 70,
634     OpDecorate = 71,
635     OpMemberDecorate = 72,
636     OpDecorationGroup = 73,
637     OpGroupDecorate = 74,
638     OpGroupMemberDecorate = 75,
639     OpVectorExtractDynamic = 77,
640     OpVectorInsertDynamic = 78,
641     OpVectorShuffle = 79,
642     OpCompositeConstruct = 80,
643     OpCompositeExtract = 81,
644     OpCompositeInsert = 82,
645     OpCopyObject = 83,
646     OpTranspose = 84,
647     OpSampledImage = 86,
648     OpImageSampleImplicitLod = 87,
649     OpImageSampleExplicitLod = 88,
650     OpImageSampleDrefImplicitLod = 89,
651     OpImageSampleDrefExplicitLod = 90,
652     OpImageSampleProjImplicitLod = 91,
653     OpImageSampleProjExplicitLod = 92,
654     OpImageSampleProjDrefImplicitLod = 93,
655     OpImageSampleProjDrefExplicitLod = 94,
656     OpImageFetch = 95,
657     OpImageGather = 96,
658     OpImageDrefGather = 97,
659     OpImageRead = 98,
660     OpImageWrite = 99,
661     OpImage = 100,
662     OpImageQueryFormat = 101,
663     OpImageQueryOrder = 102,
664     OpImageQuerySizeLod = 103,
665     OpImageQuerySize = 104,
666     OpImageQueryLod = 105,
667     OpImageQueryLevels = 106,
668     OpImageQuerySamples = 107,
669     OpConvertFToU = 109,
670     OpConvertFToS = 110,
671     OpConvertSToF = 111,
672     OpConvertUToF = 112,
673     OpUConvert = 113,
674     OpSConvert = 114,
675     OpFConvert = 115,
676     OpQuantizeToF16 = 116,
677     OpConvertPtrToU = 117,
678     OpSatConvertSToU = 118,
679     OpSatConvertUToS = 119,
680     OpConvertUToPtr = 120,
681     OpPtrCastToGeneric = 121,
682     OpGenericCastToPtr = 122,
683     OpGenericCastToPtrExplicit = 123,
684     OpBitcast = 124,
685     OpSNegate = 126,
686     OpFNegate = 127,
687     OpIAdd = 128,
688     OpFAdd = 129,
689     OpISub = 130,
690     OpFSub = 131,
691     OpIMul = 132,
692     OpFMul = 133,
693     OpUDiv = 134,
694     OpSDiv = 135,
695     OpFDiv = 136,
696     OpUMod = 137,
697     OpSRem = 138,
698     OpSMod = 139,
699     OpFRem = 140,
700     OpFMod = 141,
701     OpVectorTimesScalar = 142,
702     OpMatrixTimesScalar = 143,
703     OpVectorTimesMatrix = 144,
704     OpMatrixTimesVector = 145,
705     OpMatrixTimesMatrix = 146,
706     OpOuterProduct = 147,
707     OpDot = 148,
708     OpIAddCarry = 149,
709     OpISubBorrow = 150,
710     OpUMulExtended = 151,
711     OpSMulExtended = 152,
712     OpAny = 154,
713     OpAll = 155,
714     OpIsNan = 156,
715     OpIsInf = 157,
716     OpIsFinite = 158,
717     OpIsNormal = 159,
718     OpSignBitSet = 160,
719     OpLessOrGreater = 161,
720     OpOrdered = 162,
721     OpUnordered = 163,
722     OpLogicalEqual = 164,
723     OpLogicalNotEqual = 165,
724     OpLogicalOr = 166,
725     OpLogicalAnd = 167,
726     OpLogicalNot = 168,
727     OpSelect = 169,
728     OpIEqual = 170,
729     OpINotEqual = 171,
730     OpUGreaterThan = 172,
731     OpSGreaterThan = 173,
732     OpUGreaterThanEqual = 174,
733     OpSGreaterThanEqual = 175,
734     OpULessThan = 176,
735     OpSLessThan = 177,
736     OpULessThanEqual = 178,
737     OpSLessThanEqual = 179,
738     OpFOrdEqual = 180,
739     OpFUnordEqual = 181,
740     OpFOrdNotEqual = 182,
741     OpFUnordNotEqual = 183,
742     OpFOrdLessThan = 184,
743     OpFUnordLessThan = 185,
744     OpFOrdGreaterThan = 186,
745     OpFUnordGreaterThan = 187,
746     OpFOrdLessThanEqual = 188,
747     OpFUnordLessThanEqual = 189,
748     OpFOrdGreaterThanEqual = 190,
749     OpFUnordGreaterThanEqual = 191,
750     OpShiftRightLogical = 194,
751     OpShiftRightArithmetic = 195,
752     OpShiftLeftLogical = 196,
753     OpBitwiseOr = 197,
754     OpBitwiseXor = 198,
755     OpBitwiseAnd = 199,
756     OpNot = 200,
757     OpBitFieldInsert = 201,
758     OpBitFieldSExtract = 202,
759     OpBitFieldUExtract = 203,
760     OpBitReverse = 204,
761     OpBitCount = 205,
762     OpDPdx = 207,
763     OpDPdy = 208,
764     OpFwidth = 209,
765     OpDPdxFine = 210,
766     OpDPdyFine = 211,
767     OpFwidthFine = 212,
768     OpDPdxCoarse = 213,
769     OpDPdyCoarse = 214,
770     OpFwidthCoarse = 215,
771     OpEmitVertex = 218,
772     OpEndPrimitive = 219,
773     OpEmitStreamVertex = 220,
774     OpEndStreamPrimitive = 221,
775     OpControlBarrier = 224,
776     OpMemoryBarrier = 225,
777     OpAtomicLoad = 227,
778     OpAtomicStore = 228,
779     OpAtomicExchange = 229,
780     OpAtomicCompareExchange = 230,
781     OpAtomicCompareExchangeWeak = 231,
782     OpAtomicIIncrement = 232,
783     OpAtomicIDecrement = 233,
784     OpAtomicIAdd = 234,
785     OpAtomicISub = 235,
786     OpAtomicSMin = 236,
787     OpAtomicUMin = 237,
788     OpAtomicSMax = 238,
789     OpAtomicUMax = 239,
790     OpAtomicAnd = 240,
791     OpAtomicOr = 241,
792     OpAtomicXor = 242,
793     OpPhi = 245,
794     OpLoopMerge = 246,
795     OpSelectionMerge = 247,
796     OpLabel = 248,
797     OpBranch = 249,
798     OpBranchConditional = 250,
799     OpSwitch = 251,
800     OpKill = 252,
801     OpReturn = 253,
802     OpReturnValue = 254,
803     OpUnreachable = 255,
804     OpLifetimeStart = 256,
805     OpLifetimeStop = 257,
806     OpGroupAsyncCopy = 259,
807     OpGroupWaitEvents = 260,
808     OpGroupAll = 261,
809     OpGroupAny = 262,
810     OpGroupBroadcast = 263,
811     OpGroupIAdd = 264,
812     OpGroupFAdd = 265,
813     OpGroupFMin = 266,
814     OpGroupUMin = 267,
815     OpGroupSMin = 268,
816     OpGroupFMax = 269,
817     OpGroupUMax = 270,
818     OpGroupSMax = 271,
819     OpReadPipe = 274,
820     OpWritePipe = 275,
821     OpReservedReadPipe = 276,
822     OpReservedWritePipe = 277,
823     OpReserveReadPipePackets = 278,
824     OpReserveWritePipePackets = 279,
825     OpCommitReadPipe = 280,
826     OpCommitWritePipe = 281,
827     OpIsValidReserveId = 282,
828     OpGetNumPipePackets = 283,
829     OpGetMaxPipePackets = 284,
830     OpGroupReserveReadPipePackets = 285,
831     OpGroupReserveWritePipePackets = 286,
832     OpGroupCommitReadPipe = 287,
833     OpGroupCommitWritePipe = 288,
834     OpEnqueueMarker = 291,
835     OpEnqueueKernel = 292,
836     OpGetKernelNDrangeSubGroupCount = 293,
837     OpGetKernelNDrangeMaxSubGroupSize = 294,
838     OpGetKernelWorkGroupSize = 295,
839     OpGetKernelPreferredWorkGroupSizeMultiple = 296,
840     OpRetainEvent = 297,
841     OpReleaseEvent = 298,
842     OpCreateUserEvent = 299,
843     OpIsValidEvent = 300,
844     OpSetUserEventStatus = 301,
845     OpCaptureEventProfilingInfo = 302,
846     OpGetDefaultQueue = 303,
847     OpBuildNDRange = 304,
848     OpImageSparseSampleImplicitLod = 305,
849     OpImageSparseSampleExplicitLod = 306,
850     OpImageSparseSampleDrefImplicitLod = 307,
851     OpImageSparseSampleDrefExplicitLod = 308,
852     OpImageSparseSampleProjImplicitLod = 309,
853     OpImageSparseSampleProjExplicitLod = 310,
854     OpImageSparseSampleProjDrefImplicitLod = 311,
855     OpImageSparseSampleProjDrefExplicitLod = 312,
856     OpImageSparseFetch = 313,
857     OpImageSparseGather = 314,
858     OpImageSparseDrefGather = 315,
859     OpImageSparseTexelsResident = 316,
860     OpNoLine = 317,
861     OpAtomicFlagTestAndSet = 318,
862     OpAtomicFlagClear = 319,
863     OpImageSparseRead = 320,
864 };
865
866 // Overload operator| for mask bit combining
867
868 inline ImageOperandsMask operator|(ImageOperandsMask a, ImageOperandsMask b) { return ImageOperandsMask(unsigned(a) | unsigned(b)); }
869 inline FPFastMathModeMask operator|(FPFastMathModeMask a, FPFastMathModeMask b) { return FPFastMathModeMask(unsigned(a) | unsigned(b)); }
870 inline SelectionControlMask operator|(SelectionControlMask a, SelectionControlMask b) { return SelectionControlMask(unsigned(a) | unsigned(b)); }
871 inline LoopControlMask operator|(LoopControlMask a, LoopControlMask b) { return LoopControlMask(unsigned(a) | unsigned(b)); }
872 inline FunctionControlMask operator|(FunctionControlMask a, FunctionControlMask b) { return FunctionControlMask(unsigned(a) | unsigned(b)); }
873 inline MemorySemanticsMask operator|(MemorySemanticsMask a, MemorySemanticsMask b) { return MemorySemanticsMask(unsigned(a) | unsigned(b)); }
874 inline MemoryAccessMask operator|(MemoryAccessMask a, MemoryAccessMask b) { return MemoryAccessMask(unsigned(a) | unsigned(b)); }
875 inline KernelProfilingInfoMask operator|(KernelProfilingInfoMask a, KernelProfilingInfoMask b) { return KernelProfilingInfoMask(unsigned(a) | unsigned(b)); }
876
877 }  // end namespace spv
878
879 #endif  // #ifndef spirv_HPP
880