• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1spv.debuginfo.bufferref.glsl.frag
2// Module Version 10000
3// Generated by (magic number): 8000b
4// Id's are bound by 146
5
6                              Capability Shader
7                              Capability PhysicalStorageBufferAddressesEXT
8                              Extension  "SPV_KHR_non_semantic_info"
9                              Extension  "SPV_KHR_physical_storage_buffer"
10                              Extension  "SPV_KHR_relaxed_extended_instruction"
11                              Extension  "SPV_KHR_storage_buffer_storage_class"
12               1:             ExtInstImport  "NonSemantic.Shader.DebugInfo.100"
13               3:             ExtInstImport  "GLSL.std.450"
14                              MemoryModel PhysicalStorageBuffer64EXT GLSL450
15                              EntryPoint Fragment 14  "main" 82 135
16                              ExecutionMode 14 OriginUpperLeft
17               2:             String  "spv.debuginfo.bufferref.glsl.frag"
18               8:             String  "uint"
19              16:             String  "main"
20              19:             String  "// OpModuleProcessed auto-map-locations
21// OpModuleProcessed auto-map-bindings
22// OpModuleProcessed client vulkan100
23// OpModuleProcessed target-env vulkan1.0
24// OpModuleProcessed keep-uncalled
25// OpModuleProcessed entry-point main
26#line 1
27#version 450 core
28#extension GL_EXT_buffer_reference : enable
29
30layout(buffer_reference, std430) buffer MeshVertexPositions {
31  float data[];
32};
33
34struct Mesh {
35  MeshVertexPositions positions;
36};
37
38layout(set = 0, binding = 0) readonly buffer PerPass_meshes {
39  Mesh data[];
40} perPass_meshes;
41
42layout(location = 0) out vec4 out_fragColor;
43
44layout(location = 0) in flat uint tri_idx0;
45
46void main() {
47    Mesh meshData = perPass_meshes.data[tri_idx0];
48
49    vec3 vertex_pos0 = vec3(meshData.positions.data[3 * tri_idx0],
50                            meshData.positions.data[3 * tri_idx0 + 1],
51                            meshData.positions.data[3 * tri_idx0 + 2]);
52
53    out_fragColor = vec4(vertex_pos0, 1.0);
54}
55"
56              33:             String  "positions"
57              37:             String  "Mesh"
58              40:             String  "float"
59              46:             String  "data"
60              49:             String  "MeshVertexPositions"
61              55:             String  "meshData"
62              69:             String  "PerPass_meshes"
63              75:             String  "perPass_meshes"
64              77:             String  "int"
65              84:             String  "tri_idx0"
66             100:             String  "vertex_pos0"
67             137:             String  "out_fragColor"
68                              SourceExtension  "GL_EXT_buffer_reference"
69                              Name 14  "main"
70                              Name 31  "Mesh"
71                              MemberName 31(Mesh) 0  "positions"
72                              Name 44  "MeshVertexPositions"
73                              MemberName 44(MeshVertexPositions) 0  "data"
74                              Name 53  "meshData"
75                              Name 59  "Mesh"
76                              MemberName 59(Mesh) 0  "positions"
77                              Name 64  "PerPass_meshes"
78                              MemberName 64(PerPass_meshes) 0  "data"
79                              Name 73  "perPass_meshes"
80                              Name 82  "tri_idx0"
81                              Name 98  "vertex_pos0"
82                              Name 135  "out_fragColor"
83                              Decorate 42 ArrayStride 4
84                              MemberDecorate 44(MeshVertexPositions) 0 Offset 0
85                              Decorate 44(MeshVertexPositions) Block
86                              MemberDecorate 59(Mesh) 0 Offset 0
87                              Decorate 62 ArrayStride 8
88                              MemberDecorate 64(PerPass_meshes) 0 NonWritable
89                              MemberDecorate 64(PerPass_meshes) 0 Offset 0
90                              Decorate 64(PerPass_meshes) Block
91                              Decorate 73(perPass_meshes) DescriptorSet 0
92                              Decorate 73(perPass_meshes) Binding 0
93                              Decorate 82(tri_idx0) Flat
94                              Decorate 82(tri_idx0) Location 0
95                              Decorate 135(out_fragColor) Location 0
96                              Decorate 53(meshData) DecorationAliasedPointerEXT
97               4:             TypeVoid
98               5:             TypeFunction 4
99               7:             TypeInt 32 0
100              10:      7(int) Constant 32
101              11:      7(int) Constant 6
102              12:      7(int) Constant 0
103               9:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 2(DebugTypeBasic) 8 10 11 12
104              13:      7(int) Constant 3
105               6:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 8(DebugTypeFunction) 13 4
106              18:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 35(DebugSource) 2 19
107              20:      7(int) Constant 20
108              22:      7(int) Constant 1
109              23:      7(int) Constant 4
110              24:      7(int) Constant 2
111              21:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 1(DebugCompilationUnit) 22 23 18 24
112              17:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 20(DebugFunction) 16 6 18 20 12 21 16 13 20
113                              TypeForwardPointer 28 PhysicalStorageBufferEXT
114              29:      7(int) Constant 5349
115              30:           4 ExtInstWithForwardRefsKHR 1(NonSemantic.Shader.DebugInfo.100) 3 48 29 12
116        31(Mesh):             TypeStruct 28
117              34:      7(int) Constant 9
118              35:      7(int) Constant 23
119              32:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 11(DebugTypeMember) 33 30 18 34 35 12 12 13
120              38:      7(int) Constant 21
121              36:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 10(DebugTypeComposite) 37 22 18 38 12 21 37 12 13 32
122              39:             TypeFloat 32
123              41:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 2(DebugTypeBasic) 40 10 13 12
124              42:             TypeRuntimeArray 39(float)
125              43:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 5(DebugTypeArray) 41 12
12644(MeshVertexPositions):             TypeStruct 42
127              47:      7(int) Constant 5
128              45:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 11(DebugTypeMember) 46 43 18 47 34 12 12 13
129              48:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 10(DebugTypeComposite) 49 22 18 38 12 21 49 12 13 45
130              28:             TypePointer PhysicalStorageBufferEXT 44(MeshVertexPositions)
131              50:             TypePointer Function 31(Mesh)
132              51:      7(int) Constant 7
133              52:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 36 51 12
134              54:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 26(DebugLocalVariable) 55 36 18 38 12 17 23
135              57:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 31(DebugExpression)
136        59(Mesh):             TypeStruct 28(ptr)
137              60:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 11(DebugTypeMember) 33 30 18 34 35 12 12 13
138              61:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 10(DebugTypeComposite) 37 22 18 38 12 21 37 12 13 60
139              62:             TypeRuntimeArray 59(Mesh)
140              63:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 5(DebugTypeArray) 61 12
14164(PerPass_meshes):             TypeStruct 62
142              66:      7(int) Constant 13
143              67:      7(int) Constant 8
144              65:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 11(DebugTypeMember) 46 63 18 66 67 12 12 13
145              68:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 10(DebugTypeComposite) 69 22 18 38 12 21 69 12 13 65
146              70:             TypePointer StorageBuffer 64(PerPass_meshes)
147              71:      7(int) Constant 12
148              72:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 68 71 12
14973(perPass_meshes):     70(ptr) Variable StorageBuffer
150              74:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 18(DebugGlobalVariable) 75 68 18 38 12 21 75 73(perPass_meshes) 67
151              76:             TypeInt 32 1
152              78:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 2(DebugTypeBasic) 77 10 23 12
153              79:     76(int) Constant 0
154              80:             TypePointer Input 7(int)
155              81:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 9 22 12
156    82(tri_idx0):     80(ptr) Variable Input
157              83:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 18(DebugGlobalVariable) 84 9 18 38 12 21 84 82(tri_idx0) 67
158              86:             TypePointer StorageBuffer 59(Mesh)
159              87:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 61 71 12
160              91:             TypePointer Function 28(ptr)
161              92:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 30 51 12
162              94:             TypeVector 39(float) 3
163              95:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 6(DebugTypeVector) 41 13
164              96:             TypePointer Function 94(fvec3)
165              97:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 95 51 12
166              99:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 26(DebugLocalVariable) 100 95 18 35 12 17 23
167             107:             TypePointer PhysicalStorageBufferEXT 39(float)
168             108:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 41 29 12
169             113:      7(int) Constant 24
170             122:      7(int) Constant 25
171             131:             TypeVector 39(float) 4
172             132:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 6(DebugTypeVector) 41 23
173             133:             TypePointer Output 131(fvec4)
174             134:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 3(DebugTypePointer) 132 13 12
175135(out_fragColor):    133(ptr) Variable Output
176             138:      7(int) Constant 27
177             136:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 18(DebugGlobalVariable) 137 132 18 138 12 21 137 135(out_fragColor) 67
178             141:   39(float) Constant 1065353216
179        14(main):           4 Function None 5
180              15:             Label
181    53(meshData):     50(ptr) Variable Function
182 98(vertex_pos0):     96(ptr) Variable Function
183              26:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 23(DebugScope) 17
184              27:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 20 20 12 12
185              25:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 101(DebugFunctionDefinition) 17 14(main)
186              58:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 38 38 12 12
187              56:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 28(DebugDeclare) 54 53(meshData) 57
188              85:      7(int) Load 82(tri_idx0)
189              88:     86(ptr) AccessChain 73(perPass_meshes) 79 85
190              89:    59(Mesh) Load 88
191              90:     28(ptr) CompositeExtract 89 0
192              93:     91(ptr) AccessChain 53(meshData) 79
193                              Store 93 90
194             102:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 35 35 12 12
195             101:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 28(DebugDeclare) 99 98(vertex_pos0) 57
196             103:     91(ptr) AccessChain 53(meshData) 79
197             104:     28(ptr) Load 103
198             105:      7(int) Load 82(tri_idx0)
199             106:      7(int) IMul 13 105
200             109:    107(ptr) AccessChain 104 79 106
201             110:   39(float) Load 109 Aligned 4
202             112:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 113 113 12 12
203             111:     91(ptr) AccessChain 53(meshData) 79
204             114:     28(ptr) Load 111
205             115:      7(int) Load 82(tri_idx0)
206             116:      7(int) IMul 13 115
207             117:      7(int) IAdd 116 22
208             118:    107(ptr) AccessChain 114 79 117
209             119:   39(float) Load 118 Aligned 4
210             121:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 122 122 12 12
211             120:     91(ptr) AccessChain 53(meshData) 79
212             123:     28(ptr) Load 120
213             124:      7(int) Load 82(tri_idx0)
214             125:      7(int) IMul 13 124
215             126:      7(int) IAdd 125 24
216             127:    107(ptr) AccessChain 123 79 126
217             128:   39(float) Load 127 Aligned 4
218             129:   94(fvec3) CompositeConstruct 110 119 128
219             130:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 35 35 12 12
220                              Store 98(vertex_pos0) 129
221             140:           4 ExtInst 1(NonSemantic.Shader.DebugInfo.100) 103(DebugLine) 18 138 138 12 12
222             139:   94(fvec3) Load 98(vertex_pos0)
223             142:   39(float) CompositeExtract 139 0
224             143:   39(float) CompositeExtract 139 1
225             144:   39(float) CompositeExtract 139 2
226             145:  131(fvec4) CompositeConstruct 142 143 144 141
227                              Store 135(out_fragColor) 145
228                              Return
229                              FunctionEnd
230