1spv.ext.meshShaderBuiltins.mesh 2// Module Version 10400 3// Generated by (magic number): 8000b 4// Id's are bound by 158 5 6 Capability ClipDistance 7 Capability CullDistance 8 Capability DrawParameters 9 Capability MultiView 10 Capability MeshShadingEXT 11 Extension "SPV_EXT_mesh_shader" 12 1: ExtInstImport "GLSL.std.450" 13 MemoryModel Logical GLSL450 14 EntryPoint MeshEXT 4 "main" 13 19 24 41 93 134 152 155 15 ExecutionMode 4 LocalSize 32 1 1 16 ExecutionMode 4 OutputVertices 81 17 ExecutionMode 4 OutputPrimitivesNV 32 18 ExecutionMode 4 OutputTrianglesNV 19 Source GLSL 460 20 SourceExtension "GL_ARB_shader_draw_parameters" 21 SourceExtension "GL_EXT_mesh_shader" 22 SourceExtension "GL_EXT_multiview" 23 Name 4 "main" 24 Name 6 "testAdditionalBuiltins(" 25 Name 10 "iid" 26 Name 13 "gl_LocalInvocationID" 27 Name 18 "gid" 28 Name 19 "gl_WorkGroupID" 29 Name 23 "numWorkGrous" 30 Name 24 "gl_NumWorkGroups" 31 Name 26 "vertexCount" 32 Name 28 "primitiveCount" 33 Name 38 "gl_MeshPerVertexEXT" 34 MemberName 38(gl_MeshPerVertexEXT) 0 "gl_Position" 35 MemberName 38(gl_MeshPerVertexEXT) 1 "gl_PointSize" 36 MemberName 38(gl_MeshPerVertexEXT) 2 "gl_ClipDistance" 37 MemberName 38(gl_MeshPerVertexEXT) 3 "gl_CullDistance" 38 Name 41 "gl_MeshVerticesEXT" 39 Name 90 "gl_MeshPerPrimitiveEXT" 40 MemberName 90(gl_MeshPerPrimitiveEXT) 0 "gl_PrimitiveID" 41 MemberName 90(gl_MeshPerPrimitiveEXT) 1 "gl_Layer" 42 MemberName 90(gl_MeshPerPrimitiveEXT) 2 "gl_ViewportIndex" 43 MemberName 90(gl_MeshPerPrimitiveEXT) 3 "gl_CullPrimitiveEXT" 44 Name 93 "gl_MeshPrimitivesEXT" 45 Name 134 "gl_PrimitiveTriangleIndicesEXT" 46 Name 150 "id" 47 Name 152 "gl_DrawIDARB" 48 Name 154 "viewIdx" 49 Name 155 "gl_ViewIndex" 50 Decorate 13(gl_LocalInvocationID) BuiltIn LocalInvocationId 51 Decorate 19(gl_WorkGroupID) BuiltIn WorkgroupId 52 Decorate 24(gl_NumWorkGroups) BuiltIn NumWorkgroups 53 Decorate 38(gl_MeshPerVertexEXT) Block 54 MemberDecorate 38(gl_MeshPerVertexEXT) 0 BuiltIn Position 55 MemberDecorate 38(gl_MeshPerVertexEXT) 1 BuiltIn PointSize 56 MemberDecorate 38(gl_MeshPerVertexEXT) 2 BuiltIn ClipDistance 57 MemberDecorate 38(gl_MeshPerVertexEXT) 3 BuiltIn CullDistance 58 Decorate 90(gl_MeshPerPrimitiveEXT) Block 59 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 0 BuiltIn PrimitiveId 60 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 0 PerPrimitiveNV 61 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 1 BuiltIn Layer 62 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 1 PerPrimitiveNV 63 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 2 BuiltIn ViewportIndex 64 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 2 PerPrimitiveNV 65 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 3 BuiltIn CullPrimitiveEXT 66 MemberDecorate 90(gl_MeshPerPrimitiveEXT) 3 PerPrimitiveNV 67 Decorate 134(gl_PrimitiveTriangleIndicesEXT) BuiltIn PrimitiveTriangleIndicesEXT 68 Decorate 152(gl_DrawIDARB) BuiltIn DrawIndex 69 Decorate 155(gl_ViewIndex) BuiltIn ViewIndex 70 Decorate 157 BuiltIn WorkgroupSize 71 2: TypeVoid 72 3: TypeFunction 2 73 8: TypeInt 32 0 74 9: TypePointer Function 8(int) 75 11: TypeVector 8(int) 3 76 12: TypePointer Input 11(ivec3) 7713(gl_LocalInvocationID): 12(ptr) Variable Input 78 14: 8(int) Constant 0 79 15: TypePointer Input 8(int) 8019(gl_WorkGroupID): 12(ptr) Variable Input 81 22: TypePointer Function 11(ivec3) 8224(gl_NumWorkGroups): 12(ptr) Variable Input 83 27: 8(int) Constant 81 84 29: 8(int) Constant 32 85 32: TypeFloat 32 86 33: TypeVector 32(float) 4 87 34: 8(int) Constant 4 88 35: TypeArray 32(float) 34 89 36: 8(int) Constant 3 90 37: TypeArray 32(float) 36 9138(gl_MeshPerVertexEXT): TypeStruct 33(fvec4) 32(float) 35 37 92 39: TypeArray 38(gl_MeshPerVertexEXT) 27 93 40: TypePointer Output 39 9441(gl_MeshVerticesEXT): 40(ptr) Variable Output 95 43: TypeInt 32 1 96 44: 43(int) Constant 0 97 45: 32(float) Constant 1065353216 98 46: 33(fvec4) ConstantComposite 45 45 45 45 99 47: TypePointer Output 33(fvec4) 100 50: 43(int) Constant 1 101 51: 32(float) Constant 1073741824 102 52: TypePointer Output 32(float) 103 55: 43(int) Constant 2 104 56: 43(int) Constant 3 105 57: 32(float) Constant 1077936128 106 60: 32(float) Constant 1082130432 107 62: 8(int) Constant 1 108 63: 8(int) Constant 264 109 64: 8(int) Constant 2 110 89: TypeBool 11190(gl_MeshPerPrimitiveEXT): TypeStruct 43(int) 43(int) 43(int) 89(bool) 112 91: TypeArray 90(gl_MeshPerPrimitiveEXT) 29 113 92: TypePointer Output 91 11493(gl_MeshPrimitivesEXT): 92(ptr) Variable Output 115 95: 43(int) Constant 6 116 96: TypePointer Output 43(int) 117 99: 43(int) Constant 7 118 102: 43(int) Constant 8 119 105: 89(bool) ConstantFalse 120 106: TypePointer Output 89(bool) 121 132: TypeArray 11(ivec3) 29 122 133: TypePointer Output 132 123134(gl_PrimitiveTriangleIndicesEXT): 133(ptr) Variable Output 124 135: 8(int) Constant 257 125 136: 11(ivec3) ConstantComposite 135 135 135 126 137: TypePointer Output 11(ivec3) 127 141: 11(ivec3) ConstantComposite 64 64 64 128 149: TypePointer Function 43(int) 129 151: TypePointer Input 43(int) 130152(gl_DrawIDARB): 151(ptr) Variable Input 131155(gl_ViewIndex): 151(ptr) Variable Input 132 157: 11(ivec3) ConstantComposite 29 62 62 133 4(main): 2 Function None 3 134 5: Label 135 10(iid): 9(ptr) Variable Function 136 18(gid): 9(ptr) Variable Function 13723(numWorkGrous): 22(ptr) Variable Function 138 26(vertexCount): 9(ptr) Variable Function 13928(primitiveCount): 9(ptr) Variable Function 140 16: 15(ptr) AccessChain 13(gl_LocalInvocationID) 14 141 17: 8(int) Load 16 142 Store 10(iid) 17 143 20: 15(ptr) AccessChain 19(gl_WorkGroupID) 14 144 21: 8(int) Load 20 145 Store 18(gid) 21 146 25: 11(ivec3) Load 24(gl_NumWorkGroups) 147 Store 23(numWorkGrous) 25 148 Store 26(vertexCount) 27 149 Store 28(primitiveCount) 29 150 30: 8(int) Load 26(vertexCount) 151 31: 8(int) Load 28(primitiveCount) 152 SetMeshOutputsEXT 30 31 153 42: 8(int) Load 10(iid) 154 48: 47(ptr) AccessChain 41(gl_MeshVerticesEXT) 42 44 155 Store 48 46 156 49: 8(int) Load 10(iid) 157 53: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 49 50 158 Store 53 51 159 54: 8(int) Load 10(iid) 160 58: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 54 55 56 161 Store 58 57 162 59: 8(int) Load 10(iid) 163 61: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 59 56 55 164 Store 61 60 165 MemoryBarrier 62 63 166 ControlBarrier 64 64 63 167 65: 8(int) Load 10(iid) 168 66: 8(int) IAdd 65 62 169 67: 8(int) Load 10(iid) 170 68: 47(ptr) AccessChain 41(gl_MeshVerticesEXT) 67 44 171 69: 33(fvec4) Load 68 172 70: 47(ptr) AccessChain 41(gl_MeshVerticesEXT) 66 44 173 Store 70 69 174 71: 8(int) Load 10(iid) 175 72: 8(int) IAdd 71 62 176 73: 8(int) Load 10(iid) 177 74: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 73 50 178 75: 32(float) Load 74 179 76: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 72 50 180 Store 76 75 181 77: 8(int) Load 10(iid) 182 78: 8(int) IAdd 77 62 183 79: 8(int) Load 10(iid) 184 80: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 79 55 56 185 81: 32(float) Load 80 186 82: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 78 55 56 187 Store 82 81 188 83: 8(int) Load 10(iid) 189 84: 8(int) IAdd 83 62 190 85: 8(int) Load 10(iid) 191 86: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 85 56 55 192 87: 32(float) Load 86 193 88: 52(ptr) AccessChain 41(gl_MeshVerticesEXT) 84 56 55 194 Store 88 87 195 MemoryBarrier 62 63 196 ControlBarrier 64 64 63 197 94: 8(int) Load 10(iid) 198 97: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 94 44 199 Store 97 95 200 98: 8(int) Load 10(iid) 201 100: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 98 50 202 Store 100 99 203 101: 8(int) Load 10(iid) 204 103: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 101 55 205 Store 103 102 206 104: 8(int) Load 10(iid) 207 107: 106(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 104 56 208 Store 107 105 209 MemoryBarrier 62 63 210 ControlBarrier 64 64 63 211 108: 8(int) Load 10(iid) 212 109: 8(int) IAdd 108 62 213 110: 8(int) Load 10(iid) 214 111: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 110 44 215 112: 43(int) Load 111 216 113: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 109 44 217 Store 113 112 218 114: 8(int) Load 10(iid) 219 115: 8(int) IAdd 114 62 220 116: 8(int) Load 10(iid) 221 117: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 116 50 222 118: 43(int) Load 117 223 119: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 115 50 224 Store 119 118 225 120: 8(int) Load 10(iid) 226 121: 8(int) IAdd 120 62 227 122: 8(int) Load 10(iid) 228 123: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 122 55 229 124: 43(int) Load 123 230 125: 96(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 121 55 231 Store 125 124 232 126: 8(int) Load 10(iid) 233 127: 8(int) IAdd 126 62 234 128: 8(int) Load 10(iid) 235 129: 106(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 128 56 236 130: 89(bool) Load 129 237 131: 106(ptr) AccessChain 93(gl_MeshPrimitivesEXT) 127 56 238 Store 131 130 239 MemoryBarrier 62 63 240 ControlBarrier 64 64 63 241 138: 137(ptr) AccessChain 134(gl_PrimitiveTriangleIndicesEXT) 44 242 Store 138 136 243 139: 8(int) Load 28(primitiveCount) 244 140: 8(int) ISub 139 62 245 142: 137(ptr) AccessChain 134(gl_PrimitiveTriangleIndicesEXT) 140 246 Store 142 141 247 143: 8(int) Load 18(gid) 248 144: 8(int) Load 18(gid) 249 145: 8(int) ISub 144 62 250 146: 137(ptr) AccessChain 134(gl_PrimitiveTriangleIndicesEXT) 145 251 147: 11(ivec3) Load 146 252 148: 137(ptr) AccessChain 134(gl_PrimitiveTriangleIndicesEXT) 143 253 Store 148 147 254 MemoryBarrier 62 63 255 ControlBarrier 64 64 63 256 Return 257 FunctionEnd 2586(testAdditionalBuiltins(): 2 Function None 3 259 7: Label 260 150(id): 149(ptr) Variable Function 261 154(viewIdx): 149(ptr) Variable Function 262 153: 43(int) Load 152(gl_DrawIDARB) 263 Store 150(id) 153 264 156: 43(int) Load 155(gl_ViewIndex) 265 Store 154(viewIdx) 156 266 Return 267 FunctionEnd 268