Add SPV_KHR_shader_ballot enumerants for 1.0.
authorJohn Kessenich <cepheus@frii.com>
Fri, 16 Sep 2016 18:16:00 +0000 (12:16 -0600)
committerJohn Kessenich <cepheus@frii.com>
Fri, 16 Sep 2016 18:16:00 +0000 (12:16 -0600)
include/spirv/1.0/spirv.core.grammar.json
include/spirv/1.0/spirv.h
include/spirv/1.0/spirv.hpp
include/spirv/1.0/spirv.hpp11
include/spirv/1.0/spirv.json
include/spirv/1.0/spirv.lua
include/spirv/1.0/spirv.py

index 0192b72..1466160 100644 (file)
         { "kind" : "ImageOperands", "quantifier" : "?" }
       ],
       "capabilities" : [ "SparseResidency" ]
+    },
+    {
+      "opname" : "OpSubgroupBallotKHR",
+      "opcode" : 4421,
+      "operands" : [
+        { "kind" : "IdResultType" },
+        { "kind" : "IdResult" },
+        { "kind" : "IdRef", "name" : "'Predicate'" }
+      ],
+      "capabilities" : [ "SubgroupBallotKHR" ]
+    },
+    {
+      "opname" : "OpSubgroupFirstInvocationKHR",
+      "opcode" : 4422,
+      "operands" : [
+        { "kind" : "IdResultType" },
+        { "kind" : "IdResult" },
+        { "kind" : "IdRef", "name" : "'Value'" }
+      ],
+      "capabilities" : [ "SubgroupBallotKHR" ]
     }
   ],
   "operand_kinds" : [
           "value" : "0x0000"
         },
         {
-          "enumerant" : "SequentiallyConsistent",
-          "value" : "0x0010"
-        },
-        {
           "enumerant" : "Acquire",
           "value" : "0x0002"
         },
           "value" : "0x0008"
         },
         {
+          "enumerant" : "SequentiallyConsistent",
+          "value" : "0x0010"
+        },
+        {
           "enumerant" : "UniformMemory",
           "value" : "0x0040",
           "capabilities" : [ "Shader" ]
           "enumerant" : "InstanceIndex",
           "value" : 43,
           "capabilities" : [ "Shader" ]
+        },
+        {
+          "enumerant" : "SubgroupEqMaskKHR",
+          "value" : 4416,
+          "capabilities" : [ "SubgroupBallotKHR" ]
+        },
+        {
+          "enumerant" : "SubgroupGeMaskKHR",
+          "value" : 4417,
+          "capabilities" : [ "SubgroupBallotKHR" ]
+        },
+        {
+          "enumerant" : "SubgroupGtMaskKHR",
+          "value" : 4418,
+          "capabilities" : [ "SubgroupBallotKHR" ]
+        },
+        {
+          "enumerant" : "SubgroupLeMaskKHR",
+          "value" : 4419,
+          "capabilities" : [ "SubgroupBallotKHR" ]
+        },
+        {
+          "enumerant" : "SubgroupLtMaskKHR",
+          "value" : 4420,
+          "capabilities" : [ "SubgroupBallotKHR" ]
         }
       ]
     },
           "enumerant" : "MultiViewport",
           "value" : 57,
           "capabilities" : [ "Geometry" ]
+        },
+        {
+          "enumerant" : "SubgroupBallotKHR",
+          "value" : 4423,
+          "extensions" : [ "SPV_KHR_shader_ballot" ]
         }
       ]
     },
index ef917a4..ae8dd13 100644 (file)
@@ -423,6 +423,11 @@ typedef enum SpvBuiltIn_ {
     SpvBuiltInSubgroupLocalInvocationId = 41,
     SpvBuiltInVertexIndex = 42,
     SpvBuiltInInstanceIndex = 43,
+    SpvBuiltInSubgroupEqMaskKHR = 4416,
+    SpvBuiltInSubgroupGeMaskKHR = 4417,
+    SpvBuiltInSubgroupGtMaskKHR = 4418,
+    SpvBuiltInSubgroupLeMaskKHR = 4419,
+    SpvBuiltInSubgroupLtMaskKHR = 4420,
     SpvBuiltInMax = 0x7fffffff,
 } SpvBuiltIn;
 
@@ -598,6 +603,7 @@ typedef enum SpvCapability_ {
     SpvCapabilityStorageImageReadWithoutFormat = 55,
     SpvCapabilityStorageImageWriteWithoutFormat = 56,
     SpvCapabilityMultiViewport = 57,
+    SpvCapabilitySubgroupBallotKHR = 4423,
     SpvCapabilityMax = 0x7fffffff,
 } SpvCapability;
 
@@ -896,6 +902,8 @@ typedef enum SpvOp_ {
     SpvOpAtomicFlagTestAndSet = 318,
     SpvOpAtomicFlagClear = 319,
     SpvOpImageSparseRead = 320,
+    SpvOpSubgroupBallotKHR = 4421,
+    SpvOpSubgroupFirstInvocationKHR = 4422,
     SpvOpMax = 0x7fffffff,
 } SpvOp;
 
index 8e28da7..b80a006 100644 (file)
@@ -419,6 +419,11 @@ enum BuiltIn {
     BuiltInSubgroupLocalInvocationId = 41,
     BuiltInVertexIndex = 42,
     BuiltInInstanceIndex = 43,
+    BuiltInSubgroupEqMaskKHR = 4416,
+    BuiltInSubgroupGeMaskKHR = 4417,
+    BuiltInSubgroupGtMaskKHR = 4418,
+    BuiltInSubgroupLeMaskKHR = 4419,
+    BuiltInSubgroupLtMaskKHR = 4420,
     BuiltInMax = 0x7fffffff,
 };
 
