b64dc90b793dd5785d8df7bf60ac99d159bd2d9f
[platform/upstream/glslang.git] / Test / baseResults / spv.atomic.comp.out
1 spv.atomic.comp
2 // Module Version 10000
3 // Generated by (magic number): 80002
4 // Id's are bound by 74
5
6                               Capability Shader
7                               Capability AtomicStorage
8                1:             ExtInstImport  "GLSL.std.450"
9                               MemoryModel Logical GLSL450
10                               EntryPoint GLCompute 4  "main"
11                               ExecutionMode 4 LocalSize 1 1 1
12                               Source GLSL 450
13                               Name 4  "main"
14                               Name 10  "func(au1;"
15                               Name 9  "c"
16                               Name 12  "atoms("
17                               Name 20  "counter"
18                               Name 23  "val"
19                               Name 27  "countArr"
20                               Name 37  "origi"
21                               Name 39  "atomi"
22                               Name 42  "origu"
23                               Name 44  "atomu"
24                               Name 45  "value"
25                               Name 62  "dataSSB"
26                               MemberName 62(dataSSB) 0  "f"
27                               MemberName 62(dataSSB) 1  "n_frames_rendered"
28                               Name 64  "result"
29                               Name 71  "arrX"
30                               Name 72  "arrY"
31                               Name 73  "arrZ"
32                               Decorate 20(counter) Offset 0
33                               Decorate 20(counter) Binding 0
34                               Decorate 27(countArr) Offset 4
35                               Decorate 27(countArr) Binding 0
36                               MemberDecorate 62(dataSSB) 0 Restrict
37                               MemberDecorate 62(dataSSB) 0 Offset 0
38                               MemberDecorate 62(dataSSB) 1 Restrict
39                               MemberDecorate 62(dataSSB) 1 Offset 16
40                               Decorate 62(dataSSB) BufferBlock
41                               Decorate 64(result) DescriptorSet 0
42                               Decorate 64(result) Binding 0
43                2:             TypeVoid
44                3:             TypeFunction 2
45                6:             TypeInt 32 0
46                7:             TypePointer AtomicCounter 6(int)
47                8:             TypeFunction 6(int) 7(ptr)
48               14:      6(int) Constant 1
49               15:      6(int) Constant 0
50               19:      6(int) Constant 1024
51      20(counter):      7(ptr) Variable AtomicCounter
52               22:             TypePointer Function 6(int)
53               24:      6(int) Constant 4
54               25:             TypeArray 6(int) 24
55               26:             TypePointer AtomicCounter 25
56     27(countArr):     26(ptr) Variable AtomicCounter
57               28:             TypeInt 32 1
58               29:     28(int) Constant 2
59               33:     28(int) Constant 1
60               36:             TypePointer Function 28(int)
61               38:             TypePointer Workgroup 28(int)
62        39(atomi):     38(ptr) Variable Workgroup
63               40:     28(int) Constant 3
64               43:             TypePointer Workgroup 6(int)
65        44(atomu):     43(ptr) Variable Workgroup
66        45(value):     43(ptr) Variable Workgroup
67               48:      6(int) Constant 7
68               53:     28(int) Constant 7
69               57:      6(int) Constant 10
70               60:             TypeFloat 32
71               61:             TypeVector 28(int) 4
72      62(dataSSB):             TypeStruct 60(float) 61(ivec4)
73               63:             TypePointer Uniform 62(dataSSB)
74       64(result):     63(ptr) Variable Uniform
75               65:      6(int) Constant 2
76               66:             TypePointer Uniform 28(int)
77               69:             TypeArray 28(int) 14
78               70:             TypePointer Private 69
79         71(arrX):     70(ptr) Variable Private
80         72(arrY):     70(ptr) Variable Private
81         73(arrZ):     70(ptr) Variable Private
82          4(main):           2 Function None 3
83                5:             Label
84          23(val):     22(ptr) Variable Function
85                               MemoryBarrier 14 19
86               21:      6(int) FunctionCall 10(func(au1;) 20(counter)
87               30:      7(ptr) AccessChain 27(countArr) 29
88               31:      6(int) AtomicLoad 30 14 15
89                               Store 23(val) 31
90               32:      6(int) AtomicIDecrement 20(counter) 14 15
91               34:      6(int) ISub 32 33
92               35:      6(int) AtomicIIncrement 20(counter) 14 15
93                               Return
94                               FunctionEnd
95    10(func(au1;):      6(int) Function None 8
96             9(c):      7(ptr) FunctionParameter
97               11:             Label
98               16:      6(int) AtomicIIncrement 9(c) 14 15
99                               ReturnValue 16
100                               FunctionEnd
101       12(atoms():           2 Function None 3
102               13:             Label
103        37(origi):     36(ptr) Variable Function
104        42(origu):     22(ptr) Variable Function
105               41:     28(int) AtomicIAdd 39(atomi) 14 15 40
106                               Store 37(origi) 41
107               46:      6(int) Load 45(value)
108               47:      6(int) AtomicAnd 44(atomu) 14 15 46
109                               Store 42(origu) 47
110               49:      6(int) AtomicOr 44(atomu) 14 15 48
111                               Store 42(origu) 49
112               50:      6(int) AtomicXor 44(atomu) 14 15 48
113                               Store 42(origu) 50
114               51:      6(int) Load 45(value)
115               52:      6(int) AtomicUMin 44(atomu) 14 15 51
116                               Store 42(origu) 52
117               54:     28(int) AtomicSMax 39(atomi) 14 15 53
118                               Store 37(origi) 54
119               55:     28(int) Load 37(origi)
120               56:     28(int) AtomicExchange 39(atomi) 14 15 55
121                               Store 37(origi) 56
122               58:      6(int) Load 45(value)
123               59:      6(int) AtomicCompareExchange 44(atomu) 14 15 15 58 57
124                               Store 42(origu) 59
125               67:     66(ptr) AccessChain 64(result) 33 65
126               68:     28(int) AtomicIAdd 67 14 15 33
127                               Return
128                               FunctionEnd