mirror of
https://github.com/RPCS3/glslang.git
synced 2025-01-13 06:21:33 +00:00
d82c906378
Note: This required adding a new test mode to see the AST for vulkan tests. This also required reworking some deeper parts of type creation, regarding when storage qualification and constness is deduced bottom-up or dictated top-down.
165 lines
7.9 KiB
Plaintext
165 lines
7.9 KiB
Plaintext
spv.specConstantOperations.vert
|
|
Warning, version 450 is not yet complete; most version-specific features are present, but some are missing.
|
|
|
|
|
|
Linked vertex stage:
|
|
|
|
|
|
// Module Version 10000
|
|
// Generated by (magic number): 80001
|
|
// Id's are bound by 131
|
|
|
|
Capability Shader
|
|
1: ExtInstImport "GLSL.std.450"
|
|
MemoryModel Logical GLSL450
|
|
EntryPoint Vertex 4 "main"
|
|
Source GLSL 450
|
|
Name 4 "main"
|
|
Name 8 "non_const_array_size_from_spec_const("
|
|
Name 11 "i"
|
|
Name 27 "array"
|
|
Decorate 19 SpecId 201
|
|
Decorate 40 SpecId 200
|
|
Decorate 42 SpecId 202
|
|
Decorate 43 SpecId 203
|
|
2: TypeVoid
|
|
3: TypeFunction 2
|
|
6: TypeInt 32 1
|
|
7: TypeFunction 6(int)
|
|
10: TypePointer Function 6(int)
|
|
12: 6(int) Constant 0
|
|
19: 6(int) SpecConstant 10
|
|
20: 6(int) Constant 2
|
|
21: 6(int) SpecConstantOp 128 19 20
|
|
22: TypeBool
|
|
24: 6(int) SpecConstantOp 128 19 20
|
|
25: TypeArray 6(int) 24
|
|
26: TypePointer Function 25
|
|
29: 6(int) Constant 1023
|
|
32: 6(int) Constant 1
|
|
34: 6(int) SpecConstantOp 128 19 32
|
|
39: TypeFloat 32
|
|
40: 39(float) SpecConstant 1078530010
|
|
41: TypeInt 32 0
|
|
42: 41(int) SpecConstant 100
|
|
43: 6(int) SpecConstant 4294967286
|
|
44: 41(int) Constant 0
|
|
45: 22(bool) SpecConstantOp 171 19 44
|
|
46: 22(bool) SpecConstantOp 171 42 44
|
|
47: 6(int) SpecConstantOp 169 45 32 12
|
|
48: 41(int) Constant 1
|
|
49: 41(int) SpecConstantOp 169 45 48 44
|
|
50: 41(int) SpecConstantOp 128 43 44
|
|
51: 6(int) SpecConstantOp 128 42 44
|
|
52: 6(int) SpecConstantOp 126 19
|
|
53: 6(int) SpecConstantOp 200 19
|
|
54: 6(int) SpecConstantOp 128 19 20
|
|
55: 6(int) SpecConstantOp 128 19 20
|
|
56: 6(int) Constant 3
|
|
57: 6(int) SpecConstantOp 130 55 56
|
|
58: 6(int) Constant 4
|
|
59: 6(int) SpecConstantOp 130 54 58
|
|
60: 6(int) SpecConstantOp 132 43 20
|
|
61: 41(int) Constant 2
|
|
62: 41(int) SpecConstantOp 132 42 61
|
|
63: 6(int) Constant 5
|
|
64: 6(int) SpecConstantOp 135 60 63
|
|
65: 41(int) Constant 5
|
|
66: 41(int) SpecConstantOp 134 62 65
|
|
67: 6(int) SpecConstantOp 139 43 58
|
|
68: 41(int) Constant 4
|
|
69: 41(int) SpecConstantOp 137 42 68
|
|
70: 6(int) SpecConstantOp 132 43 56
|
|
71: 6(int) SpecConstantOp 135 70 63
|
|
72: 6(int) Constant 10
|
|
73: 6(int) SpecConstantOp 195 43 72
|
|
74: 6(int) Constant 20
|
|
75: 41(int) SpecConstantOp 194 42 74
|
|
76: 6(int) SpecConstantOp 196 43 32
|
|
77: 41(int) SpecConstantOp 196 42 20
|
|
78: 6(int) Constant 256
|
|
79: 6(int) SpecConstantOp 197 43 78
|
|
80: 41(int) Constant 512
|
|
81: 41(int) SpecConstantOp 198 42 80
|
|
82: 22(bool) SpecConstantOp 177 19 43
|
|
83: 22(bool) SpecConstantOp 170 42 42
|
|
84: 22(bool) SpecConstantOp 173 19 43
|
|
85: 6(int) Constant 30
|
|
86: TypeVector 6(int) 4
|
|
87: 86(ivec4) SpecConstantComposite 74 85 19 19
|
|
88: 41(int) Constant 4294967295
|
|
89: 41(int) Constant 4294967294
|
|
90: TypeVector 41(int) 4
|
|
91: 90(ivec4) SpecConstantComposite 42 42 88 89
|
|
92: TypeVector 22(bool) 4
|
|
93: 90(ivec4) ConstantComposite 44 44 44 44
|
|
94: 92(bvec4) SpecConstantOp 171 87 93
|
|
95: 92(bvec4) SpecConstantOp 171 91 93
|
|
96: 86(ivec4) ConstantComposite 12 12 12 12
|
|
97: 86(ivec4) ConstantComposite 32 32 32 32
|
|
98: 86(ivec4) SpecConstantOp 169 94 97 96
|
|
99: 90(ivec4) ConstantComposite 48 48 48 48
|
|
100: 90(ivec4) SpecConstantOp 169 94 99 93
|
|
101: 90(ivec4) SpecConstantOp 128 87 93
|
|
102: 86(ivec4) SpecConstantOp 128 91 93
|
|
103: 86(ivec4) SpecConstantOp 200 87
|
|
104: 86(ivec4) SpecConstantOp 126 87
|
|
105: 86(ivec4) ConstantComposite 20 20 20 20
|
|
106: 86(ivec4) SpecConstantOp 128 87 105
|
|
107: 86(ivec4) SpecConstantOp 128 87 105
|
|
108: 86(ivec4) ConstantComposite 56 56 56 56
|
|
109: 86(ivec4) SpecConstantOp 130 107 108
|
|
110: 86(ivec4) ConstantComposite 58 58 58 58
|
|
111: 86(ivec4) SpecConstantOp 130 109 110
|
|
112: 86(ivec4) SpecConstantOp 132 87 105
|
|
113: 86(ivec4) ConstantComposite 63 63 63 63
|
|
114: 86(ivec4) SpecConstantOp 135 112 113
|
|
115: 86(ivec4) SpecConstantOp 139 87 110
|
|
116: 86(ivec4) ConstantComposite 72 72 72 72
|
|
117: 86(ivec4) SpecConstantOp 195 87 116
|
|
118: 86(ivec4) SpecConstantOp 196 87 105
|
|
119: 6(int) Constant 1024
|
|
120: 86(ivec4) ConstantComposite 119 119 119 119
|
|
121: 86(ivec4) SpecConstantOp 197 87 120
|
|
122: 41(int) Constant 2048
|
|
123: 90(ivec4) ConstantComposite 122 122 122 122
|
|
124: 90(ivec4) SpecConstantOp 198 91 123
|
|
125: 6(int) SpecConstantOp 81 87 0
|
|
126: TypeVector 6(int) 2
|
|
127: 126(ivec2) SpecConstantOp 79 87 87 1(GLSL.std.450) 0
|
|
128: TypeVector 6(int) 3
|
|
129: 128(ivec3) SpecConstantOp 79 87 87 2 1(GLSL.std.450) 0
|
|
130: 86(ivec4) SpecConstantOp 79 87 87 1(GLSL.std.450) 2 0 3
|
|
4(main): 2 Function None 3
|
|
5: Label
|
|
Return
|
|
FunctionEnd
|
|
8(non_const_array_size_from_spec_const(): 6(int) Function None 7
|
|
9: Label
|
|
11(i): 10(ptr) Variable Function
|
|
27(array): 26(ptr) Variable Function
|
|
Store 11(i) 12
|
|
Branch 13
|
|
13: Label
|
|
LoopMerge 15 16 None
|
|
Branch 17
|
|
17: Label
|
|
18: 6(int) Load 11(i)
|
|
23: 22(bool) SLessThan 18 21
|
|
BranchConditional 23 14 15
|
|
14: Label
|
|
28: 6(int) Load 11(i)
|
|
30: 10(ptr) AccessChain 27(array) 28
|
|
Store 30 29
|
|
Branch 16
|
|
16: Label
|
|
31: 6(int) Load 11(i)
|
|
33: 6(int) IAdd 31 32
|
|
Store 11(i) 33
|
|
Branch 13
|
|
15: Label
|
|
35: 10(ptr) AccessChain 27(array) 34
|
|
36: 6(int) Load 35
|
|
ReturnValue 36
|
|
FunctionEnd
|