c6e4619d5e0ed8529c3c560f047ecdde9a8b08e4
[platform/upstream/glslang.git] / Test / baseResults / hlsl.intrinsics.promote.outputs.frag.out
1 hlsl.intrinsics.promote.outputs.frag
2 Shader version: 450
3 gl_FragCoord origin is upper left
4 0:? Sequence
5 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float color})
6 0:20    Function Parameters: 
7 0:?     Sequence
8 0:37      clamp ( temp float)
9 0:37        fpos: direct index for structure ( uniform float)
10 0:37          'anon@0' (layout( row_major std140) uniform block{ uniform int i,  uniform uint u,  uniform float f,  uniform bool b,  uniform 2-component vector of int i2,  uniform 2-component vector of uint u2,  uniform 2-component vector of float f2,  uniform 2-component vector of bool b2,  uniform uint upos,  uniform float fpos})
11 0:37          Constant:
12 0:37            9 (const uint)
13 0:37        Constant:
14 0:37          0.000000
15 0:37        Constant:
16 0:37          1.000000
17 0:40      Sequence
18 0:40        move second child to first child ( temp uint)
19 0:40          'sizeQueryTemp' ( temp uint)
20 0:40          textureSize ( temp uint)
21 0:40            'g_tTex1df4' ( uniform texture1D)
22 0:40            Constant:
23 0:40              0 (const int)
24 0:40        move second child to first child ( temp int)
25 0:40          'WidthI' ( temp int)
26 0:40          Convert uint to int ( temp int)
27 0:40            'sizeQueryTemp' ( temp uint)
28 0:41      Sequence
29 0:41        move second child to first child ( temp uint)
30 0:41          'sizeQueryTemp' ( temp uint)
31 0:41          textureSize ( temp uint)
32 0:41            'g_tTex1df4' ( uniform texture1D)
33 0:41            Constant:
34 0:41              6 (const uint)
35 0:41        move second child to first child ( temp int)
36 0:41          'WidthI' ( temp int)
37 0:41          Convert uint to int ( temp int)
38 0:41            'sizeQueryTemp' ( temp uint)
39 0:41        move second child to first child ( temp uint)
40 0:41          'NumberOfLevelsU' ( temp uint)
41 0:41          textureQueryLevels ( temp uint)
42 0:41            'g_tTex1df4' ( uniform texture1D)
43 0:42      Sequence
44 0:42        move second child to first child ( temp uint)
45 0:42          'sizeQueryTemp' ( temp uint)
46 0:42          textureSize ( temp uint)
47 0:42            'g_tTex1df4' ( uniform texture1D)
48 0:42            Constant:
49 0:42              6 (const uint)
50 0:42        move second child to first child ( temp uint)
51 0:42          'WidthU' ( temp uint)
52 0:42          'sizeQueryTemp' ( temp uint)
53 0:42        move second child to first child ( temp int)
54 0:42          'NumberOfLevelsI' ( temp int)
55 0:42          Convert uint to int ( temp int)
56 0:42            textureQueryLevels ( temp uint)
57 0:42              'g_tTex1df4' ( uniform texture1D)
58 0:43      Sequence
59 0:43        move second child to first child ( temp uint)
60 0:43          'sizeQueryTemp' ( temp uint)
61 0:43          textureSize ( temp uint)
62 0:43            'g_tTex1df4' ( uniform texture1D)
63 0:43            Constant:
64 0:43              6 (const uint)
65 0:43        move second child to first child ( temp int)
66 0:43          'WidthI' ( temp int)
67 0:43          Convert uint to int ( temp int)
68 0:43            'sizeQueryTemp' ( temp uint)
69 0:43        move second child to first child ( temp int)
70 0:43          'NumberOfLevelsI' ( temp int)
71 0:43          Convert uint to int ( temp int)
72 0:43            textureQueryLevels ( temp uint)
73 0:43              'g_tTex1df4' ( uniform texture1D)
74 0:47      move second child to first child ( temp 4-component vector of float)
75 0:47        color: direct index for structure ( temp 4-component vector of float)
76 0:47          'ps_output' ( temp structure{ temp 4-component vector of float color})
77 0:47          Constant:
78 0:47            0 (const int)
79 0:47        Constant:
80 0:47          0.000000
81 0:47          0.000000
82 0:47          0.000000
83 0:47          0.000000
84 0:48      Branch: Return with expression
85 0:48        'ps_output' ( temp structure{ temp 4-component vector of float color})
86 0:20  Function Definition: main( ( temp void)
87 0:20    Function Parameters: 
88 0:?     Sequence
89 0:20      Sequence
90 0:20        move second child to first child ( temp 4-component vector of float)
91 0:?           'color' (layout( location=0) out 4-component vector of float)
92 0:20          color: direct index for structure ( temp 4-component vector of float)
93 0:20            Function Call: @main( ( temp structure{ temp 4-component vector of float color})
94 0:20            Constant:
95 0:20              0 (const int)
96 0:?   Linker Objects
97 0:?     'anon@0' (layout( row_major std140) uniform block{ uniform int i,  uniform uint u,  uniform float f,  uniform bool b,  uniform 2-component vector of int i2,  uniform 2-component vector of uint u2,  uniform 2-component vector of float f2,  uniform 2-component vector of bool b2,  uniform uint upos,  uniform float fpos})
98 0:?     'g_tTexbfs' (layout( r32f) uniform textureBuffer)
99 0:?     'g_tTex1df4' ( uniform texture1D)
100 0:?     'color' (layout( location=0) out 4-component vector of float)
101
102
103 Linked fragment stage:
104
105
106 Shader version: 450
107 gl_FragCoord origin is upper left
108 0:? Sequence
109 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float color})
110 0:20    Function Parameters: 
111 0:?     Sequence
112 0:37      clamp ( temp float)
113 0:37        fpos: direct index for structure ( uniform float)
114 0:37          'anon@0' (layout( row_major std140) uniform block{ uniform int i,  uniform uint u,  uniform float f,  uniform bool b,  uniform 2-component vector of int i2,  uniform 2-component vector of uint u2,  uniform 2-component vector of float f2,  uniform 2-component vector of bool b2,  uniform uint upos,  uniform float fpos})
115 0:37          Constant:
116 0:37            9 (const uint)
117 0:37        Constant:
118 0:37          0.000000
119 0:37        Constant:
120 0:37          1.000000
121 0:40      Sequence
122 0:40        move second child to first child ( temp uint)
123 0:40          'sizeQueryTemp' ( temp uint)
124 0:40          textureSize ( temp uint)
125 0:40            'g_tTex1df4' ( uniform texture1D)
126 0:40            Constant:
127 0:40              0 (const int)
128 0:40        move second child to first child ( temp int)
129 0:40          'WidthI' ( temp int)
130 0:40          Convert uint to int ( temp int)
131 0:40            'sizeQueryTemp' ( temp uint)
132 0:41      Sequence
133 0:41        move second child to first child ( temp uint)
134 0:41          'sizeQueryTemp' ( temp uint)
135 0:41          textureSize ( temp uint)
136 0:41            'g_tTex1df4' ( uniform texture1D)
137 0:41            Constant:
138 0:41              6 (const uint)
139 0:41        move second child to first child ( temp int)
140 0:41          'WidthI' ( temp int)
141 0:41          Convert uint to int ( temp int)
142 0:41            'sizeQueryTemp' ( temp uint)
143 0:41        move second child to first child ( temp uint)
144 0:41          'NumberOfLevelsU' ( temp uint)
145 0:41          textureQueryLevels ( temp uint)
146 0:41            'g_tTex1df4' ( uniform texture1D)
147 0:42      Sequence
148 0:42        move second child to first child ( temp uint)
149 0:42          'sizeQueryTemp' ( temp uint)
150 0:42          textureSize ( temp uint)
151 0:42            'g_tTex1df4' ( uniform texture1D)
152 0:42            Constant:
153 0:42              6 (const uint)
154 0:42        move second child to first child ( temp uint)
155 0:42          'WidthU' ( temp uint)
156 0:42          'sizeQueryTemp' ( temp uint)
157 0:42        move second child to first child ( temp int)
158 0:42          'NumberOfLevelsI' ( temp int)
159 0:42          Convert uint to int ( temp int)
160 0:42            textureQueryLevels ( temp uint)
161 0:42              'g_tTex1df4' ( uniform texture1D)
162 0:43      Sequence
163 0:43        move second child to first child ( temp uint)
164 0:43          'sizeQueryTemp' ( temp uint)
165 0:43          textureSize ( temp uint)
166 0:43            'g_tTex1df4' ( uniform texture1D)
167 0:43            Constant:
168 0:43              6 (const uint)
169 0:43        move second child to first child ( temp int)
170 0:43          'WidthI' ( temp int)
171 0:43          Convert uint to int ( temp int)
172 0:43            'sizeQueryTemp' ( temp uint)
173 0:43        move second child to first child ( temp int)
174 0:43          'NumberOfLevelsI' ( temp int)
175 0:43          Convert uint to int ( temp int)
176 0:43            textureQueryLevels ( temp uint)
177 0:43              'g_tTex1df4' ( uniform texture1D)
178 0:47      move second child to first child ( temp 4-component vector of float)
179 0:47        color: direct index for structure ( temp 4-component vector of float)
180 0:47          'ps_output' ( temp structure{ temp 4-component vector of float color})
181 0:47          Constant:
182 0:47            0 (const int)
183 0:47        Constant:
184 0:47          0.000000
185 0:47          0.000000
186 0:47          0.000000
187 0:47          0.000000
188 0:48      Branch: Return with expression
189 0:48        'ps_output' ( temp structure{ temp 4-component vector of float color})
190 0:20  Function Definition: main( ( temp void)
191 0:20    Function Parameters: 
192 0:?     Sequence
193 0:20      Sequence
194 0:20        move second child to first child ( temp 4-component vector of float)
195 0:?           'color' (layout( location=0) out 4-component vector of float)
196 0:20          color: direct index for structure ( temp 4-component vector of float)
197 0:20            Function Call: @main( ( temp structure{ temp 4-component vector of float color})
198 0:20            Constant:
199 0:20              0 (const int)
200 0:?   Linker Objects
201 0:?     'anon@0' (layout( row_major std140) uniform block{ uniform int i,  uniform uint u,  uniform float f,  uniform bool b,  uniform 2-component vector of int i2,  uniform 2-component vector of uint u2,  uniform 2-component vector of float f2,  uniform 2-component vector of bool b2,  uniform uint upos,  uniform float fpos})
202 0:?     'g_tTexbfs' (layout( r32f) uniform textureBuffer)
203 0:?     'g_tTex1df4' ( uniform texture1D)
204 0:?     'color' (layout( location=0) out 4-component vector of float)
205
206 // Module Version 10000
207 // Generated by (magic number): 80001
208 // Id's are bound by 80
209
210                               Capability Shader
211                               Capability Sampled1D
212                               Capability SampledBuffer
213                               Capability ImageQuery
214                1:             ExtInstImport  "GLSL.std.450"
215                               MemoryModel Logical GLSL450
216                               EntryPoint Fragment 4  "main" 74
217                               ExecutionMode 4 OriginUpperLeft
218                               Name 4  "main"
219                               Name 8  "PS_OUTPUT"
220                               MemberName 8(PS_OUTPUT) 0  "color"
221                               Name 10  "@main("
222                               Name 17  "$Global"
223                               MemberName 17($Global) 0  "i"
224                               MemberName 17($Global) 1  "u"
225                               MemberName 17($Global) 2  "f"
226                               MemberName 17($Global) 3  "b"
227                               MemberName 17($Global) 4  "i2"
228                               MemberName 17($Global) 5  "u2"
229                               MemberName 17($Global) 6  "f2"
230                               MemberName 17($Global) 7  "b2"
231                               MemberName 17($Global) 8  "upos"
232                               MemberName 17($Global) 9  "fpos"
233                               Name 19  ""
234                               Name 28  "sizeQueryTemp"
235                               Name 31  "g_tTex1df4"
236                               Name 36  "WidthI"
237                               Name 39  "sizeQueryTemp"
238                               Name 45  "NumberOfLevelsU"
239                               Name 48  "sizeQueryTemp"
240                               Name 51  "WidthU"
241                               Name 53  "NumberOfLevelsI"
242                               Name 57  "sizeQueryTemp"
243                               Name 66  "ps_output"
244                               Name 74  "color"
245                               Name 79  "g_tTexbfs"
246                               MemberDecorate 17($Global) 0 Offset 0
247                               MemberDecorate 17($Global) 1 Offset 4
248                               MemberDecorate 17($Global) 2 Offset 8
249                               MemberDecorate 17($Global) 3 Offset 12
250                               MemberDecorate 17($Global) 4 Offset 16
251                               MemberDecorate 17($Global) 5 Offset 24
252                               MemberDecorate 17($Global) 6 Offset 32
253                               MemberDecorate 17($Global) 7 Offset 40
254                               MemberDecorate 17($Global) 8 Offset 48
255                               MemberDecorate 17($Global) 9 Offset 52
256                               Decorate 17($Global) Block
257                               Decorate 19 DescriptorSet 0
258                               Decorate 31(g_tTex1df4) DescriptorSet 0
259                               Decorate 74(color) Location 0
260                               Decorate 79(g_tTexbfs) DescriptorSet 0
261                2:             TypeVoid
262                3:             TypeFunction 2
263                6:             TypeFloat 32
264                7:             TypeVector 6(float) 4
265     8(PS_OUTPUT):             TypeStruct 7(fvec4)
266                9:             TypeFunction 8(PS_OUTPUT)
267               12:             TypeInt 32 1
268               13:             TypeInt 32 0
269               14:             TypeVector 12(int) 2
270               15:             TypeVector 13(int) 2
271               16:             TypeVector 6(float) 2
272      17($Global):             TypeStruct 12(int) 13(int) 6(float) 13(int) 14(ivec2) 15(ivec2) 16(fvec2) 15(ivec2) 13(int) 6(float)
273               18:             TypePointer Uniform 17($Global)
274               19:     18(ptr) Variable Uniform
275               20:     12(int) Constant 9
276               21:             TypePointer Uniform 6(float)
277               24:    6(float) Constant 0
278               25:    6(float) Constant 1065353216
279               27:             TypePointer Function 13(int)
280               29:             TypeImage 6(float) 1D sampled format:Unknown
281               30:             TypePointer UniformConstant 29
282   31(g_tTex1df4):     30(ptr) Variable UniformConstant
283               33:     12(int) Constant 0
284               35:             TypePointer Function 12(int)
285               41:     13(int) Constant 6
286               65:             TypePointer Function 8(PS_OUTPUT)
287               67:    7(fvec4) ConstantComposite 24 24 24 24
288               68:             TypePointer Function 7(fvec4)
289               73:             TypePointer Output 7(fvec4)
290        74(color):     73(ptr) Variable Output
291               77:             TypeImage 6(float) Buffer sampled format:R32f
292               78:             TypePointer UniformConstant 77
293    79(g_tTexbfs):     78(ptr) Variable UniformConstant
294          4(main):           2 Function None 3
295                5:             Label
296               75:8(PS_OUTPUT) FunctionCall 10(@main()
297               76:    7(fvec4) CompositeExtract 75 0
298                               Store 74(color) 76
299                               Return
300                               FunctionEnd
301       10(@main():8(PS_OUTPUT) Function None 9
302               11:             Label
303 28(sizeQueryTemp):     27(ptr) Variable Function
304       36(WidthI):     35(ptr) Variable Function
305 39(sizeQueryTemp):     27(ptr) Variable Function
306 45(NumberOfLevelsU):     27(ptr) Variable Function
307 48(sizeQueryTemp):     27(ptr) Variable Function
308       51(WidthU):     27(ptr) Variable Function
309 53(NumberOfLevelsI):     35(ptr) Variable Function
310 57(sizeQueryTemp):     27(ptr) Variable Function
311    66(ps_output):     65(ptr) Variable Function
312               22:     21(ptr) AccessChain 19 20
313               23:    6(float) Load 22
314               26:    6(float) ExtInst 1(GLSL.std.450) 43(FClamp) 23 24 25
315               32:          29 Load 31(g_tTex1df4)
316               34:     13(int) ImageQuerySizeLod 32 33
317                               Store 28(sizeQueryTemp) 34
318               37:     13(int) Load 28(sizeQueryTemp)
319               38:     12(int) Bitcast 37
320                               Store 36(WidthI) 38
321               40:          29 Load 31(g_tTex1df4)
322               42:     13(int) ImageQuerySizeLod 40 41
323                               Store 39(sizeQueryTemp) 42
324               43:     13(int) Load 39(sizeQueryTemp)
325               44:     12(int) Bitcast 43
326                               Store 36(WidthI) 44
327               46:          29 Load 31(g_tTex1df4)
328               47:     13(int) ImageQueryLevels 46
329                               Store 45(NumberOfLevelsU) 47
330               49:          29 Load 31(g_tTex1df4)
331               50:     13(int) ImageQuerySizeLod 49 41
332                               Store 48(sizeQueryTemp) 50
333               52:     13(int) Load 48(sizeQueryTemp)
334                               Store 51(WidthU) 52
335               54:          29 Load 31(g_tTex1df4)
336               55:     13(int) ImageQueryLevels 54
337               56:     12(int) Bitcast 55
338                               Store 53(NumberOfLevelsI) 56
339               58:          29 Load 31(g_tTex1df4)
340               59:     13(int) ImageQuerySizeLod 58 41
341                               Store 57(sizeQueryTemp) 59
342               60:     13(int) Load 57(sizeQueryTemp)
343               61:     12(int) Bitcast 60
344                               Store 36(WidthI) 61
345               62:          29 Load 31(g_tTex1df4)
346               63:     13(int) ImageQueryLevels 62
347               64:     12(int) Bitcast 63
348                               Store 53(NumberOfLevelsI) 64
349               69:     68(ptr) AccessChain 66(ps_output) 33
350                               Store 69 67
351               70:8(PS_OUTPUT) Load 66(ps_output)
352                               ReturnValue 70
353                               FunctionEnd