@@ -594,6 +599,7 @@ enum Capability {
     CapabilityStorageImageReadWithoutFormat = 55,
     CapabilityStorageImageWriteWithoutFormat = 56,
     CapabilityMultiViewport = 57,
+    CapabilitySubgroupBallotKHR = 4423,
     CapabilityMax = 0x7fffffff,
 };
 
@@ -892,6 +898,8 @@ enum Op {
     OpAtomicFlagTestAndSet = 318,
     OpAtomicFlagClear = 319,
     OpImageSparseRead = 320,
+    OpSubgroupBallotKHR = 4421,
+    OpSubgroupFirstInvocationKHR = 4422,
     OpMax = 0x7fffffff,
 };
 
index 61d7222..284a378 100644 (file)
@@ -419,6 +419,11 @@ enum class BuiltIn : unsigned {
     SubgroupLocalInvocationId = 41,
     VertexIndex = 42,
     InstanceIndex = 43,
+    SubgroupEqMaskKHR = 4416,
+    SubgroupGeMaskKHR = 4417,
+    SubgroupGtMaskKHR = 4418,
+    SubgroupLeMaskKHR = 4419,
+    SubgroupLtMaskKHR = 4420,
     Max = 0x7fffffff,
 };
 
@@ -594,6 +599,7 @@ enum class Capability : unsigned {
     StorageImageReadWithoutFormat = 55,
     StorageImageWriteWithoutFormat = 56,
     MultiViewport = 57,
+    SubgroupBallotKHR = 4423,
     Max = 0x7fffffff,
 };
 
@@ -892,6 +898,8 @@ enum class Op : unsigned {
     OpAtomicFlagTestAndSet = 318,
     OpAtomicFlagClear = 319,
     OpImageSparseRead = 320,
+    OpSubgroupBallotKHR = 4421,
+    OpSubgroupFirstInvocationKHR = 4422,
     Max = 0x7fffffff,
 };
 
index 489d2dd..c7f5369 100644 (file)
                     "SubgroupId": 40,
                     "SubgroupLocalInvocationId": 41,
                     "VertexIndex": 42,
-                    "InstanceIndex": 43
+                    "InstanceIndex": 43,
+                    "SubgroupEqMaskKHR": 4416,
+                    "SubgroupGeMaskKHR": 4417,
+                    "SubgroupGtMaskKHR": 4418,
+                    "SubgroupLeMaskKHR": 4419,
+                    "SubgroupLtMaskKHR": 4420
                 }
             },
             {
                     "GeometryStreams": 54,
                     "StorageImageReadWithoutFormat": 55,
                     "StorageImageWriteWithoutFormat": 56,
-                    "MultiViewport": 57
+                    "MultiViewport": 57,
+                    "SubgroupBallotKHR": 4423
                 }
             },
             {
                     "OpNoLine": 317,
                     "OpAtomicFlagTestAndSet": 318,
                     "OpAtomicFlagClear": 319,
-                    "OpImageSparseRead": 320
+                    "OpImageSparseRead": 320,
+                    "OpSubgroupBallotKHR": 4421,
+                    "OpSubgroupFirstInvocationKHR": 4422
                 }
             }
         ]
index 1ac1718..2f09386 100644 (file)
@@ -391,6 +391,11 @@ spv = {
         SubgroupLocalInvocationId = 41,
         VertexIndex = 42,
         InstanceIndex = 43,
+        SubgroupEqMaskKHR = 4416,
+        SubgroupGeMaskKHR = 4417,
+        SubgroupGtMaskKHR = 4418,
+        SubgroupLeMaskKHR = 4419,
+        SubgroupLtMaskKHR = 4420,
     },
 
     SelectionControlShift = {
@@ -556,6 +561,7 @@ spv = {
         StorageImageReadWithoutFormat = 55,
         StorageImageWriteWithoutFormat = 56,
         MultiViewport = 57,
+        SubgroupBallotKHR = 4423,
     },
 
     Op = {
@@ -853,6 +859,8 @@ spv = {
         OpAtomicFlagTestAndSet = 318,
         OpAtomicFlagClear = 319,
         OpImageSparseRead = 320,
+        OpSubgroupBallotKHR = 4421,
+        OpSubgroupFirstInvocationKHR = 4422,
     },
 
 }
index e0ef9e8..550ab69 100644 (file)
@@ -391,6 +391,11 @@ spv = {
         'SubgroupLocalInvocationId' : 41,
         'VertexIndex' : 42,
         'InstanceIndex' : 43,
+        'SubgroupEqMaskKHR' : 4416,
+        'SubgroupGeMaskKHR' : 4417,
+        'SubgroupGtMaskKHR' : 4418,
+        'SubgroupLeMaskKHR' : 4419,
+        'SubgroupLtMaskKHR' : 4420,
     },
 
     'SelectionControlShift' : {
@@ -556,6 +561,7 @@ spv = {
         'StorageImageReadWithoutFormat' : 55,
         'StorageImageWriteWithoutFormat' : 56,
         'MultiViewport' : 57,
+        'SubgroupBallotKHR' : 4423,
     },
 
     'Op' : {
@@ -853,6 +859,8 @@ spv = {
         'OpAtomicFlagTestAndSet' : 318,
         'OpAtomicFlagClear' : 319,
         'OpImageSparseRead' : 320,
+        'OpSubgroupBallotKHR' : 4421,
+        'OpSubgroupFirstInvocationKHR' : 4422,
     },
 
 }