Commit 035acbd2 by Alexis Hetu

Squashed 'third_party/SPIRV-Headers/' changes from 204cd131c..f8bf11a02

f8bf11a02 Merge pull request #149 from dgkoch/prov_ray_tracing fdbc0d1c4 Add shadercalls scope 9a186c772 Added ray flags, primitive culling flags, queries 9e8e6aff3 Non-functional: Update header build to match Khronos spec. builder. 8830d1d77 Merge pull request #135 from vulturm/patch-1 95b48cedd Update headers for SPV_KHR_ray_tracing. a17e17e36 Merge pull request #148 from null77/fix-gn 976926d58 Add missing header to BUILD.gn. 30ef660ce Merge pull request #146 from s-perron/bazel 0d334e4ad Export NonSemanticDebugPrintf.h in bazel build d9ce9ca52 Merge pull request #145 from jeffbolznv/nonsemantic_debugprintf e814bf006 Add NonSemantic.DebugPrintf JSON/header 89bef4096 Fix max enum value 0a7fc4525 Add grammars, C header, and header generator for vendor and KHR extended instruction sets (#143) 5dbc1c321 Merge pull request #142 from mkinsner/additional_loop_control_bits 4b013f0fd Allocate three bits for upcoming Intel extension dc77030ac Merge pull request #141 from dneto0/update-buildgn-lic 9c63d5773 Fix the license to match LICENSE 0125ae61b Merge pull request #140 from ShabbyX/add_build_gn c7f52d34c Add BUILD.gn 927aae4dc Also propagate SPIRV-Headers version to CMakeLists.txt git-subtree-dir: third_party/SPIRV-Headers git-subtree-split: f8bf11a0253a32375c32cad92c841237b96696c0
parent 2c8ca519
...@@ -81,6 +81,7 @@ cc_library( ...@@ -81,6 +81,7 @@ cc_library(
"include/spirv/1.2/GLSL.std.450.h", "include/spirv/1.2/GLSL.std.450.h",
"include/spirv/1.2/OpenCL.std.h", "include/spirv/1.2/OpenCL.std.h",
"include/spirv/unified1/GLSL.std.450.h", "include/spirv/unified1/GLSL.std.450.h",
"include/spirv/unified1/NonSemanticDebugPrintf.h",
"include/spirv/unified1/OpenCL.std.h", "include/spirv/unified1/OpenCL.std.h",
], ],
includes = ["include"], includes = ["include"],
......
# Copyright (c) 2020 Google LLC
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and/or associated documentation files (the "Materials"),
# to deal in the Materials without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Materials, and to permit persons to whom the
# Materials are furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Materials.
#
# MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS KHRONOS
# STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS SPECIFICATIONS AND
# HEADER INFORMATION ARE LOCATED AT https://www.khronos.org/registry/
#
# THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM,OUT OF OR IN CONNECTION WITH THE MATERIALS OR THE USE OR OTHER DEALINGS
# IN THE MATERIALS.
config("spv_headers_public_config") {
include_dirs = [ "include" ]
}
source_set("spv_headers") {
sources = [
"include/spirv/1.2/GLSL.std.450.h",
"include/spirv/1.2/OpenCL.std.h",
"include/spirv/1.2/spirv.h",
"include/spirv/1.2/spirv.hpp",
"include/spirv/unified1/GLSL.std.450.h",
"include/spirv/unified1/NonSemanticDebugPrintf.h",
"include/spirv/unified1/OpenCL.std.h",
"include/spirv/unified1/spirv.h",
"include/spirv/unified1/spirv.hpp",
]
public_configs = [ ":spv_headers_public_config" ]
}
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
# https://www.khronos.org/registry/spir-v/ # https://www.khronos.org/registry/spir-v/
# #
cmake_minimum_required(VERSION 3.0) cmake_minimum_required(VERSION 3.0)
project(SPIRV-Headers VERSION 1.4.1) project(SPIRV-Headers VERSION 1.5.1)
# There are two ways to use this project. # There are two ways to use this project.
# #
......
...@@ -119,7 +119,7 @@ cc_library( ...@@ -119,7 +119,7 @@ cc_library(
#include "spirv/unified1/spirv.hpp" #include "spirv/unified1/spirv.hpp"
``` ```
## Generating the headers from the JSON grammar ## Generating headers from the JSON grammar for the SPIR-V core instruction set
This will generally be done by Khronos, for a change to the JSON grammar. This will generally be done by Khronos, for a change to the JSON grammar.
However, the project for the tool to do this is included in this repository, However, the project for the tool to do this is included in this repository,
...@@ -137,6 +137,26 @@ Notes: ...@@ -137,6 +137,26 @@ Notes:
and that influences the languages used, for legacy reasons and that influences the languages used, for legacy reasons
- the C++ structures built may similarly include more than strictly necessary, for the same reason - the C++ structures built may similarly include more than strictly necessary, for the same reason
## Generating C headers for extended instruction sets
The [GLSL.std.450.h](include/spirv/unified1/GLSL.std.450.h)
and [OpenCL.std.h](include/spirv/unified1/OpenCL.std.h) extended instruction set headers
are maintained manually.
The C/C++ header for each of the other extended instruction sets
is generated from the corresponding JSON grammar file. For example, the
[OpenCLDebugInfo100.h](include/spirv/unified1/OpenCLDebugInfo100.h) header
is generated from the
[extinst.opencl.debuginfo.100.grammar.json](include/spirv/unified1/extinst.opencl.debuginfo.100.grammar.json)
grammar file.
To generate these C/C++ headers, first make sure `python3` is in your PATH, then
invoke the build script as follows:
```
cd tools/buildHeaders
python3 bin/makeExtinstHeaders.py
```
## FAQ ## FAQ
* *How are different versions published?* * *How are different versions published?*
......
...@@ -139,8 +139,8 @@ ...@@ -139,8 +139,8 @@
<!-- Reserved loop control bits --> <!-- Reserved loop control bits -->
<ids type="LoopControl" start="0" end="15" vendor="Khronos" comment="Reserved LoopControl bits, not available to vendors - see the SPIR-V Specification"/> <ids type="LoopControl" start="0" end="15" vendor="Khronos" comment="Reserved LoopControl bits, not available to vendors - see the SPIR-V Specification"/>
<ids type="LoopControl" start="16" end="19" vendor="Intel" comment="Contact michael.kinsner@intel.com"/> <ids type="LoopControl" start="16" end="22" vendor="Intel" comment="Contact michael.kinsner@intel.com"/>
<ids type="LoopControl" start="20" end="30" comment="Unreserved bits reservable for use by vendors"/> <ids type="LoopControl" start="23" end="30" comment="Unreserved bits reservable for use by vendors"/>
<ids type="LoopControl" start="31" end="31" vendor="Khronos" comment="Reserved LoopControl bit, not available to vendors"/> <ids type="LoopControl" start="31" end="31" vendor="Khronos" comment="Reserved LoopControl bit, not available to vendors"/>
</registry> </registry>
// Copyright (c) 2020 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Materials, and to
// permit persons to whom the Materials are furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
// KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
// SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
// https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
//
#ifndef SPIRV_UNIFIED1_AMD_gcn_shader_H_
#define SPIRV_UNIFIED1_AMD_gcn_shader_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
AMD_gcn_shaderRevision = 2,
AMD_gcn_shaderRevision_BitWidthPadding = 0x7fffffff
};
enum AMD_gcn_shaderInstructions {
AMD_gcn_shaderCubeFaceIndexAMD = 1,
AMD_gcn_shaderCubeFaceCoordAMD = 2,
AMD_gcn_shaderTimeAMD = 3,
AMD_gcn_shaderInstructionsMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_AMD_gcn_shader_H_
// Copyright (c) 2020 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Materials, and to
// permit persons to whom the Materials are furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
// KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
// SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
// https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
//
#ifndef SPIRV_UNIFIED1_AMD_shader_ballot_H_
#define SPIRV_UNIFIED1_AMD_shader_ballot_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
AMD_shader_ballotRevision = 5,
AMD_shader_ballotRevision_BitWidthPadding = 0x7fffffff
};
enum AMD_shader_ballotInstructions {
AMD_shader_ballotSwizzleInvocationsAMD = 1,
AMD_shader_ballotSwizzleInvocationsMaskedAMD = 2,
AMD_shader_ballotWriteInvocationAMD = 3,
AMD_shader_ballotMbcntAMD = 4,
AMD_shader_ballotInstructionsMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_AMD_shader_ballot_H_
// Copyright (c) 2020 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Materials, and to
// permit persons to whom the Materials are furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
// KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
// SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
// https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
//
#ifndef SPIRV_UNIFIED1_AMD_shader_explicit_vertex_parameter_H_
#define SPIRV_UNIFIED1_AMD_shader_explicit_vertex_parameter_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
AMD_shader_explicit_vertex_parameterRevision = 4,
AMD_shader_explicit_vertex_parameterRevision_BitWidthPadding = 0x7fffffff
};
enum AMD_shader_explicit_vertex_parameterInstructions {
AMD_shader_explicit_vertex_parameterInterpolateAtVertexAMD = 1,
AMD_shader_explicit_vertex_parameterInstructionsMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_AMD_shader_explicit_vertex_parameter_H_
// Copyright (c) 2020 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Materials, and to
// permit persons to whom the Materials are furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
// KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
// SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
// https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
//
#ifndef SPIRV_UNIFIED1_AMD_shader_trinary_minmax_H_
#define SPIRV_UNIFIED1_AMD_shader_trinary_minmax_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
AMD_shader_trinary_minmaxRevision = 4,
AMD_shader_trinary_minmaxRevision_BitWidthPadding = 0x7fffffff
};
enum AMD_shader_trinary_minmaxInstructions {
AMD_shader_trinary_minmaxFMin3AMD = 1,
AMD_shader_trinary_minmaxUMin3AMD = 2,
AMD_shader_trinary_minmaxSMin3AMD = 3,
AMD_shader_trinary_minmaxFMax3AMD = 4,
AMD_shader_trinary_minmaxUMax3AMD = 5,
AMD_shader_trinary_minmaxSMax3AMD = 6,
AMD_shader_trinary_minmaxFMid3AMD = 7,
AMD_shader_trinary_minmaxUMid3AMD = 8,
AMD_shader_trinary_minmaxSMid3AMD = 9,
AMD_shader_trinary_minmaxInstructionsMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_AMD_shader_trinary_minmax_H_
// Copyright (c) 2017 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and/or associated documentation files (the "Materials"),
// to deal in the Materials without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Materials, and to permit persons to whom the
// Materials are furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS KHRONOS
// STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS SPECIFICATIONS AND
// HEADER INFORMATION ARE LOCATED AT https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM,OUT OF OR IN CONNECTION WITH THE MATERIALS OR THE USE OR OTHER DEALINGS
// IN THE MATERIALS.
#ifndef SPIRV_UNIFIED1_DebugInfo_H_
#define SPIRV_UNIFIED1_DebugInfo_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
DebugInfoVersion = 100,
DebugInfoVersion_BitWidthPadding = 0x7fffffff
};
enum {
DebugInfoRevision = 1,
DebugInfoRevision_BitWidthPadding = 0x7fffffff
};
enum DebugInfoInstructions {
DebugInfoDebugInfoNone = 0,
DebugInfoDebugCompilationUnit = 1,
DebugInfoDebugTypeBasic = 2,
DebugInfoDebugTypePointer = 3,
DebugInfoDebugTypeQualifier = 4,
DebugInfoDebugTypeArray = 5,
DebugInfoDebugTypeVector = 6,
DebugInfoDebugTypedef = 7,
DebugInfoDebugTypeFunction = 8,
DebugInfoDebugTypeEnum = 9,
DebugInfoDebugTypeComposite = 10,
DebugInfoDebugTypeMember = 11,
DebugInfoDebugTypeInheritance = 12,
DebugInfoDebugTypePtrToMember = 13,
DebugInfoDebugTypeTemplate = 14,
DebugInfoDebugTypeTemplateParameter = 15,
DebugInfoDebugTypeTemplateTemplateParameter = 16,
DebugInfoDebugTypeTemplateParameterPack = 17,
DebugInfoDebugGlobalVariable = 18,
DebugInfoDebugFunctionDeclaration = 19,
DebugInfoDebugFunction = 20,
DebugInfoDebugLexicalBlock = 21,
DebugInfoDebugLexicalBlockDiscriminator = 22,
DebugInfoDebugScope = 23,
DebugInfoDebugNoScope = 24,
DebugInfoDebugInlinedAt = 25,
DebugInfoDebugLocalVariable = 26,
DebugInfoDebugInlinedVariable = 27,
DebugInfoDebugDeclare = 28,
DebugInfoDebugValue = 29,
DebugInfoDebugOperation = 30,
DebugInfoDebugExpression = 31,
DebugInfoDebugMacroDef = 32,
DebugInfoDebugMacroUndef = 33,
DebugInfoInstructionsMax = 0x7fffffff
};
enum DebugInfoDebugInfoFlags {
DebugInfoFlagIsProtected = 0x01,
DebugInfoFlagIsPrivate = 0x02,
DebugInfoFlagIsPublic = 0x03,
DebugInfoFlagIsLocal = 0x04,
DebugInfoFlagIsDefinition = 0x08,
DebugInfoFlagFwdDecl = 0x10,
DebugInfoFlagArtificial = 0x20,
DebugInfoFlagExplicit = 0x40,
DebugInfoFlagPrototyped = 0x80,
DebugInfoFlagObjectPointer = 0x100,
DebugInfoFlagStaticMember = 0x200,
DebugInfoFlagIndirectVariable = 0x400,
DebugInfoFlagLValueReference = 0x800,
DebugInfoFlagRValueReference = 0x1000,
DebugInfoFlagIsOptimized = 0x2000,
DebugInfoDebugInfoFlagsMax = 0x7fffffff
};
enum DebugInfoDebugBaseTypeAttributeEncoding {
DebugInfoUnspecified = 0,
DebugInfoAddress = 1,
DebugInfoBoolean = 2,
DebugInfoFloat = 4,
DebugInfoSigned = 5,
DebugInfoSignedChar = 6,
DebugInfoUnsigned = 7,
DebugInfoUnsignedChar = 8,
DebugInfoDebugBaseTypeAttributeEncodingMax = 0x7fffffff
};
enum DebugInfoDebugCompositeType {
DebugInfoClass = 0,
DebugInfoStructure = 1,
DebugInfoUnion = 2,
DebugInfoDebugCompositeTypeMax = 0x7fffffff
};
enum DebugInfoDebugTypeQualifier {
DebugInfoConstType = 0,
DebugInfoVolatileType = 1,
DebugInfoRestrictType = 2,
DebugInfoDebugTypeQualifierMax = 0x7fffffff
};
enum DebugInfoDebugOperation {
DebugInfoDeref = 0,
DebugInfoPlus = 1,
DebugInfoMinus = 2,
DebugInfoPlusUconst = 3,
DebugInfoBitPiece = 4,
DebugInfoSwap = 5,
DebugInfoXderef = 6,
DebugInfoStackValue = 7,
DebugInfoConstu = 8,
DebugInfoDebugOperationMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_DebugInfo_H_
// Copyright (c) 2020 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Materials, and to
// permit persons to whom the Materials are furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
// KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
// SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
// https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
//
#ifndef SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_
#define SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
NonSemanticDebugPrintfRevision = 1,
NonSemanticDebugPrintfRevision_BitWidthPadding = 0x7fffffff
};
enum NonSemanticDebugPrintfInstructions {
NonSemanticDebugPrintfDebugPrintf = 1,
NonSemanticDebugPrintfInstructionsMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_
// Copyright (c) 2018 The Khronos Group Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and/or associated documentation files (the "Materials"),
// to deal in the Materials without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Materials, and to permit persons to whom the
// Materials are furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Materials.
//
// MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS KHRONOS
// STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS SPECIFICATIONS AND
// HEADER INFORMATION ARE LOCATED AT https://www.khronos.org/registry/
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM,OUT OF OR IN CONNECTION WITH THE MATERIALS OR THE USE OR OTHER DEALINGS
// IN THE MATERIALS.
#ifndef SPIRV_UNIFIED1_OpenCLDebugInfo100_H_
#define SPIRV_UNIFIED1_OpenCLDebugInfo100_H_
#ifdef __cplusplus
extern "C" {
#endif
enum {
OpenCLDebugInfo100Version = 200,
OpenCLDebugInfo100Version_BitWidthPadding = 0x7fffffff
};
enum {
OpenCLDebugInfo100Revision = 2,
OpenCLDebugInfo100Revision_BitWidthPadding = 0x7fffffff
};
enum OpenCLDebugInfo100Instructions {
OpenCLDebugInfo100DebugInfoNone = 0,
OpenCLDebugInfo100DebugCompilationUnit = 1,
OpenCLDebugInfo100DebugTypeBasic = 2,
OpenCLDebugInfo100DebugTypePointer = 3,
OpenCLDebugInfo100DebugTypeQualifier = 4,
OpenCLDebugInfo100DebugTypeArray = 5,
OpenCLDebugInfo100DebugTypeVector = 6,
OpenCLDebugInfo100DebugTypedef = 7,
OpenCLDebugInfo100DebugTypeFunction = 8,
OpenCLDebugInfo100DebugTypeEnum = 9,
OpenCLDebugInfo100DebugTypeComposite = 10,
OpenCLDebugInfo100DebugTypeMember = 11,
OpenCLDebugInfo100DebugTypeInheritance = 12,
OpenCLDebugInfo100DebugTypePtrToMember = 13,
OpenCLDebugInfo100DebugTypeTemplate = 14,
OpenCLDebugInfo100DebugTypeTemplateParameter = 15,
OpenCLDebugInfo100DebugTypeTemplateTemplateParameter = 16,
OpenCLDebugInfo100DebugTypeTemplateParameterPack = 17,
OpenCLDebugInfo100DebugGlobalVariable = 18,
OpenCLDebugInfo100DebugFunctionDeclaration = 19,
OpenCLDebugInfo100DebugFunction = 20,
OpenCLDebugInfo100DebugLexicalBlock = 21,
OpenCLDebugInfo100DebugLexicalBlockDiscriminator = 22,
OpenCLDebugInfo100DebugScope = 23,
OpenCLDebugInfo100DebugNoScope = 24,
OpenCLDebugInfo100DebugInlinedAt = 25,
OpenCLDebugInfo100DebugLocalVariable = 26,
OpenCLDebugInfo100DebugInlinedVariable = 27,
OpenCLDebugInfo100DebugDeclare = 28,
OpenCLDebugInfo100DebugValue = 29,
OpenCLDebugInfo100DebugOperation = 30,
OpenCLDebugInfo100DebugExpression = 31,
OpenCLDebugInfo100DebugMacroDef = 32,
OpenCLDebugInfo100DebugMacroUndef = 33,
OpenCLDebugInfo100DebugImportedEntity = 34,
OpenCLDebugInfo100DebugSource = 35,
OpenCLDebugInfo100InstructionsMax = 0x7fffffff
};
enum OpenCLDebugInfo100DebugInfoFlags {
OpenCLDebugInfo100FlagIsProtected = 0x01,
OpenCLDebugInfo100FlagIsPrivate = 0x02,
OpenCLDebugInfo100FlagIsPublic = 0x03,
OpenCLDebugInfo100FlagIsLocal = 0x04,
OpenCLDebugInfo100FlagIsDefinition = 0x08,
OpenCLDebugInfo100FlagFwdDecl = 0x10,
OpenCLDebugInfo100FlagArtificial = 0x20,
OpenCLDebugInfo100FlagExplicit = 0x40,
OpenCLDebugInfo100FlagPrototyped = 0x80,
OpenCLDebugInfo100FlagObjectPointer = 0x100,
OpenCLDebugInfo100FlagStaticMember = 0x200,
OpenCLDebugInfo100FlagIndirectVariable = 0x400,
OpenCLDebugInfo100FlagLValueReference = 0x800,
OpenCLDebugInfo100FlagRValueReference = 0x1000,
OpenCLDebugInfo100FlagIsOptimized = 0x2000,
OpenCLDebugInfo100FlagIsEnumClass = 0x4000,
OpenCLDebugInfo100FlagTypePassByValue = 0x8000,
OpenCLDebugInfo100FlagTypePassByReference = 0x10000,
OpenCLDebugInfo100DebugInfoFlagsMax = 0x7fffffff
};
enum OpenCLDebugInfo100DebugBaseTypeAttributeEncoding {
OpenCLDebugInfo100Unspecified = 0,
OpenCLDebugInfo100Address = 1,
OpenCLDebugInfo100Boolean = 2,
OpenCLDebugInfo100Float = 3,
OpenCLDebugInfo100Signed = 4,
OpenCLDebugInfo100SignedChar = 5,
OpenCLDebugInfo100Unsigned = 6,
OpenCLDebugInfo100UnsignedChar = 7,
OpenCLDebugInfo100DebugBaseTypeAttributeEncodingMax = 0x7fffffff
};
enum OpenCLDebugInfo100DebugCompositeType {
OpenCLDebugInfo100Class = 0,
OpenCLDebugInfo100Structure = 1,
OpenCLDebugInfo100Union = 2,
OpenCLDebugInfo100DebugCompositeTypeMax = 0x7fffffff
};
enum OpenCLDebugInfo100DebugTypeQualifier {
OpenCLDebugInfo100ConstType = 0,
OpenCLDebugInfo100VolatileType = 1,
OpenCLDebugInfo100RestrictType = 2,
OpenCLDebugInfo100AtomicType = 3,
OpenCLDebugInfo100DebugTypeQualifierMax = 0x7fffffff
};
enum OpenCLDebugInfo100DebugOperation {
OpenCLDebugInfo100Deref = 0,
OpenCLDebugInfo100Plus = 1,
OpenCLDebugInfo100Minus = 2,
OpenCLDebugInfo100PlusUconst = 3,
OpenCLDebugInfo100BitPiece = 4,
OpenCLDebugInfo100Swap = 5,
OpenCLDebugInfo100Xderef = 6,
OpenCLDebugInfo100StackValue = 7,
OpenCLDebugInfo100Constu = 8,
OpenCLDebugInfo100Fragment = 9,
OpenCLDebugInfo100DebugOperationMax = 0x7fffffff
};
enum OpenCLDebugInfo100DebugImportedEntity {
OpenCLDebugInfo100ImportedModule = 0,
OpenCLDebugInfo100ImportedDeclaration = 1,
OpenCLDebugInfo100DebugImportedEntityMax = 0x7fffffff
};
#ifdef __cplusplus
}
#endif
#endif // SPIRV_UNIFIED1_OpenCLDebugInfo100_H_
{
"revision" : 1,
"instructions" : [
{
"opname" : "DebugPrintf",
"opcode" : 1,
"operands" : [
{ "kind" : "IdRef", "name" : "'Format'" },
{ "kind" : "IdRef", "quantifier" : "*" }
]
}
]
}
{
"revision" : 2,
"instructions" : [
{
"opname" : "CubeFaceIndexAMD",
"opcode" : 1,
"operands" : [
{ "kind" : "IdRef", "name" : "'P'" }
],
"extensions" : [ "SPV_AMD_gcn_shader" ]
},
{
"opname" : "CubeFaceCoordAMD",
"opcode" : 2,
"operands" : [
{ "kind" : "IdRef", "name" : "'P'" }
],
"extensions" : [ "SPV_AMD_gcn_shader" ]
},
{
"opname" : "TimeAMD",
"opcode" : 3,
"extensions" : [ "SPV_AMD_gcn_shader" ]
}
]
}
{
"revision" : 5,
"instructions" : [
{
"opname" : "SwizzleInvocationsAMD",
"opcode" : 1,
"operands" : [
{ "kind" : "IdRef", "name" : "'data'" },
{ "kind" : "IdRef", "name" : "'offset'" }
],
"extensions" : [ "SPV_AMD_shader_ballot" ]
},
{
"opname" : "SwizzleInvocationsMaskedAMD",
"opcode" : 2,
"operands" : [
{ "kind" : "IdRef", "name" : "'data'" },
{ "kind" : "IdRef", "name" : "'mask'" }
],
"extensions" : [ "SPV_AMD_shader_ballot" ]
},
{
"opname" : "WriteInvocationAMD",
"opcode" : 3,
"operands" : [
{ "kind" : "IdRef", "name" : "'inputValue'" },
{ "kind" : "IdRef", "name" : "'writeValue'" },
{ "kind" : "IdRef", "name" : "'invocationIndex'" }
],
"extensions" : [ "SPV_AMD_shader_ballot" ]
},
{
"opname" : "MbcntAMD",
"opcode" : 4,
"operands" : [
{ "kind" : "IdRef", "name" : "'mask'" }
],
"extensions" : [ "SPV_AMD_shader_ballot" ]
}
]
}
{
"revision" : 4,
"instructions" : [
{
"opname" : "InterpolateAtVertexAMD",
"opcode" : 1,
"operands" : [
{ "kind" : "IdRef", "name" : "'interpolant'" },
{ "kind" : "IdRef", "name" : "'vertexIdx'" }
],
"extensions" : [ "SPV_AMD_shader_explicit_vertex_parameter" ]
}
]
}
{
"revision" : 4,
"instructions" : [
{
"opname" : "FMin3AMD",
"opcode" : 1,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "UMin3AMD",
"opcode" : 2,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "SMin3AMD",
"opcode" : 3,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "FMax3AMD",
"opcode" : 4,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "UMax3AMD",
"opcode" : 5,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "SMax3AMD",
"opcode" : 6,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "FMid3AMD",
"opcode" : 7,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "UMid3AMD",
"opcode" : 8,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
},
{
"opname" : "SMid3AMD",
"opcode" : 9,
"operands" : [
{ "kind" : "IdRef", "name" : "'x'" },
{ "kind" : "IdRef", "name" : "'y'" },
{ "kind" : "IdRef", "name" : "'z'" }
],
"extensions" : [ "SPV_AMD_shader_trinary_minmax" ]
}
]
}
// Copyright (c) 2014-2019 The Khronos Group Inc. // Copyright (c) 2014-2020 The Khronos Group Inc.
// //
// Permission is hereby granted, free of charge, to any person obtaining a copy // Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and/or associated documentation files (the "Materials"), // of this software and/or associated documentation files (the "Materials"),
...@@ -74,11 +74,17 @@ namespace Spv ...@@ -74,11 +74,17 @@ namespace Spv
Kernel = 6, Kernel = 6,
TaskNV = 5267, TaskNV = 5267,
MeshNV = 5268, MeshNV = 5268,
RayGenerationKHR = 5313,
RayGenerationNV = 5313, RayGenerationNV = 5313,
IntersectionKHR = 5314,
IntersectionNV = 5314, IntersectionNV = 5314,
AnyHitKHR = 5315,
AnyHitNV = 5315, AnyHitNV = 5315,
ClosestHitKHR = 5316,
ClosestHitNV = 5316, ClosestHitNV = 5316,
MissKHR = 5317,
MissNV = 5317, MissNV = 5317,
CallableKHR = 5318,
CallableNV = 5318, CallableNV = 5318,
} }
...@@ -175,11 +181,17 @@ namespace Spv ...@@ -175,11 +181,17 @@ namespace Spv
AtomicCounter = 10, AtomicCounter = 10,
Image = 11, Image = 11,
StorageBuffer = 12, StorageBuffer = 12,
CallableDataKHR = 5328,
CallableDataNV = 5328, CallableDataNV = 5328,
IncomingCallableDataKHR = 5329,
IncomingCallableDataNV = 5329, IncomingCallableDataNV = 5329,
RayPayloadKHR = 5338,
RayPayloadNV = 5338, RayPayloadNV = 5338,
HitAttributeKHR = 5339,
HitAttributeNV = 5339, HitAttributeNV = 5339,
IncomingRayPayloadKHR = 5342,
IncomingRayPayloadNV = 5342, IncomingRayPayloadNV = 5342,
ShaderRecordBufferKHR = 5343,
ShaderRecordBufferNV = 5343, ShaderRecordBufferNV = 5343,
PhysicalStorageBuffer = 5349, PhysicalStorageBuffer = 5349,
PhysicalStorageBufferEXT = 5349, PhysicalStorageBufferEXT = 5349,
...@@ -556,20 +568,35 @@ namespace Spv ...@@ -556,20 +568,35 @@ namespace Spv
FragmentSizeNV = 5292, FragmentSizeNV = 5292,
FragInvocationCountEXT = 5293, FragInvocationCountEXT = 5293,
InvocationsPerPixelNV = 5293, InvocationsPerPixelNV = 5293,
LaunchIdKHR = 5319,
LaunchIdNV = 5319, LaunchIdNV = 5319,
LaunchSizeKHR = 5320,
LaunchSizeNV = 5320, LaunchSizeNV = 5320,
WorldRayOriginKHR = 5321,
WorldRayOriginNV = 5321, WorldRayOriginNV = 5321,
WorldRayDirectionKHR = 5322,
WorldRayDirectionNV = 5322, WorldRayDirectionNV = 5322,
ObjectRayOriginKHR = 5323,
ObjectRayOriginNV = 5323, ObjectRayOriginNV = 5323,
ObjectRayDirectionKHR = 5324,
ObjectRayDirectionNV = 5324, ObjectRayDirectionNV = 5324,
RayTminKHR = 5325,
RayTminNV = 5325, RayTminNV = 5325,
RayTmaxKHR = 5326,
RayTmaxNV = 5326, RayTmaxNV = 5326,
InstanceCustomIndexKHR = 5327,
InstanceCustomIndexNV = 5327, InstanceCustomIndexNV = 5327,
ObjectToWorldKHR = 5330,
ObjectToWorldNV = 5330, ObjectToWorldNV = 5330,
WorldToObjectKHR = 5331,
WorldToObjectNV = 5331, WorldToObjectNV = 5331,
HitTKHR = 5332,
HitTNV = 5332, HitTNV = 5332,
HitKindKHR = 5333,
HitKindNV = 5333, HitKindNV = 5333,
IncomingRayFlagsKHR = 5351,
IncomingRayFlagsNV = 5351, IncomingRayFlagsNV = 5351,
RayGeometryIndexKHR = 5352,
WarpsPerSMNV = 5374, WarpsPerSMNV = 5374,
SMCountNV = 5375, SMCountNV = 5375,
WarpIDNV = 5376, WarpIDNV = 5376,
...@@ -712,6 +739,7 @@ namespace Spv ...@@ -712,6 +739,7 @@ namespace Spv
Invocation = 4, Invocation = 4,
QueueFamily = 5, QueueFamily = 5,
QueueFamilyKHR = 5, QueueFamilyKHR = 5,
ShaderCallKHR = 6,
} }
public enum GroupOperation public enum GroupOperation
...@@ -837,6 +865,8 @@ namespace Spv ...@@ -837,6 +865,8 @@ namespace Spv
SignedZeroInfNanPreserve = 4466, SignedZeroInfNanPreserve = 4466,
RoundingModeRTE = 4467, RoundingModeRTE = 4467,
RoundingModeRTZ = 4468, RoundingModeRTZ = 4468,
RayQueryProvisionalKHR = 4471,
RayTraversalPrimitiveCullingProvisionalKHR = 4478,
Float16ImageAMD = 5008, Float16ImageAMD = 5008,
ImageGatherBiasLodAMD = 5009, ImageGatherBiasLodAMD = 5009,
FragmentMaskAMD = 5010, FragmentMaskAMD = 5010,
...@@ -890,6 +920,7 @@ namespace Spv ...@@ -890,6 +920,7 @@ namespace Spv
PhysicalStorageBufferAddresses = 5347, PhysicalStorageBufferAddresses = 5347,
PhysicalStorageBufferAddressesEXT = 5347, PhysicalStorageBufferAddressesEXT = 5347,
ComputeDerivativeGroupLinearNV = 5350, ComputeDerivativeGroupLinearNV = 5350,
RayTracingProvisionalKHR = 5353,
CooperativeMatrixNV = 5357, CooperativeMatrixNV = 5357,
FragmentShaderSampleInterlockEXT = 5363, FragmentShaderSampleInterlockEXT = 5363,
FragmentShaderShadingRateInterlockEXT = 5372, FragmentShaderShadingRateInterlockEXT = 5372,
...@@ -906,6 +937,54 @@ namespace Spv ...@@ -906,6 +937,54 @@ namespace Spv
SubgroupAvcMotionEstimationChromaINTEL = 5698, SubgroupAvcMotionEstimationChromaINTEL = 5698,
} }
public enum RayFlagsShift
{
OpaqueKHR = 0,
NoOpaqueKHR = 1,
TerminateOnFirstHitKHR = 2,
SkipClosestHitShaderKHR = 3,
CullBackFacingTrianglesKHR = 4,
CullFrontFacingTrianglesKHR = 5,
CullOpaqueKHR = 6,
CullNoOpaqueKHR = 7,
SkipTrianglesKHR = 8,
SkipAABBsKHR = 9,
}
public enum RayFlagsMask
{
MaskNone = 0,
OpaqueKHR = 0x00000001,
NoOpaqueKHR = 0x00000002,
TerminateOnFirstHitKHR = 0x00000004,
SkipClosestHitShaderKHR = 0x00000008,
CullBackFacingTrianglesKHR = 0x00000010,
CullFrontFacingTrianglesKHR = 0x00000020,
CullOpaqueKHR = 0x00000040,
CullNoOpaqueKHR = 0x00000080,
SkipTrianglesKHR = 0x00000100,
SkipAABBsKHR = 0x00000200,
}
public enum RayQueryIntersection
{
RayQueryCandidateIntersectionKHR = 0,
RayQueryCommittedIntersectionKHR = 1,
}
public enum RayQueryCommittedIntersectionType
{
RayQueryCommittedIntersectionNoneKHR = 0,
RayQueryCommittedIntersectionTriangleKHR = 1,
RayQueryCommittedIntersectionGeneratedKHR = 2,
}
public enum RayQueryCandidateIntersectionType
{
RayQueryCandidateIntersectionTriangleKHR = 0,
RayQueryCandidateIntersectionAABBKHR = 1,
}
public enum Op public enum Op
{ {
OpNop = 0, OpNop = 0,
...@@ -1258,6 +1337,13 @@ namespace Spv ...@@ -1258,6 +1337,13 @@ namespace Spv
OpSubgroupAnyKHR = 4429, OpSubgroupAnyKHR = 4429,
OpSubgroupAllEqualKHR = 4430, OpSubgroupAllEqualKHR = 4430,
OpSubgroupReadInvocationKHR = 4432, OpSubgroupReadInvocationKHR = 4432,
OpTypeRayQueryProvisionalKHR = 4472,
OpRayQueryInitializeKHR = 4473,
OpRayQueryTerminateKHR = 4474,
OpRayQueryGenerateIntersectionKHR = 4475,
OpRayQueryConfirmIntersectionKHR = 4476,
OpRayQueryProceedKHR = 4477,
OpRayQueryGetIntersectionTypeKHR = 4479,
OpGroupIAddNonUniformAMD = 5000, OpGroupIAddNonUniformAMD = 5000,
OpGroupFAddNonUniformAMD = 5001, OpGroupFAddNonUniformAMD = 5001,
OpGroupFMinNonUniformAMD = 5002, OpGroupFMinNonUniformAMD = 5002,
...@@ -1272,11 +1358,17 @@ namespace Spv ...@@ -1272,11 +1358,17 @@ namespace Spv
OpImageSampleFootprintNV = 5283, OpImageSampleFootprintNV = 5283,
OpGroupNonUniformPartitionNV = 5296, OpGroupNonUniformPartitionNV = 5296,
OpWritePackedPrimitiveIndices4x8NV = 5299, OpWritePackedPrimitiveIndices4x8NV = 5299,
OpReportIntersectionKHR = 5334,
OpReportIntersectionNV = 5334, OpReportIntersectionNV = 5334,
OpIgnoreIntersectionKHR = 5335,
OpIgnoreIntersectionNV = 5335, OpIgnoreIntersectionNV = 5335,
OpTerminateRayKHR = 5336,
OpTerminateRayNV = 5336, OpTerminateRayNV = 5336,
OpTraceNV = 5337, OpTraceNV = 5337,
OpTraceRayKHR = 5337,
OpTypeAccelerationStructureKHR = 5341,
OpTypeAccelerationStructureNV = 5341, OpTypeAccelerationStructureNV = 5341,
OpExecuteCallableKHR = 5344,
OpExecuteCallableNV = 5344, OpExecuteCallableNV = 5344,
OpTypeCooperativeMatrixNV = 5358, OpTypeCooperativeMatrixNV = 5358,
OpCooperativeMatrixLoadNV = 5359, OpCooperativeMatrixLoadNV = 5359,
...@@ -1433,6 +1525,23 @@ namespace Spv ...@@ -1433,6 +1525,23 @@ namespace Spv
OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL = 5814, OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL = 5814,
OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL = 5815, OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL = 5815,
OpSubgroupAvcSicGetInterRawSadsINTEL = 5816, OpSubgroupAvcSicGetInterRawSadsINTEL = 5816,
OpRayQueryGetRayTMinKHR = 6016,
OpRayQueryGetRayFlagsKHR = 6017,
OpRayQueryGetIntersectionTKHR = 6018,
OpRayQueryGetIntersectionInstanceCustomIndexKHR = 6019,
OpRayQueryGetIntersectionInstanceIdKHR = 6020,
OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR = 6021,
OpRayQueryGetIntersectionGeometryIndexKHR = 6022,
OpRayQueryGetIntersectionPrimitiveIndexKHR = 6023,
OpRayQueryGetIntersectionBarycentricsKHR = 6024,
OpRayQueryGetIntersectionFrontFaceKHR = 6025,
OpRayQueryGetIntersectionCandidateAABBOpaqueKHR = 6026,
OpRayQueryGetIntersectionObjectRayDirectionKHR = 6027,
OpRayQueryGetIntersectionObjectRayOriginKHR = 6028,
OpRayQueryGetWorldRayDirectionKHR = 6029,
OpRayQueryGetWorldRayOriginKHR = 6030,
OpRayQueryGetIntersectionObjectToWorldKHR = 6031,
OpRayQueryGetIntersectionWorldToObjectKHR = 6032,
} }
} }
} }
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
"Comment": "Comment":
[ [
[ [
"Copyright (c) 2014-2019 The Khronos Group Inc.", "Copyright (c) 2014-2020 The Khronos Group Inc.",
"", "",
"Permission is hereby granted, free of charge, to any person obtaining a copy", "Permission is hereby granted, free of charge, to any person obtaining a copy",
"of this software and/or associated documentation files (the \"Materials\"),", "of this software and/or associated documentation files (the \"Materials\"),",
...@@ -88,11 +88,17 @@ ...@@ -88,11 +88,17 @@
"Kernel": 6, "Kernel": 6,
"TaskNV": 5267, "TaskNV": 5267,
"MeshNV": 5268, "MeshNV": 5268,
"RayGenerationKHR": 5313,
"RayGenerationNV": 5313, "RayGenerationNV": 5313,
"IntersectionKHR": 5314,
"IntersectionNV": 5314, "IntersectionNV": 5314,
"AnyHitKHR": 5315,
"AnyHitNV": 5315, "AnyHitNV": 5315,
"ClosestHitKHR": 5316,
"ClosestHitNV": 5316, "ClosestHitNV": 5316,
"MissKHR": 5317,
"MissNV": 5317, "MissNV": 5317,
"CallableKHR": 5318,
"CallableNV": 5318 "CallableNV": 5318
} }
}, },
...@@ -201,11 +207,17 @@ ...@@ -201,11 +207,17 @@
"AtomicCounter": 10, "AtomicCounter": 10,
"Image": 11, "Image": 11,
"StorageBuffer": 12, "StorageBuffer": 12,
"CallableDataKHR": 5328,
"CallableDataNV": 5328, "CallableDataNV": 5328,
"IncomingCallableDataKHR": 5329,
"IncomingCallableDataNV": 5329, "IncomingCallableDataNV": 5329,
"RayPayloadKHR": 5338,
"RayPayloadNV": 5338, "RayPayloadNV": 5338,
"HitAttributeKHR": 5339,
"HitAttributeNV": 5339, "HitAttributeNV": 5339,
"IncomingRayPayloadKHR": 5342,
"IncomingRayPayloadNV": 5342, "IncomingRayPayloadNV": 5342,
"ShaderRecordBufferKHR": 5343,
"ShaderRecordBufferNV": 5343, "ShaderRecordBufferNV": 5343,
"PhysicalStorageBuffer": 5349, "PhysicalStorageBuffer": 5349,
"PhysicalStorageBufferEXT": 5349 "PhysicalStorageBufferEXT": 5349
...@@ -591,20 +603,35 @@ ...@@ -591,20 +603,35 @@
"FragmentSizeNV": 5292, "FragmentSizeNV": 5292,
"FragInvocationCountEXT": 5293, "FragInvocationCountEXT": 5293,
"InvocationsPerPixelNV": 5293, "InvocationsPerPixelNV": 5293,
"LaunchIdKHR": 5319,
"LaunchIdNV": 5319, "LaunchIdNV": 5319,
"LaunchSizeKHR": 5320,
"LaunchSizeNV": 5320, "LaunchSizeNV": 5320,
"WorldRayOriginKHR": 5321,
"WorldRayOriginNV": 5321, "WorldRayOriginNV": 5321,
"WorldRayDirectionKHR": 5322,
"WorldRayDirectionNV": 5322, "WorldRayDirectionNV": 5322,
"ObjectRayOriginKHR": 5323,
"ObjectRayOriginNV": 5323, "ObjectRayOriginNV": 5323,
"ObjectRayDirectionKHR": 5324,
"ObjectRayDirectionNV": 5324, "ObjectRayDirectionNV": 5324,
"RayTminKHR": 5325,
"RayTminNV": 5325, "RayTminNV": 5325,
"RayTmaxKHR": 5326,
"RayTmaxNV": 5326, "RayTmaxNV": 5326,
"InstanceCustomIndexKHR": 5327,
"InstanceCustomIndexNV": 5327, "InstanceCustomIndexNV": 5327,
"ObjectToWorldKHR": 5330,
"ObjectToWorldNV": 5330, "ObjectToWorldNV": 5330,
"WorldToObjectKHR": 5331,
"WorldToObjectNV": 5331, "WorldToObjectNV": 5331,
"HitTKHR": 5332,
"HitTNV": 5332, "HitTNV": 5332,
"HitKindKHR": 5333,
"HitKindNV": 5333, "HitKindNV": 5333,
"IncomingRayFlagsKHR": 5351,
"IncomingRayFlagsNV": 5351, "IncomingRayFlagsNV": 5351,
"RayGeometryIndexKHR": 5352,
"WarpsPerSMNV": 5374, "WarpsPerSMNV": 5374,
"SMCountNV": 5375, "SMCountNV": 5375,
"WarpIDNV": 5376, "WarpIDNV": 5376,
...@@ -698,7 +725,8 @@ ...@@ -698,7 +725,8 @@
"Subgroup": 3, "Subgroup": 3,
"Invocation": 4, "Invocation": 4,
"QueueFamily": 5, "QueueFamily": 5,
"QueueFamilyKHR": 5 "QueueFamilyKHR": 5,
"ShaderCallKHR": 6
} }
}, },
{ {
...@@ -830,6 +858,8 @@ ...@@ -830,6 +858,8 @@
"SignedZeroInfNanPreserve": 4466, "SignedZeroInfNanPreserve": 4466,
"RoundingModeRTE": 4467, "RoundingModeRTE": 4467,
"RoundingModeRTZ": 4468, "RoundingModeRTZ": 4468,
"RayQueryProvisionalKHR": 4471,
"RayTraversalPrimitiveCullingProvisionalKHR": 4478,
"Float16ImageAMD": 5008, "Float16ImageAMD": 5008,
"ImageGatherBiasLodAMD": 5009, "ImageGatherBiasLodAMD": 5009,
"FragmentMaskAMD": 5010, "FragmentMaskAMD": 5010,
...@@ -883,6 +913,7 @@ ...@@ -883,6 +913,7 @@
"PhysicalStorageBufferAddresses": 5347, "PhysicalStorageBufferAddresses": 5347,
"PhysicalStorageBufferAddressesEXT": 5347, "PhysicalStorageBufferAddressesEXT": 5347,
"ComputeDerivativeGroupLinearNV": 5350, "ComputeDerivativeGroupLinearNV": 5350,
"RayTracingProvisionalKHR": 5353,
"CooperativeMatrixNV": 5357, "CooperativeMatrixNV": 5357,
"FragmentShaderSampleInterlockEXT": 5363, "FragmentShaderSampleInterlockEXT": 5363,
"FragmentShaderShadingRateInterlockEXT": 5372, "FragmentShaderShadingRateInterlockEXT": 5372,
...@@ -900,6 +931,51 @@ ...@@ -900,6 +931,51 @@
} }
}, },
{ {
"Name": "RayFlags",
"Type": "Bit",
"Values":
{
"OpaqueKHR": 0,
"NoOpaqueKHR": 1,
"TerminateOnFirstHitKHR": 2,
"SkipClosestHitShaderKHR": 3,
"CullBackFacingTrianglesKHR": 4,
"CullFrontFacingTrianglesKHR": 5,
"CullOpaqueKHR": 6,
"CullNoOpaqueKHR": 7,
"SkipTrianglesKHR": 8,
"SkipAABBsKHR": 9
}
},
{
"Name": "RayQueryIntersection",
"Type": "Value",
"Values":
{
"RayQueryCandidateIntersectionKHR": 0,
"RayQueryCommittedIntersectionKHR": 1
}
},
{
"Name": "RayQueryCommittedIntersectionType",
"Type": "Value",
"Values":
{
"RayQueryCommittedIntersectionNoneKHR": 0,
"RayQueryCommittedIntersectionTriangleKHR": 1,
"RayQueryCommittedIntersectionGeneratedKHR": 2
}
},
{
"Name": "RayQueryCandidateIntersectionType",
"Type": "Value",
"Values":
{
"RayQueryCandidateIntersectionTriangleKHR": 0,
"RayQueryCandidateIntersectionAABBKHR": 1
}
},
{
"Name": "Op", "Name": "Op",
"Type": "Value", "Type": "Value",
"Values": "Values":
...@@ -1254,6 +1330,13 @@ ...@@ -1254,6 +1330,13 @@
"OpSubgroupAnyKHR": 4429, "OpSubgroupAnyKHR": 4429,
"OpSubgroupAllEqualKHR": 4430, "OpSubgroupAllEqualKHR": 4430,
"OpSubgroupReadInvocationKHR": 4432, "OpSubgroupReadInvocationKHR": 4432,
"OpTypeRayQueryProvisionalKHR": 4472,
"OpRayQueryInitializeKHR": 4473,
"OpRayQueryTerminateKHR": 4474,
"OpRayQueryGenerateIntersectionKHR": 4475,
"OpRayQueryConfirmIntersectionKHR": 4476,
"OpRayQueryProceedKHR": 4477,
"OpRayQueryGetIntersectionTypeKHR": 4479,
"OpGroupIAddNonUniformAMD": 5000, "OpGroupIAddNonUniformAMD": 5000,
"OpGroupFAddNonUniformAMD": 5001, "OpGroupFAddNonUniformAMD": 5001,
"OpGroupFMinNonUniformAMD": 5002, "OpGroupFMinNonUniformAMD": 5002,
...@@ -1268,11 +1351,17 @@ ...@@ -1268,11 +1351,17 @@
"OpImageSampleFootprintNV": 5283, "OpImageSampleFootprintNV": 5283,
"OpGroupNonUniformPartitionNV": 5296, "OpGroupNonUniformPartitionNV": 5296,
"OpWritePackedPrimitiveIndices4x8NV": 5299, "OpWritePackedPrimitiveIndices4x8NV": 5299,
"OpReportIntersectionKHR": 5334,
"OpReportIntersectionNV": 5334, "OpReportIntersectionNV": 5334,
"OpIgnoreIntersectionKHR": 5335,
"OpIgnoreIntersectionNV": 5335, "OpIgnoreIntersectionNV": 5335,
"OpTerminateRayKHR": 5336,
"OpTerminateRayNV": 5336, "OpTerminateRayNV": 5336,
"OpTraceNV": 5337, "OpTraceNV": 5337,
"OpTraceRayKHR": 5337,
"OpTypeAccelerationStructureKHR": 5341,
"OpTypeAccelerationStructureNV": 5341, "OpTypeAccelerationStructureNV": 5341,
"OpExecuteCallableKHR": 5344,
"OpExecuteCallableNV": 5344, "OpExecuteCallableNV": 5344,
"OpTypeCooperativeMatrixNV": 5358, "OpTypeCooperativeMatrixNV": 5358,
"OpCooperativeMatrixLoadNV": 5359, "OpCooperativeMatrixLoadNV": 5359,
...@@ -1428,7 +1517,24 @@ ...@@ -1428,7 +1517,24 @@
"OpSubgroupAvcSicGetIpeChromaModeINTEL": 5813, "OpSubgroupAvcSicGetIpeChromaModeINTEL": 5813,
"OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL": 5814, "OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL": 5814,
"OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL": 5815, "OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL": 5815,
"OpSubgroupAvcSicGetInterRawSadsINTEL": 5816 "OpSubgroupAvcSicGetInterRawSadsINTEL": 5816,
"OpRayQueryGetRayTMinKHR": 6016,
"OpRayQueryGetRayFlagsKHR": 6017,
"OpRayQueryGetIntersectionTKHR": 6018,
"OpRayQueryGetIntersectionInstanceCustomIndexKHR": 6019,
"OpRayQueryGetIntersectionInstanceIdKHR": 6020,
"OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR": 6021,
"OpRayQueryGetIntersectionGeometryIndexKHR": 6022,
"OpRayQueryGetIntersectionPrimitiveIndexKHR": 6023,
"OpRayQueryGetIntersectionBarycentricsKHR": 6024,
"OpRayQueryGetIntersectionFrontFaceKHR": 6025,
"OpRayQueryGetIntersectionCandidateAABBOpaqueKHR": 6026,
"OpRayQueryGetIntersectionObjectRayDirectionKHR": 6027,
"OpRayQueryGetIntersectionObjectRayOriginKHR": 6028,
"OpRayQueryGetWorldRayDirectionKHR": 6029,
"OpRayQueryGetWorldRayOriginKHR": 6030,
"OpRayQueryGetIntersectionObjectToWorldKHR": 6031,
"OpRayQueryGetIntersectionWorldToObjectKHR": 6032
} }
} }
] ]
......
-- Copyright (c) 2014-2019 The Khronos Group Inc. -- Copyright (c) 2014-2020 The Khronos Group Inc.
-- --
-- Permission is hereby granted, free of charge, to any person obtaining a copy -- Permission is hereby granted, free of charge, to any person obtaining a copy
-- of this software and/or associated documentation files (the "Materials"), -- of this software and/or associated documentation files (the "Materials"),
...@@ -68,11 +68,17 @@ spv = { ...@@ -68,11 +68,17 @@ spv = {
Kernel = 6, Kernel = 6,
TaskNV = 5267, TaskNV = 5267,
MeshNV = 5268, MeshNV = 5268,
RayGenerationKHR = 5313,
RayGenerationNV = 5313, RayGenerationNV = 5313,
IntersectionKHR = 5314,
IntersectionNV = 5314, IntersectionNV = 5314,
AnyHitKHR = 5315,
AnyHitNV = 5315, AnyHitNV = 5315,
ClosestHitKHR = 5316,
ClosestHitNV = 5316, ClosestHitNV = 5316,
MissKHR = 5317,
MissNV = 5317, MissNV = 5317,
CallableKHR = 5318,
CallableNV = 5318, CallableNV = 5318,
}, },
...@@ -165,11 +171,17 @@ spv = { ...@@ -165,11 +171,17 @@ spv = {
AtomicCounter = 10, AtomicCounter = 10,
Image = 11, Image = 11,
StorageBuffer = 12, StorageBuffer = 12,
CallableDataKHR = 5328,
CallableDataNV = 5328, CallableDataNV = 5328,
IncomingCallableDataKHR = 5329,
IncomingCallableDataNV = 5329, IncomingCallableDataNV = 5329,
RayPayloadKHR = 5338,
RayPayloadNV = 5338, RayPayloadNV = 5338,
HitAttributeKHR = 5339,
HitAttributeNV = 5339, HitAttributeNV = 5339,
IncomingRayPayloadKHR = 5342,
IncomingRayPayloadNV = 5342, IncomingRayPayloadNV = 5342,
ShaderRecordBufferKHR = 5343,
ShaderRecordBufferNV = 5343, ShaderRecordBufferNV = 5343,
PhysicalStorageBuffer = 5349, PhysicalStorageBuffer = 5349,
PhysicalStorageBufferEXT = 5349, PhysicalStorageBufferEXT = 5349,
...@@ -530,20 +542,35 @@ spv = { ...@@ -530,20 +542,35 @@ spv = {
FragmentSizeNV = 5292, FragmentSizeNV = 5292,
FragInvocationCountEXT = 5293, FragInvocationCountEXT = 5293,
InvocationsPerPixelNV = 5293, InvocationsPerPixelNV = 5293,
LaunchIdKHR = 5319,
LaunchIdNV = 5319, LaunchIdNV = 5319,
LaunchSizeKHR = 5320,
LaunchSizeNV = 5320, LaunchSizeNV = 5320,
WorldRayOriginKHR = 5321,
WorldRayOriginNV = 5321, WorldRayOriginNV = 5321,
WorldRayDirectionKHR = 5322,
WorldRayDirectionNV = 5322, WorldRayDirectionNV = 5322,
ObjectRayOriginKHR = 5323,
ObjectRayOriginNV = 5323, ObjectRayOriginNV = 5323,
ObjectRayDirectionKHR = 5324,
ObjectRayDirectionNV = 5324, ObjectRayDirectionNV = 5324,
RayTminKHR = 5325,
RayTminNV = 5325, RayTminNV = 5325,
RayTmaxKHR = 5326,
RayTmaxNV = 5326, RayTmaxNV = 5326,
InstanceCustomIndexKHR = 5327,
InstanceCustomIndexNV = 5327, InstanceCustomIndexNV = 5327,
ObjectToWorldKHR = 5330,
ObjectToWorldNV = 5330, ObjectToWorldNV = 5330,
WorldToObjectKHR = 5331,
WorldToObjectNV = 5331, WorldToObjectNV = 5331,
HitTKHR = 5332,
HitTNV = 5332, HitTNV = 5332,
HitKindKHR = 5333,
HitKindNV = 5333, HitKindNV = 5333,
IncomingRayFlagsKHR = 5351,
IncomingRayFlagsNV = 5351, IncomingRayFlagsNV = 5351,
RayGeometryIndexKHR = 5352,
WarpsPerSMNV = 5374, WarpsPerSMNV = 5374,
SMCountNV = 5375, SMCountNV = 5375,
WarpIDNV = 5376, WarpIDNV = 5376,
...@@ -675,6 +702,7 @@ spv = { ...@@ -675,6 +702,7 @@ spv = {
Invocation = 4, Invocation = 4,
QueueFamily = 5, QueueFamily = 5,
QueueFamilyKHR = 5, QueueFamilyKHR = 5,
ShaderCallKHR = 6,
}, },
GroupOperation = { GroupOperation = {
...@@ -795,6 +823,8 @@ spv = { ...@@ -795,6 +823,8 @@ spv = {
SignedZeroInfNanPreserve = 4466, SignedZeroInfNanPreserve = 4466,
RoundingModeRTE = 4467, RoundingModeRTE = 4467,
RoundingModeRTZ = 4468, RoundingModeRTZ = 4468,
RayQueryProvisionalKHR = 4471,
RayTraversalPrimitiveCullingProvisionalKHR = 4478,
Float16ImageAMD = 5008, Float16ImageAMD = 5008,
ImageGatherBiasLodAMD = 5009, ImageGatherBiasLodAMD = 5009,
FragmentMaskAMD = 5010, FragmentMaskAMD = 5010,
...@@ -848,6 +878,7 @@ spv = { ...@@ -848,6 +878,7 @@ spv = {
PhysicalStorageBufferAddresses = 5347, PhysicalStorageBufferAddresses = 5347,
PhysicalStorageBufferAddressesEXT = 5347, PhysicalStorageBufferAddressesEXT = 5347,
ComputeDerivativeGroupLinearNV = 5350, ComputeDerivativeGroupLinearNV = 5350,
RayTracingProvisionalKHR = 5353,
CooperativeMatrixNV = 5357, CooperativeMatrixNV = 5357,
FragmentShaderSampleInterlockEXT = 5363, FragmentShaderSampleInterlockEXT = 5363,
FragmentShaderShadingRateInterlockEXT = 5372, FragmentShaderShadingRateInterlockEXT = 5372,
...@@ -864,6 +895,49 @@ spv = { ...@@ -864,6 +895,49 @@ spv = {
SubgroupAvcMotionEstimationChromaINTEL = 5698, SubgroupAvcMotionEstimationChromaINTEL = 5698,
}, },
RayFlagsShift = {
OpaqueKHR = 0,
NoOpaqueKHR = 1,
TerminateOnFirstHitKHR = 2,
SkipClosestHitShaderKHR = 3,
CullBackFacingTrianglesKHR = 4,
CullFrontFacingTrianglesKHR = 5,
CullOpaqueKHR = 6,
CullNoOpaqueKHR = 7,
SkipTrianglesKHR = 8,
SkipAABBsKHR = 9,
},
RayFlagsMask = {
MaskNone = 0,
OpaqueKHR = 0x00000001,
NoOpaqueKHR = 0x00000002,
TerminateOnFirstHitKHR = 0x00000004,
SkipClosestHitShaderKHR = 0x00000008,
CullBackFacingTrianglesKHR = 0x00000010,
CullFrontFacingTrianglesKHR = 0x00000020,
CullOpaqueKHR = 0x00000040,
CullNoOpaqueKHR = 0x00000080,
SkipTrianglesKHR = 0x00000100,
SkipAABBsKHR = 0x00000200,
},
RayQueryIntersection = {
RayQueryCandidateIntersectionKHR = 0,
RayQueryCommittedIntersectionKHR = 1,
},
RayQueryCommittedIntersectionType = {
RayQueryCommittedIntersectionNoneKHR = 0,
RayQueryCommittedIntersectionTriangleKHR = 1,
RayQueryCommittedIntersectionGeneratedKHR = 2,
},
RayQueryCandidateIntersectionType = {
RayQueryCandidateIntersectionTriangleKHR = 0,
RayQueryCandidateIntersectionAABBKHR = 1,
},
Op = { Op = {
OpNop = 0, OpNop = 0,
OpUndef = 1, OpUndef = 1,
...@@ -1215,6 +1289,13 @@ spv = { ...@@ -1215,6 +1289,13 @@ spv = {
OpSubgroupAnyKHR = 4429, OpSubgroupAnyKHR = 4429,
OpSubgroupAllEqualKHR = 4430, OpSubgroupAllEqualKHR = 4430,
OpSubgroupReadInvocationKHR = 4432, OpSubgroupReadInvocationKHR = 4432,
OpTypeRayQueryProvisionalKHR = 4472,
OpRayQueryInitializeKHR = 4473,
OpRayQueryTerminateKHR = 4474,
OpRayQueryGenerateIntersectionKHR = 4475,
OpRayQueryConfirmIntersectionKHR = 4476,
OpRayQueryProceedKHR = 4477,
OpRayQueryGetIntersectionTypeKHR = 4479,
OpGroupIAddNonUniformAMD = 5000, OpGroupIAddNonUniformAMD = 5000,
OpGroupFAddNonUniformAMD = 5001, OpGroupFAddNonUniformAMD = 5001,
OpGroupFMinNonUniformAMD = 5002, OpGroupFMinNonUniformAMD = 5002,
...@@ -1229,11 +1310,17 @@ spv = { ...@@ -1229,11 +1310,17 @@ spv = {
OpImageSampleFootprintNV = 5283, OpImageSampleFootprintNV = 5283,
OpGroupNonUniformPartitionNV = 5296, OpGroupNonUniformPartitionNV = 5296,
OpWritePackedPrimitiveIndices4x8NV = 5299, OpWritePackedPrimitiveIndices4x8NV = 5299,
OpReportIntersectionKHR = 5334,
OpReportIntersectionNV = 5334, OpReportIntersectionNV = 5334,
OpIgnoreIntersectionKHR = 5335,
OpIgnoreIntersectionNV = 5335, OpIgnoreIntersectionNV = 5335,
OpTerminateRayKHR = 5336,
OpTerminateRayNV = 5336, OpTerminateRayNV = 5336,
OpTraceNV = 5337, OpTraceNV = 5337,
OpTraceRayKHR = 5337,
OpTypeAccelerationStructureKHR = 5341,
OpTypeAccelerationStructureNV = 5341, OpTypeAccelerationStructureNV = 5341,
OpExecuteCallableKHR = 5344,
OpExecuteCallableNV = 5344, OpExecuteCallableNV = 5344,
OpTypeCooperativeMatrixNV = 5358, OpTypeCooperativeMatrixNV = 5358,
OpCooperativeMatrixLoadNV = 5359, OpCooperativeMatrixLoadNV = 5359,
...@@ -1390,6 +1477,23 @@ spv = { ...@@ -1390,6 +1477,23 @@ spv = {
OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL = 5814, OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL = 5814,
OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL = 5815, OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL = 5815,
OpSubgroupAvcSicGetInterRawSadsINTEL = 5816, OpSubgroupAvcSicGetInterRawSadsINTEL = 5816,
OpRayQueryGetRayTMinKHR = 6016,
OpRayQueryGetRayFlagsKHR = 6017,
OpRayQueryGetIntersectionTKHR = 6018,
OpRayQueryGetIntersectionInstanceCustomIndexKHR = 6019,
OpRayQueryGetIntersectionInstanceIdKHR = 6020,
OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR = 6021,
OpRayQueryGetIntersectionGeometryIndexKHR = 6022,
OpRayQueryGetIntersectionPrimitiveIndexKHR = 6023,
OpRayQueryGetIntersectionBarycentricsKHR = 6024,
OpRayQueryGetIntersectionFrontFaceKHR = 6025,
OpRayQueryGetIntersectionCandidateAABBOpaqueKHR = 6026,
OpRayQueryGetIntersectionObjectRayDirectionKHR = 6027,
OpRayQueryGetIntersectionObjectRayOriginKHR = 6028,
OpRayQueryGetWorldRayDirectionKHR = 6029,
OpRayQueryGetWorldRayOriginKHR = 6030,
OpRayQueryGetIntersectionObjectToWorldKHR = 6031,
OpRayQueryGetIntersectionWorldToObjectKHR = 6032,
}, },
} }
......
# Copyright (c) 2014-2019 The Khronos Group Inc. # Copyright (c) 2014-2020 The Khronos Group Inc.
# #
# Permission is hereby granted, free of charge, to any person obtaining a copy # Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and/or associated documentation files (the "Materials"), # of this software and/or associated documentation files (the "Materials"),
...@@ -68,11 +68,17 @@ spv = { ...@@ -68,11 +68,17 @@ spv = {
'Kernel' : 6, 'Kernel' : 6,
'TaskNV' : 5267, 'TaskNV' : 5267,
'MeshNV' : 5268, 'MeshNV' : 5268,
'RayGenerationKHR' : 5313,
'RayGenerationNV' : 5313, 'RayGenerationNV' : 5313,
'IntersectionKHR' : 5314,
'IntersectionNV' : 5314, 'IntersectionNV' : 5314,
'AnyHitKHR' : 5315,
'AnyHitNV' : 5315, 'AnyHitNV' : 5315,
'ClosestHitKHR' : 5316,
'ClosestHitNV' : 5316, 'ClosestHitNV' : 5316,
'MissKHR' : 5317,
'MissNV' : 5317, 'MissNV' : 5317,
'CallableKHR' : 5318,
'CallableNV' : 5318, 'CallableNV' : 5318,
}, },
...@@ -165,11 +171,17 @@ spv = { ...@@ -165,11 +171,17 @@ spv = {
'AtomicCounter' : 10, 'AtomicCounter' : 10,
'Image' : 11, 'Image' : 11,
'StorageBuffer' : 12, 'StorageBuffer' : 12,
'CallableDataKHR' : 5328,
'CallableDataNV' : 5328, 'CallableDataNV' : 5328,
'IncomingCallableDataKHR' : 5329,
'IncomingCallableDataNV' : 5329, 'IncomingCallableDataNV' : 5329,
'RayPayloadKHR' : 5338,
'RayPayloadNV' : 5338, 'RayPayloadNV' : 5338,
'HitAttributeKHR' : 5339,
'HitAttributeNV' : 5339, 'HitAttributeNV' : 5339,
'IncomingRayPayloadKHR' : 5342,
'IncomingRayPayloadNV' : 5342, 'IncomingRayPayloadNV' : 5342,
'ShaderRecordBufferKHR' : 5343,
'ShaderRecordBufferNV' : 5343, 'ShaderRecordBufferNV' : 5343,
'PhysicalStorageBuffer' : 5349, 'PhysicalStorageBuffer' : 5349,
'PhysicalStorageBufferEXT' : 5349, 'PhysicalStorageBufferEXT' : 5349,
...@@ -530,20 +542,35 @@ spv = { ...@@ -530,20 +542,35 @@ spv = {
'FragmentSizeNV' : 5292, 'FragmentSizeNV' : 5292,
'FragInvocationCountEXT' : 5293, 'FragInvocationCountEXT' : 5293,
'InvocationsPerPixelNV' : 5293, 'InvocationsPerPixelNV' : 5293,
'LaunchIdKHR' : 5319,
'LaunchIdNV' : 5319, 'LaunchIdNV' : 5319,
'LaunchSizeKHR' : 5320,
'LaunchSizeNV' : 5320, 'LaunchSizeNV' : 5320,
'WorldRayOriginKHR' : 5321,
'WorldRayOriginNV' : 5321, 'WorldRayOriginNV' : 5321,
'WorldRayDirectionKHR' : 5322,
'WorldRayDirectionNV' : 5322, 'WorldRayDirectionNV' : 5322,
'ObjectRayOriginKHR' : 5323,
'ObjectRayOriginNV' : 5323, 'ObjectRayOriginNV' : 5323,
'ObjectRayDirectionKHR' : 5324,
'ObjectRayDirectionNV' : 5324, 'ObjectRayDirectionNV' : 5324,
'RayTminKHR' : 5325,
'RayTminNV' : 5325, 'RayTminNV' : 5325,
'RayTmaxKHR' : 5326,
'RayTmaxNV' : 5326, 'RayTmaxNV' : 5326,
'InstanceCustomIndexKHR' : 5327,
'InstanceCustomIndexNV' : 5327, 'InstanceCustomIndexNV' : 5327,
'ObjectToWorldKHR' : 5330,
'ObjectToWorldNV' : 5330, 'ObjectToWorldNV' : 5330,
'WorldToObjectKHR' : 5331,
'WorldToObjectNV' : 5331, 'WorldToObjectNV' : 5331,
'HitTKHR' : 5332,
'HitTNV' : 5332, 'HitTNV' : 5332,
'HitKindKHR' : 5333,
'HitKindNV' : 5333, 'HitKindNV' : 5333,
'IncomingRayFlagsKHR' : 5351,
'IncomingRayFlagsNV' : 5351, 'IncomingRayFlagsNV' : 5351,
'RayGeometryIndexKHR' : 5352,
'WarpsPerSMNV' : 5374, 'WarpsPerSMNV' : 5374,
'SMCountNV' : 5375, 'SMCountNV' : 5375,
'WarpIDNV' : 5376, 'WarpIDNV' : 5376,
...@@ -675,6 +702,7 @@ spv = { ...@@ -675,6 +702,7 @@ spv = {
'Invocation' : 4, 'Invocation' : 4,
'QueueFamily' : 5, 'QueueFamily' : 5,
'QueueFamilyKHR' : 5, 'QueueFamilyKHR' : 5,
'ShaderCallKHR' : 6,
}, },
'GroupOperation' : { 'GroupOperation' : {
...@@ -795,6 +823,8 @@ spv = { ...@@ -795,6 +823,8 @@ spv = {
'SignedZeroInfNanPreserve' : 4466, 'SignedZeroInfNanPreserve' : 4466,
'RoundingModeRTE' : 4467, 'RoundingModeRTE' : 4467,
'RoundingModeRTZ' : 4468, 'RoundingModeRTZ' : 4468,
'RayQueryProvisionalKHR' : 4471,
'RayTraversalPrimitiveCullingProvisionalKHR' : 4478,
'Float16ImageAMD' : 5008, 'Float16ImageAMD' : 5008,
'ImageGatherBiasLodAMD' : 5009, 'ImageGatherBiasLodAMD' : 5009,
'FragmentMaskAMD' : 5010, 'FragmentMaskAMD' : 5010,
...@@ -848,6 +878,7 @@ spv = { ...@@ -848,6 +878,7 @@ spv = {
'PhysicalStorageBufferAddresses' : 5347, 'PhysicalStorageBufferAddresses' : 5347,
'PhysicalStorageBufferAddressesEXT' : 5347, 'PhysicalStorageBufferAddressesEXT' : 5347,
'ComputeDerivativeGroupLinearNV' : 5350, 'ComputeDerivativeGroupLinearNV' : 5350,
'RayTracingProvisionalKHR' : 5353,
'CooperativeMatrixNV' : 5357, 'CooperativeMatrixNV' : 5357,
'FragmentShaderSampleInterlockEXT' : 5363, 'FragmentShaderSampleInterlockEXT' : 5363,
'FragmentShaderShadingRateInterlockEXT' : 5372, 'FragmentShaderShadingRateInterlockEXT' : 5372,
...@@ -864,6 +895,49 @@ spv = { ...@@ -864,6 +895,49 @@ spv = {
'SubgroupAvcMotionEstimationChromaINTEL' : 5698, 'SubgroupAvcMotionEstimationChromaINTEL' : 5698,
}, },
'RayFlagsShift' : {
'OpaqueKHR' : 0,
'NoOpaqueKHR' : 1,
'TerminateOnFirstHitKHR' : 2,
'SkipClosestHitShaderKHR' : 3,
'CullBackFacingTrianglesKHR' : 4,
'CullFrontFacingTrianglesKHR' : 5,
'CullOpaqueKHR' : 6,
'CullNoOpaqueKHR' : 7,
'SkipTrianglesKHR' : 8,
'SkipAABBsKHR' : 9,
},
'RayFlagsMask' : {
'MaskNone' : 0,
'OpaqueKHR' : 0x00000001,
'NoOpaqueKHR' : 0x00000002,
'TerminateOnFirstHitKHR' : 0x00000004,
'SkipClosestHitShaderKHR' : 0x00000008,
'CullBackFacingTrianglesKHR' : 0x00000010,
'CullFrontFacingTrianglesKHR' : 0x00000020,
'CullOpaqueKHR' : 0x00000040,
'CullNoOpaqueKHR' : 0x00000080,
'SkipTrianglesKHR' : 0x00000100,
'SkipAABBsKHR' : 0x00000200,
},
'RayQueryIntersection' : {
'RayQueryCandidateIntersectionKHR' : 0,
'RayQueryCommittedIntersectionKHR' : 1,
},
'RayQueryCommittedIntersectionType' : {
'RayQueryCommittedIntersectionNoneKHR' : 0,
'RayQueryCommittedIntersectionTriangleKHR' : 1,
'RayQueryCommittedIntersectionGeneratedKHR' : 2,
},
'RayQueryCandidateIntersectionType' : {
'RayQueryCandidateIntersectionTriangleKHR' : 0,
'RayQueryCandidateIntersectionAABBKHR' : 1,
},
'Op' : { 'Op' : {
'OpNop' : 0, 'OpNop' : 0,
'OpUndef' : 1, 'OpUndef' : 1,
...@@ -1215,6 +1289,13 @@ spv = { ...@@ -1215,6 +1289,13 @@ spv = {
'OpSubgroupAnyKHR' : 4429, 'OpSubgroupAnyKHR' : 4429,
'OpSubgroupAllEqualKHR' : 4430, 'OpSubgroupAllEqualKHR' : 4430,
'OpSubgroupReadInvocationKHR' : 4432, 'OpSubgroupReadInvocationKHR' : 4432,
'OpTypeRayQueryProvisionalKHR' : 4472,
'OpRayQueryInitializeKHR' : 4473,
'OpRayQueryTerminateKHR' : 4474,
'OpRayQueryGenerateIntersectionKHR' : 4475,
'OpRayQueryConfirmIntersectionKHR' : 4476,
'OpRayQueryProceedKHR' : 4477,
'OpRayQueryGetIntersectionTypeKHR' : 4479,
'OpGroupIAddNonUniformAMD' : 5000, 'OpGroupIAddNonUniformAMD' : 5000,
'OpGroupFAddNonUniformAMD' : 5001, 'OpGroupFAddNonUniformAMD' : 5001,
'OpGroupFMinNonUniformAMD' : 5002, 'OpGroupFMinNonUniformAMD' : 5002,
...@@ -1229,11 +1310,17 @@ spv = { ...@@ -1229,11 +1310,17 @@ spv = {
'OpImageSampleFootprintNV' : 5283, 'OpImageSampleFootprintNV' : 5283,
'OpGroupNonUniformPartitionNV' : 5296, 'OpGroupNonUniformPartitionNV' : 5296,
'OpWritePackedPrimitiveIndices4x8NV' : 5299, 'OpWritePackedPrimitiveIndices4x8NV' : 5299,
'OpReportIntersectionKHR' : 5334,
'OpReportIntersectionNV' : 5334, 'OpReportIntersectionNV' : 5334,
'OpIgnoreIntersectionKHR' : 5335,
'OpIgnoreIntersectionNV' : 5335, 'OpIgnoreIntersectionNV' : 5335,
'OpTerminateRayKHR' : 5336,
'OpTerminateRayNV' : 5336, 'OpTerminateRayNV' : 5336,
'OpTraceNV' : 5337, 'OpTraceNV' : 5337,
'OpTraceRayKHR' : 5337,
'OpTypeAccelerationStructureKHR' : 5341,
'OpTypeAccelerationStructureNV' : 5341, 'OpTypeAccelerationStructureNV' : 5341,
'OpExecuteCallableKHR' : 5344,
'OpExecuteCallableNV' : 5344, 'OpExecuteCallableNV' : 5344,
'OpTypeCooperativeMatrixNV' : 5358, 'OpTypeCooperativeMatrixNV' : 5358,
'OpCooperativeMatrixLoadNV' : 5359, 'OpCooperativeMatrixLoadNV' : 5359,
...@@ -1390,6 +1477,23 @@ spv = { ...@@ -1390,6 +1477,23 @@ spv = {
'OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL' : 5814, 'OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL' : 5814,
'OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL' : 5815, 'OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL' : 5815,
'OpSubgroupAvcSicGetInterRawSadsINTEL' : 5816, 'OpSubgroupAvcSicGetInterRawSadsINTEL' : 5816,
'OpRayQueryGetRayTMinKHR' : 6016,
'OpRayQueryGetRayFlagsKHR' : 6017,
'OpRayQueryGetIntersectionTKHR' : 6018,
'OpRayQueryGetIntersectionInstanceCustomIndexKHR' : 6019,
'OpRayQueryGetIntersectionInstanceIdKHR' : 6020,
'OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR' : 6021,
'OpRayQueryGetIntersectionGeometryIndexKHR' : 6022,
'OpRayQueryGetIntersectionPrimitiveIndexKHR' : 6023,
'OpRayQueryGetIntersectionBarycentricsKHR' : 6024,
'OpRayQueryGetIntersectionFrontFaceKHR' : 6025,
'OpRayQueryGetIntersectionCandidateAABBOpaqueKHR' : 6026,
'OpRayQueryGetIntersectionObjectRayDirectionKHR' : 6027,
'OpRayQueryGetIntersectionObjectRayOriginKHR' : 6028,
'OpRayQueryGetWorldRayDirectionKHR' : 6029,
'OpRayQueryGetWorldRayOriginKHR' : 6030,
'OpRayQueryGetIntersectionObjectToWorldKHR' : 6031,
'OpRayQueryGetIntersectionWorldToObjectKHR' : 6032,
}, },
} }
......
/+ /+
+ Copyright (c) 2014-2019 The Khronos Group Inc. + Copyright (c) 2014-2020 The Khronos Group Inc.
+ +
+ Permission is hereby granted, free of charge, to any person obtaining a copy + Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and/or associated documentation files (the "Materials"), + of this software and/or associated documentation files (the "Materials"),
...@@ -77,11 +77,17 @@ enum ExecutionModel : uint ...@@ -77,11 +77,17 @@ enum ExecutionModel : uint
Kernel = 6, Kernel = 6,
TaskNV = 5267, TaskNV = 5267,
MeshNV = 5268, MeshNV = 5268,
RayGenerationKHR = 5313,
RayGenerationNV = 5313, RayGenerationNV = 5313,
IntersectionKHR = 5314,
IntersectionNV = 5314, IntersectionNV = 5314,
AnyHitKHR = 5315,
AnyHitNV = 5315, AnyHitNV = 5315,
ClosestHitKHR = 5316,
ClosestHitNV = 5316, ClosestHitNV = 5316,
MissKHR = 5317,
MissNV = 5317, MissNV = 5317,
CallableKHR = 5318,
CallableNV = 5318, CallableNV = 5318,
} }
...@@ -178,11 +184,17 @@ enum StorageClass : uint ...@@ -178,11 +184,17 @@ enum StorageClass : uint
AtomicCounter = 10, AtomicCounter = 10,
Image = 11, Image = 11,
StorageBuffer = 12, StorageBuffer = 12,
CallableDataKHR = 5328,
CallableDataNV = 5328, CallableDataNV = 5328,
IncomingCallableDataKHR = 5329,
IncomingCallableDataNV = 5329, IncomingCallableDataNV = 5329,
RayPayloadKHR = 5338,
RayPayloadNV = 5338, RayPayloadNV = 5338,
HitAttributeKHR = 5339,
HitAttributeNV = 5339, HitAttributeNV = 5339,
IncomingRayPayloadKHR = 5342,
IncomingRayPayloadNV = 5342, IncomingRayPayloadNV = 5342,
ShaderRecordBufferKHR = 5343,
ShaderRecordBufferNV = 5343, ShaderRecordBufferNV = 5343,
PhysicalStorageBuffer = 5349, PhysicalStorageBuffer = 5349,
PhysicalStorageBufferEXT = 5349, PhysicalStorageBufferEXT = 5349,
...@@ -559,20 +571,35 @@ enum BuiltIn : uint ...@@ -559,20 +571,35 @@ enum BuiltIn : uint
FragmentSizeNV = 5292, FragmentSizeNV = 5292,
FragInvocationCountEXT = 5293, FragInvocationCountEXT = 5293,
InvocationsPerPixelNV = 5293, InvocationsPerPixelNV = 5293,
LaunchIdKHR = 5319,
LaunchIdNV = 5319, LaunchIdNV = 5319,
LaunchSizeKHR = 5320,
LaunchSizeNV = 5320, LaunchSizeNV = 5320,
WorldRayOriginKHR = 5321,
WorldRayOriginNV = 5321, WorldRayOriginNV = 5321,
WorldRayDirectionKHR = 5322,
WorldRayDirectionNV = 5322, WorldRayDirectionNV = 5322,
ObjectRayOriginKHR = 5323,
ObjectRayOriginNV = 5323, ObjectRayOriginNV = 5323,
ObjectRayDirectionKHR = 5324,
ObjectRayDirectionNV = 5324, ObjectRayDirectionNV = 5324,
RayTminKHR = 5325,
RayTminNV = 5325, RayTminNV = 5325,
RayTmaxKHR = 5326,
RayTmaxNV = 5326, RayTmaxNV = 5326,
InstanceCustomIndexKHR = 5327,
InstanceCustomIndexNV = 5327, InstanceCustomIndexNV = 5327,
ObjectToWorldKHR = 5330,
ObjectToWorldNV = 5330, ObjectToWorldNV = 5330,
WorldToObjectKHR = 5331,
WorldToObjectNV = 5331, WorldToObjectNV = 5331,
HitTKHR = 5332,
HitTNV = 5332, HitTNV = 5332,
HitKindKHR = 5333,
HitKindNV = 5333, HitKindNV = 5333,
IncomingRayFlagsKHR = 5351,
IncomingRayFlagsNV = 5351, IncomingRayFlagsNV = 5351,
RayGeometryIndexKHR = 5352,
WarpsPerSMNV = 5374, WarpsPerSMNV = 5374,
SMCountNV = 5375, SMCountNV = 5375,
WarpIDNV = 5376, WarpIDNV = 5376,
...@@ -715,6 +742,7 @@ enum Scope : uint ...@@ -715,6 +742,7 @@ enum Scope : uint
Invocation = 4, Invocation = 4,
QueueFamily = 5, QueueFamily = 5,
QueueFamilyKHR = 5, QueueFamilyKHR = 5,
ShaderCallKHR = 6,
} }
enum GroupOperation : uint enum GroupOperation : uint
...@@ -840,6 +868,8 @@ enum Capability : uint ...@@ -840,6 +868,8 @@ enum Capability : uint
SignedZeroInfNanPreserve = 4466, SignedZeroInfNanPreserve = 4466,
RoundingModeRTE = 4467, RoundingModeRTE = 4467,
RoundingModeRTZ = 4468, RoundingModeRTZ = 4468,
RayQueryProvisionalKHR = 4471,
RayTraversalPrimitiveCullingProvisionalKHR = 4478,
Float16ImageAMD = 5008, Float16ImageAMD = 5008,
ImageGatherBiasLodAMD = 5009, ImageGatherBiasLodAMD = 5009,
FragmentMaskAMD = 5010, FragmentMaskAMD = 5010,
...@@ -893,6 +923,7 @@ enum Capability : uint ...@@ -893,6 +923,7 @@ enum Capability : uint
PhysicalStorageBufferAddresses = 5347, PhysicalStorageBufferAddresses = 5347,
PhysicalStorageBufferAddressesEXT = 5347, PhysicalStorageBufferAddressesEXT = 5347,
ComputeDerivativeGroupLinearNV = 5350, ComputeDerivativeGroupLinearNV = 5350,
RayTracingProvisionalKHR = 5353,
CooperativeMatrixNV = 5357, CooperativeMatrixNV = 5357,
FragmentShaderSampleInterlockEXT = 5363, FragmentShaderSampleInterlockEXT = 5363,
FragmentShaderShadingRateInterlockEXT = 5372, FragmentShaderShadingRateInterlockEXT = 5372,
...@@ -909,6 +940,54 @@ enum Capability : uint ...@@ -909,6 +940,54 @@ enum Capability : uint
SubgroupAvcMotionEstimationChromaINTEL = 5698, SubgroupAvcMotionEstimationChromaINTEL = 5698,
} }
enum RayFlagsShift : uint
{
OpaqueKHR = 0,
NoOpaqueKHR = 1,
TerminateOnFirstHitKHR = 2,
SkipClosestHitShaderKHR = 3,
CullBackFacingTrianglesKHR = 4,
CullFrontFacingTrianglesKHR = 5,
CullOpaqueKHR = 6,
CullNoOpaqueKHR = 7,
SkipTrianglesKHR = 8,
SkipAABBsKHR = 9,
}
enum RayFlagsMask : uint
{
MaskNone = 0,
OpaqueKHR = 0x00000001,
NoOpaqueKHR = 0x00000002,
TerminateOnFirstHitKHR = 0x00000004,
SkipClosestHitShaderKHR = 0x00000008,
CullBackFacingTrianglesKHR = 0x00000010,
CullFrontFacingTrianglesKHR = 0x00000020,
CullOpaqueKHR = 0x00000040,
CullNoOpaqueKHR = 0x00000080,
SkipTrianglesKHR = 0x00000100,
SkipAABBsKHR = 0x00000200,
}
enum RayQueryIntersection : uint
{
RayQueryCandidateIntersectionKHR = 0,
RayQueryCommittedIntersectionKHR = 1,
}
enum RayQueryCommittedIntersectionType : uint
{
RayQueryCommittedIntersectionNoneKHR = 0,
RayQueryCommittedIntersectionTriangleKHR = 1,
RayQueryCommittedIntersectionGeneratedKHR = 2,
}
enum RayQueryCandidateIntersectionType : uint
{
RayQueryCandidateIntersectionTriangleKHR = 0,
RayQueryCandidateIntersectionAABBKHR = 1,
}
enum Op : uint enum Op : uint
{ {
OpNop = 0, OpNop = 0,
...@@ -1261,6 +1340,13 @@ enum Op : uint ...@@ -1261,6 +1340,13 @@ enum Op : uint
OpSubgroupAnyKHR = 4429, OpSubgroupAnyKHR = 4429,
OpSubgroupAllEqualKHR = 4430, OpSubgroupAllEqualKHR = 4430,
OpSubgroupReadInvocationKHR = 4432, OpSubgroupReadInvocationKHR = 4432,
OpTypeRayQueryProvisionalKHR = 4472,
OpRayQueryInitializeKHR = 4473,
OpRayQueryTerminateKHR = 4474,
OpRayQueryGenerateIntersectionKHR = 4475,
OpRayQueryConfirmIntersectionKHR = 4476,
OpRayQueryProceedKHR = 4477,
OpRayQueryGetIntersectionTypeKHR = 4479,
OpGroupIAddNonUniformAMD = 5000, OpGroupIAddNonUniformAMD = 5000,
OpGroupFAddNonUniformAMD = 5001, OpGroupFAddNonUniformAMD = 5001,
OpGroupFMinNonUniformAMD = 5002, OpGroupFMinNonUniformAMD = 5002,
...@@ -1275,11 +1361,17 @@ enum Op : uint ...@@ -1275,11 +1361,17 @@ enum Op : uint
OpImageSampleFootprintNV = 5283, OpImageSampleFootprintNV = 5283,
OpGroupNonUniformPartitionNV = 5296, OpGroupNonUniformPartitionNV = 5296,
OpWritePackedPrimitiveIndices4x8NV = 5299, OpWritePackedPrimitiveIndices4x8NV = 5299,
OpReportIntersectionKHR = 5334,
OpReportIntersectionNV = 5334, OpReportIntersectionNV = 5334,
OpIgnoreIntersectionKHR = 5335,
OpIgnoreIntersectionNV = 5335, OpIgnoreIntersectionNV = 5335,
OpTerminateRayKHR = 5336,
OpTerminateRayNV = 5336, OpTerminateRayNV = 5336,
OpTraceNV = 5337, OpTraceNV = 5337,
OpTraceRayKHR = 5337,
OpTypeAccelerationStructureKHR = 5341,
OpTypeAccelerationStructureNV = 5341, OpTypeAccelerationStructureNV = 5341,
OpExecuteCallableKHR = 5344,
OpExecuteCallableNV = 5344, OpExecuteCallableNV = 5344,
OpTypeCooperativeMatrixNV = 5358, OpTypeCooperativeMatrixNV = 5358,
OpCooperativeMatrixLoadNV = 5359, OpCooperativeMatrixLoadNV = 5359,
...@@ -1436,6 +1528,23 @@ enum Op : uint ...@@ -1436,6 +1528,23 @@ enum Op : uint
OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL = 5814, OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL = 5814,
OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL = 5815, OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL = 5815,
OpSubgroupAvcSicGetInterRawSadsINTEL = 5816, OpSubgroupAvcSicGetInterRawSadsINTEL = 5816,
OpRayQueryGetRayTMinKHR = 6016,
OpRayQueryGetRayFlagsKHR = 6017,
OpRayQueryGetIntersectionTKHR = 6018,
OpRayQueryGetIntersectionInstanceCustomIndexKHR = 6019,
OpRayQueryGetIntersectionInstanceIdKHR = 6020,
OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR = 6021,
OpRayQueryGetIntersectionGeometryIndexKHR = 6022,
OpRayQueryGetIntersectionPrimitiveIndexKHR = 6023,
OpRayQueryGetIntersectionBarycentricsKHR = 6024,
OpRayQueryGetIntersectionFrontFaceKHR = 6025,
OpRayQueryGetIntersectionCandidateAABBOpaqueKHR = 6026,
OpRayQueryGetIntersectionObjectRayDirectionKHR = 6027,
OpRayQueryGetIntersectionObjectRayOriginKHR = 6028,
OpRayQueryGetWorldRayDirectionKHR = 6029,
OpRayQueryGetWorldRayOriginKHR = 6030,
OpRayQueryGetIntersectionObjectToWorldKHR = 6031,
OpRayQueryGetIntersectionWorldToObjectKHR = 6032,
} }
#!/usr/bin/env python3
# Copyright (c) 2017-2020 Google LLC
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and/or associated documentation files (the
# "Materials"), to deal in the Materials without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Materials, and to
# permit persons to whom the Materials are furnished to do so, subject to
# the following conditions:
#
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Materials.
#
# MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
# KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
# SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
# https://www.khronos.org/registry/
#
# THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
# CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
"""Generates a C language headers from a SPIR-V JSON grammar file"""
import errno
import json
import os.path
import re
DEFAULT_COPYRIGHT="""Copyright (c) 2020 The Khronos Group Inc.
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and/or associated documentation files (the
"Materials"), to deal in the Materials without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Materials, and to
permit persons to whom the Materials are furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Materials.
MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
https://www.khronos.org/registry/
THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
""".split('\n')
def make_path_to_file(f):
"""Makes all ancestor directories to the given file, if they
don't yet exist.
Arguments:
f: The file whose ancestor directories are to be created.
"""
dir = os.path.dirname(os.path.abspath(f))
try:
os.makedirs(dir)
except OSError as e:
if e.errno == errno.EEXIST and os.path.isdir(dir):
pass
else:
raise
class ExtInstGrammar:
"""The grammar for an extended instruction set"""
def __init__(self, name, copyright, instructions, operand_kinds, version = None, revision = None):
self.name = name
self.copyright = copyright
self.instructions = instructions
self.operand_kinds = operand_kinds
self.version = version
self.revision = revision
class LangGenerator:
"""A language-specific generator"""
def __init__(self):
self.upper_case_initial = re.compile('^[A-Z]')
pass
def comment_prefix(self):
return ""
def namespace_prefix(self):
return ""
def uses_guards(self):
return False
def cpp_guard_preamble(self):
return ""
def cpp_guard_postamble(self):
return ""
def enum_value(self, prefix, name, value):
if self.upper_case_initial.match(name):
use_name = name
else:
use_name = '_' + name
return " {}{} = {},".format(prefix, use_name, value)
def generate(self, grammar):
"""Returns a string that is the language-specific header for the given grammar"""
parts = []
if grammar.copyright:
parts.extend(["{}{}".format(self.comment_prefix(), f) for f in grammar.copyright])
parts.append('')
guard = 'SPIRV_UNIFIED1_{}_H_'.format(grammar.name)
if self.uses_guards:
parts.append('#ifndef {}'.format(guard))
parts.append('#define {}'.format(guard))
parts.append('')
parts.append(self.cpp_guard_preamble())
if grammar.version:
parts.append(self.const_definition(grammar.name, 'Version', grammar.version))
if grammar.revision is not None:
parts.append(self.const_definition(grammar.name, 'Revision', grammar.revision))
parts.append('')
if grammar.instructions:
parts.append(self.enum_prefix(grammar.name, 'Instructions'))
for inst in grammar.instructions:
parts.append(self.enum_value(grammar.name, inst['opname'], inst['opcode']))
parts.append(self.enum_end(grammar.name, 'Instructions'))
parts.append('')
if grammar.operand_kinds:
for kind in grammar.operand_kinds:
parts.append(self.enum_prefix(grammar.name, kind['kind']))
for e in kind['enumerants']:
parts.append(self.enum_value(grammar.name, e['enumerant'], e['value']))
parts.append(self.enum_end(grammar.name, kind['kind']))
parts.append('')
parts.append(self.cpp_guard_postamble())
if self.uses_guards:
parts.append('#endif // {}'.format(guard))
# Ensre the file ends in an end of line
parts.append('')
return '\n'.join(parts)
class CLikeGenerator(LangGenerator):
def uses_guards(self):
return True
def comment_prefix(self):
return "// "
def const_definition(self, prefix, var, value):
# Use an anonymous enum. Don't use a static const int variable because
# that can bloat binary size.
return 'enum {0}{1}{2}{3} = {4},{1}{2}{3}_BitWidthPadding = 0x7fffffff{5};'.format(
'{', '\n ', prefix, var, value, '\n}')
def enum_prefix(self, prefix, name):
return 'enum {}{} {}'.format(prefix, name, '{')
def enum_end(self, prefix, enum):
return ' {}{}Max = 0x7fffffff\n{};\n'.format(prefix, enum, '}')
def cpp_guard_preamble(self):
return '#ifdef __cplusplus\nextern "C" {\n#endif\n'
def cpp_guard_postamble(self):
return '#ifdef __cplusplus\n}\n#endif\n'
class CGenerator(CLikeGenerator):
pass
def main():
import argparse
parser = argparse.ArgumentParser(description='Generate language headers from a JSON grammar')
parser.add_argument('--extinst-name',
type=str, required=True,
help='The name to use in tokens')
parser.add_argument('--extinst-grammar', metavar='<path>',
type=str, required=True,
help='input JSON grammar file for extended instruction set')
parser.add_argument('--extinst-output-base', metavar='<path>',
type=str, required=True,
help='Basename of the language-specific output file.')
args = parser.parse_args()
with open(args.extinst_grammar) as json_file:
grammar_json = json.loads(json_file.read())
if 'copyright' in grammar_json:
copyright = grammar_json['copyright']
else:
copyright = DEFAULT_COPYRIGHT
if 'version' in grammar_json:
version = grammar_json['version']
else:
version = 0
if 'operand_kinds' in grammar_json:
operand_kinds = grammar_json['operand_kinds']
else:
operand_kinds = []
grammar = ExtInstGrammar(name = args.extinst_name,
copyright = copyright,
instructions = grammar_json['instructions'],
operand_kinds = operand_kinds,
version = version,
revision = grammar_json['revision'])
make_path_to_file(args.extinst_output_base)
with open(args.extinst_output_base + '.h', 'w') as f:
f.write(CGenerator().generate(grammar))
if __name__ == '__main__':
main()
#!/usr/bin/env python3
"""Generate C headers for certain extended instruction sets"""
import subprocess
import os
# Assume we are running from the tools/buildHeaders directory
os.chdir('../../include/spirv/unified1')
def mk_extinst(name, grammar_file):
"""Generate one C header from a grammar"""
script = '../../../tools/buildHeaders/bin/generate_language_headers.py'
subprocess.check_call(['python3',
script,
'--extinst-name=' + name,
'--extinst-grammar=' + grammar_file,
'--extinst-output-base=' + name])
subprocess.check_call(['dos2unix', name + '.h'])
mk_extinst('DebugInfo', 'extinst.debuginfo.grammar.json')
mk_extinst('OpenCLDebugInfo100', 'extinst.opencl.debuginfo.100.grammar.json')
mk_extinst('AMD_gcn_shader', 'extinst.spv-amd-gcn-shader.grammar.json')
mk_extinst('AMD_shader_ballot', 'extinst.spv-amd-shader-ballot.grammar.json')
mk_extinst('AMD_shader_explicit_vertex_parameter', 'extinst.spv-amd-shader-explicit-vertex-parameter.grammar.json')
mk_extinst('AMD_shader_trinary_minmax', 'extinst.spv-amd-shader-trinary-minmax.grammar.json')
mk_extinst('NonSemanticDebugPrintf', 'extinst.nonsemantic.debugprintf.grammar.json')
#!/usr/bin/env bash #!/usr/bin/env bash
python3 bin/makeExtinstHeaders.py
cd ../../include/spirv/unified1 cd ../../include/spirv/unified1
../../../tools/buildHeaders/build/install/bin/buildSpvHeaders -H spirv.core.grammar.json ../../../tools/buildHeaders/build/install/bin/buildSpvHeaders -H spirv.core.grammar.json
dos2unix spirv.* SpirV.* spv.* dos2unix spirv.* SpirV.* spv.*
// Copyright (c) 2014-2019 The Khronos Group Inc. // Copyright (c) 2014-2020 The Khronos Group Inc.
// //
// Permission is hereby granted, free of charge, to any person obtaining a copy // Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and/or associated documentation files (the "Materials"), // of this software and/or associated documentation files (the "Materials"),
...@@ -169,7 +169,7 @@ namespace { ...@@ -169,7 +169,7 @@ namespace {
} }
const std::string TPrinter::DocCopyright = const std::string TPrinter::DocCopyright =
"Copyright (c) 2014-2019 The Khronos Group Inc.\n" "Copyright (c) 2014-2020 The Khronos Group Inc.\n"
"\n" "\n"
"Permission is hereby granted, free of charge, to any person obtaining a copy\n" "Permission is hereby granted, free of charge, to any person obtaining a copy\n"
"of this software and/or associated documentation files (the \"Materials\"),\n" "of this software and/or associated documentation files (the \"Materials\"),\n"
......
// Copyright (c) 2014-2019 The Khronos Group Inc. // Copyright (c) 2014-2020 The Khronos Group Inc.
// //
// Permission is hereby granted, free of charge, to any person obtaining a copy // Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and/or associated documentation files (the "Materials"), // of this software and/or associated documentation files (the "Materials"),
...@@ -77,6 +77,10 @@ EnumValues ScopeParams; ...@@ -77,6 +77,10 @@ EnumValues ScopeParams;
EnumValues KernelEnqueueFlagsParams; EnumValues KernelEnqueueFlagsParams;
EnumValues KernelProfilingInfoParams; EnumValues KernelProfilingInfoParams;
EnumValues CapabilityParams; EnumValues CapabilityParams;
EnumValues RayFlagsParams;
EnumValues RayQueryIntersectionParams;
EnumValues RayQueryCommittedIntersectionTypeParams;
EnumValues RayQueryCandidateIntersectionTypeParams;
std::pair<bool, std::string> ReadFile(const std::string& path) std::pair<bool, std::string> ReadFile(const std::string& path)
{ {
...@@ -146,7 +150,7 @@ ClassOptionality ToOperandClassAndOptionality(const std::string& operandKind, co ...@@ -146,7 +150,7 @@ ClassOptionality ToOperandClassAndOptionality(const std::string& operandKind, co
} else if (operandKind == "LiteralSpecConstantOpInteger") { } else if (operandKind == "LiteralSpecConstantOpInteger") {
type = OperandLiteralNumber; type = OperandLiteralNumber;
} else if (operandKind == "LiteralContextDependentNumber") { } else if (operandKind == "LiteralContextDependentNumber") {
type = OperandVariableLiterals; type = OperandAnySizeLiteralNumber;
} else if (operandKind == "SourceLanguage") { } else if (operandKind == "SourceLanguage") {
type = OperandSource; type = OperandSource;
} else if (operandKind == "ExecutionModel") { } else if (operandKind == "ExecutionModel") {
...@@ -203,6 +207,14 @@ ClassOptionality ToOperandClassAndOptionality(const std::string& operandKind, co ...@@ -203,6 +207,14 @@ ClassOptionality ToOperandClassAndOptionality(const std::string& operandKind, co
type = OperandFunction; type = OperandFunction;
} else if (operandKind == "MemoryAccess") { } else if (operandKind == "MemoryAccess") {
type = OperandMemoryOperands; type = OperandMemoryOperands;
} else if (operandKind == "RayFlags") {
type = OperandRayFlags;
} else if (operandKind == "RayQueryIntersection") {
type = OperandRayQueryIntersection;
} else if (operandKind == "RayQueryCommittedIntersectionType") {
type = OperandRayQueryCommittedIntersectionType;
} else if (operandKind == "RayQueryCandidateIntersectionType") {
type = OperandRayQueryCandidateIntersectionType;
} }
if (type == OperandNone) { if (type == OperandNone) {
...@@ -463,6 +475,14 @@ void jsonToSpirv(const std::string& jsonPath, bool buildingHeaders) ...@@ -463,6 +475,14 @@ void jsonToSpirv(const std::string& jsonPath, bool buildingHeaders)
establishOperandClass(enumName, OperandKernelEnqueueFlags, &KernelEnqueueFlagsParams, operandEnum, category); establishOperandClass(enumName, OperandKernelEnqueueFlags, &KernelEnqueueFlagsParams, operandEnum, category);
} else if (enumName == "KernelProfilingInfo") { } else if (enumName == "KernelProfilingInfo") {
establishOperandClass(enumName, OperandKernelProfilingInfo, &KernelProfilingInfoParams, operandEnum, category); establishOperandClass(enumName, OperandKernelProfilingInfo, &KernelProfilingInfoParams, operandEnum, category);
} else if (enumName == "RayFlags") {
establishOperandClass(enumName, OperandRayFlags, &RayFlagsParams, operandEnum, category);
} else if (enumName == "RayQueryIntersection") {
establishOperandClass(enumName, OperandRayQueryIntersection, &RayQueryIntersectionParams, operandEnum, category);
} else if (enumName == "RayQueryCommittedIntersectionType") {
establishOperandClass(enumName, OperandRayQueryCommittedIntersectionType, &RayQueryCommittedIntersectionTypeParams, operandEnum, category);
} else if (enumName == "RayQueryCandidateIntersectionType") {
establishOperandClass(enumName, OperandRayQueryCandidateIntersectionType, &RayQueryCandidateIntersectionTypeParams, operandEnum, category);
} }
} }
} }
......
// Copyright (c) 2014-2019 The Khronos Group Inc. // Copyright (c) 2014-2020 The Khronos Group Inc.
// //
// Permission is hereby granted, free of charge, to any person obtaining a copy // Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and/or associated documentation files (the "Materials"), // of this software and/or associated documentation files (the "Materials"),
...@@ -51,6 +51,7 @@ enum OperandClass { ...@@ -51,6 +51,7 @@ enum OperandClass {
OperandVariableLiterals, OperandVariableLiterals,
OperandVariableIdLiteral, OperandVariableIdLiteral,
OperandVariableLiteralId, OperandVariableLiteralId,
OperandAnySizeLiteralNumber,
OperandLiteralNumber, OperandLiteralNumber,
OperandLiteralString, OperandLiteralString,
OperandSource, OperandSource,
...@@ -83,6 +84,10 @@ enum OperandClass { ...@@ -83,6 +84,10 @@ enum OperandClass {
OperandKernelEnqueueFlags, OperandKernelEnqueueFlags,
OperandKernelProfilingInfo, OperandKernelProfilingInfo,
OperandCapability, OperandCapability,
OperandRayFlags,
OperandRayQueryIntersection,
OperandRayQueryCommittedIntersectionType,
OperandRayQueryCandidateIntersectionType,
OperandOpcode, OperandOpcode,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment