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