• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1OpCapability Shader
2%1 = OpExtInstImport "GLSL.std.450"
3OpMemoryModel Logical GLSL450
4OpEntryPoint Fragment %_entrypoint_v "_entrypoint" %sk_FragColor %sk_Clockwise
5OpExecutionMode %_entrypoint_v OriginUpperLeft
6OpName %sk_FragColor "sk_FragColor"
7OpName %sk_Clockwise "sk_Clockwise"
8OpName %_UniformBuffer "_UniformBuffer"
9OpMemberName %_UniformBuffer 0 "testInputs"
10OpMemberName %_UniformBuffer 1 "colorGreen"
11OpMemberName %_UniformBuffer 2 "colorRed"
12OpName %_entrypoint_v "_entrypoint_v"
13OpName %main "main"
14OpName %intValues "intValues"
15OpName %expectedA "expectedA"
16OpName %clampLow "clampLow"
17OpName %expectedB "expectedB"
18OpName %clampHigh "clampHigh"
19OpDecorate %sk_FragColor RelaxedPrecision
20OpDecorate %sk_FragColor Location 0
21OpDecorate %sk_FragColor Index 0
22OpDecorate %sk_Clockwise BuiltIn FrontFacing
23OpMemberDecorate %_UniformBuffer 0 Offset 0
24OpMemberDecorate %_UniformBuffer 0 RelaxedPrecision
25OpMemberDecorate %_UniformBuffer 1 Offset 16
26OpMemberDecorate %_UniformBuffer 1 RelaxedPrecision
27OpMemberDecorate %_UniformBuffer 2 Offset 32
28OpMemberDecorate %_UniformBuffer 2 RelaxedPrecision
29OpDecorate %_UniformBuffer Block
30OpDecorate %10 Binding 0
31OpDecorate %10 DescriptorSet 0
32OpDecorate %33 RelaxedPrecision
33OpDecorate %35 RelaxedPrecision
34OpDecorate %36 RelaxedPrecision
35OpDecorate %38 RelaxedPrecision
36OpDecorate %40 RelaxedPrecision
37OpDecorate %42 RelaxedPrecision
38OpDecorate %212 RelaxedPrecision
39OpDecorate %215 RelaxedPrecision
40OpDecorate %216 RelaxedPrecision
41%float = OpTypeFloat 32
42%v4float = OpTypeVector %float 4
43%_ptr_Output_v4float = OpTypePointer Output %v4float
44%sk_FragColor = OpVariable %_ptr_Output_v4float Output
45%bool = OpTypeBool
46%_ptr_Input_bool = OpTypePointer Input %bool
47%sk_Clockwise = OpVariable %_ptr_Input_bool Input
48%_UniformBuffer = OpTypeStruct %v4float %v4float %v4float
49%_ptr_Uniform__UniformBuffer = OpTypePointer Uniform %_UniformBuffer
50%10 = OpVariable %_ptr_Uniform__UniformBuffer Uniform
51%void = OpTypeVoid
52%15 = OpTypeFunction %void
53%v2float = OpTypeVector %float 2
54%float_0 = OpConstant %float 0
55%19 = OpConstantComposite %v2float %float_0 %float_0
56%_ptr_Function_v2float = OpTypePointer Function %v2float
57%23 = OpTypeFunction %v4float %_ptr_Function_v2float
58%int = OpTypeInt 32 1
59%v4int = OpTypeVector %int 4
60%_ptr_Function_v4int = OpTypePointer Function %v4int
61%_ptr_Uniform_v4float = OpTypePointer Uniform %v4float
62%int_0 = OpConstant %int 0
63%float_100 = OpConstant %float 100
64%int_n100 = OpConstant %int -100
65%int_75 = OpConstant %int 75
66%int_100 = OpConstant %int 100
67%49 = OpConstantComposite %v4int %int_n100 %int_0 %int_75 %int_100
68%int_n200 = OpConstant %int -200
69%52 = OpConstantComposite %v4int %int_n100 %int_n200 %int_n200 %int_100
70%int_50 = OpConstant %int 50
71%int_225 = OpConstant %int 225
72%56 = OpConstantComposite %v4int %int_n100 %int_0 %int_50 %int_225
73%int_200 = OpConstant %int 200
74%int_300 = OpConstant %int 300
75%60 = OpConstantComposite %v4int %int_100 %int_200 %int_50 %int_300
76%false = OpConstantFalse %bool
77%v2int = OpTypeVector %int 2
78%v2bool = OpTypeVector %bool 2
79%v3int = OpTypeVector %int 3
80%v3bool = OpTypeVector %bool 3
81%v4bool = OpTypeVector %bool 4
82%115 = OpConstantComposite %v2int %int_n100 %int_0
83%123 = OpConstantComposite %v3int %int_n100 %int_0 %int_75
84%149 = OpConstantComposite %v2int %int_n100 %int_n200
85%150 = OpConstantComposite %v2int %int_100 %int_200
86%161 = OpConstantComposite %v3int %int_n100 %int_n200 %int_n200
87%162 = OpConstantComposite %v3int %int_100 %int_200 %int_50
88%193 = OpConstantComposite %v3int %int_n100 %int_0 %int_50
89%_ptr_Function_v4float = OpTypePointer Function %v4float
90%int_1 = OpConstant %int 1
91%int_2 = OpConstant %int 2
92%_entrypoint_v = OpFunction %void None %15
93%16 = OpLabel
94%20 = OpVariable %_ptr_Function_v2float Function
95OpStore %20 %19
96%22 = OpFunctionCall %v4float %main %20
97OpStore %sk_FragColor %22
98OpReturn
99OpFunctionEnd
100%main = OpFunction %v4float None %23
101%24 = OpFunctionParameter %_ptr_Function_v2float
102%25 = OpLabel
103%intValues = OpVariable %_ptr_Function_v4int Function
104%expectedA = OpVariable %_ptr_Function_v4int Function
105%clampLow = OpVariable %_ptr_Function_v4int Function
106%expectedB = OpVariable %_ptr_Function_v4int Function
107%clampHigh = OpVariable %_ptr_Function_v4int Function
108%205 = OpVariable %_ptr_Function_v4float Function
109%30 = OpAccessChain %_ptr_Uniform_v4float %10 %int_0
110%33 = OpLoad %v4float %30
111%35 = OpVectorTimesScalar %v4float %33 %float_100
112%36 = OpCompositeExtract %float %35 0
113%37 = OpConvertFToS %int %36
114%38 = OpCompositeExtract %float %35 1
115%39 = OpConvertFToS %int %38
116%40 = OpCompositeExtract %float %35 2
117%41 = OpConvertFToS %int %40
118%42 = OpCompositeExtract %float %35 3
119%43 = OpConvertFToS %int %42
120%44 = OpCompositeConstruct %v4int %37 %39 %41 %43
121OpStore %intValues %44
122OpStore %expectedA %49
123OpStore %clampLow %52
124OpStore %expectedB %56
125OpStore %clampHigh %60
126%63 = OpLoad %v4int %intValues
127%64 = OpCompositeExtract %int %63 0
128%62 = OpExtInst %int %1 SClamp %64 %int_n100 %int_100
129%65 = OpLoad %v4int %expectedA
130%66 = OpCompositeExtract %int %65 0
131%67 = OpIEqual %bool %62 %66
132OpSelectionMerge %69 None
133OpBranchConditional %67 %68 %69
134%68 = OpLabel
135%71 = OpLoad %v4int %intValues
136%72 = OpVectorShuffle %v2int %71 %71 0 1
137%74 = OpCompositeConstruct %v2int %int_n100 %int_n100
138%75 = OpCompositeConstruct %v2int %int_100 %int_100
139%70 = OpExtInst %v2int %1 SClamp %72 %74 %75
140%76 = OpLoad %v4int %expectedA
141%77 = OpVectorShuffle %v2int %76 %76 0 1
142%78 = OpIEqual %v2bool %70 %77
143%80 = OpAll %bool %78
144OpBranch %69
145%69 = OpLabel
146%81 = OpPhi %bool %false %25 %80 %68
147OpSelectionMerge %83 None
148OpBranchConditional %81 %82 %83
149%82 = OpLabel
150%85 = OpLoad %v4int %intValues
151%86 = OpVectorShuffle %v3int %85 %85 0 1 2
152%88 = OpCompositeConstruct %v3int %int_n100 %int_n100 %int_n100
153%89 = OpCompositeConstruct %v3int %int_100 %int_100 %int_100
154%84 = OpExtInst %v3int %1 SClamp %86 %88 %89
155%90 = OpLoad %v4int %expectedA
156%91 = OpVectorShuffle %v3int %90 %90 0 1 2
157%92 = OpIEqual %v3bool %84 %91
158%94 = OpAll %bool %92
159OpBranch %83
160%83 = OpLabel
161%95 = OpPhi %bool %false %69 %94 %82
162OpSelectionMerge %97 None
163OpBranchConditional %95 %96 %97
164%96 = OpLabel
165%99 = OpLoad %v4int %intValues
166%100 = OpCompositeConstruct %v4int %int_n100 %int_n100 %int_n100 %int_n100
167%101 = OpCompositeConstruct %v4int %int_100 %int_100 %int_100 %int_100
168%98 = OpExtInst %v4int %1 SClamp %99 %100 %101
169%102 = OpLoad %v4int %expectedA
170%103 = OpIEqual %v4bool %98 %102
171%105 = OpAll %bool %103
172OpBranch %97
173%97 = OpLabel
174%106 = OpPhi %bool %false %83 %105 %96
175OpSelectionMerge %108 None
176OpBranchConditional %106 %107 %108
177%107 = OpLabel
178%109 = OpLoad %v4int %expectedA
179%110 = OpCompositeExtract %int %109 0
180%111 = OpIEqual %bool %int_n100 %110
181OpBranch %108
182%108 = OpLabel
183%112 = OpPhi %bool %false %97 %111 %107
184OpSelectionMerge %114 None
185OpBranchConditional %112 %113 %114
186%113 = OpLabel
187%116 = OpLoad %v4int %expectedA
188%117 = OpVectorShuffle %v2int %116 %116 0 1
189%118 = OpIEqual %v2bool %115 %117
190%119 = OpAll %bool %118
191OpBranch %114
192%114 = OpLabel
193%120 = OpPhi %bool %false %108 %119 %113
194OpSelectionMerge %122 None
195OpBranchConditional %120 %121 %122
196%121 = OpLabel
197%124 = OpLoad %v4int %expectedA
198%125 = OpVectorShuffle %v3int %124 %124 0 1 2
199%126 = OpIEqual %v3bool %123 %125
200%127 = OpAll %bool %126
201OpBranch %122
202%122 = OpLabel
203%128 = OpPhi %bool %false %114 %127 %121
204OpSelectionMerge %130 None
205OpBranchConditional %128 %129 %130
206%129 = OpLabel
207%131 = OpLoad %v4int %expectedA
208%132 = OpIEqual %v4bool %49 %131
209%133 = OpAll %bool %132
210OpBranch %130
211%130 = OpLabel
212%134 = OpPhi %bool %false %122 %133 %129
213OpSelectionMerge %136 None
214OpBranchConditional %134 %135 %136
215%135 = OpLabel
216%138 = OpLoad %v4int %intValues
217%139 = OpCompositeExtract %int %138 0
218%137 = OpExtInst %int %1 SClamp %139 %int_n100 %int_100
219%140 = OpLoad %v4int %expectedB
220%141 = OpCompositeExtract %int %140 0
221%142 = OpIEqual %bool %137 %141
222OpBranch %136
223%136 = OpLabel
224%143 = OpPhi %bool %false %130 %142 %135
225OpSelectionMerge %145 None
226OpBranchConditional %143 %144 %145
227%144 = OpLabel
228%147 = OpLoad %v4int %intValues
229%148 = OpVectorShuffle %v2int %147 %147 0 1
230%146 = OpExtInst %v2int %1 SClamp %148 %149 %150
231%151 = OpLoad %v4int %expectedB
232%152 = OpVectorShuffle %v2int %151 %151 0 1
233%153 = OpIEqual %v2bool %146 %152
234%154 = OpAll %bool %153
235OpBranch %145
236%145 = OpLabel
237%155 = OpPhi %bool %false %136 %154 %144
238OpSelectionMerge %157 None
239OpBranchConditional %155 %156 %157
240%156 = OpLabel
241%159 = OpLoad %v4int %intValues
242%160 = OpVectorShuffle %v3int %159 %159 0 1 2
243%158 = OpExtInst %v3int %1 SClamp %160 %161 %162
244%163 = OpLoad %v4int %expectedB
245%164 = OpVectorShuffle %v3int %163 %163 0 1 2
246%165 = OpIEqual %v3bool %158 %164
247%166 = OpAll %bool %165
248OpBranch %157
249%157 = OpLabel
250%167 = OpPhi %bool %false %145 %166 %156
251OpSelectionMerge %169 None
252OpBranchConditional %167 %168 %169
253%168 = OpLabel
254%171 = OpLoad %v4int %intValues
255%172 = OpLoad %v4int %clampLow
256%173 = OpLoad %v4int %clampHigh
257%170 = OpExtInst %v4int %1 SClamp %171 %172 %173
258%174 = OpLoad %v4int %expectedB
259%175 = OpIEqual %v4bool %170 %174
260%176 = OpAll %bool %175
261OpBranch %169
262%169 = OpLabel
263%177 = OpPhi %bool %false %157 %176 %168
264OpSelectionMerge %179 None
265OpBranchConditional %177 %178 %179
266%178 = OpLabel
267%180 = OpLoad %v4int %expectedB
268%181 = OpCompositeExtract %int %180 0
269%182 = OpIEqual %bool %int_n100 %181
270OpBranch %179
271%179 = OpLabel
272%183 = OpPhi %bool %false %169 %182 %178
273OpSelectionMerge %185 None
274OpBranchConditional %183 %184 %185
275%184 = OpLabel
276%186 = OpLoad %v4int %expectedB
277%187 = OpVectorShuffle %v2int %186 %186 0 1
278%188 = OpIEqual %v2bool %115 %187
279%189 = OpAll %bool %188
280OpBranch %185
281%185 = OpLabel
282%190 = OpPhi %bool %false %179 %189 %184
283OpSelectionMerge %192 None
284OpBranchConditional %190 %191 %192
285%191 = OpLabel
286%194 = OpLoad %v4int %expectedB
287%195 = OpVectorShuffle %v3int %194 %194 0 1 2
288%196 = OpIEqual %v3bool %193 %195
289%197 = OpAll %bool %196
290OpBranch %192
291%192 = OpLabel
292%198 = OpPhi %bool %false %185 %197 %191
293OpSelectionMerge %200 None
294OpBranchConditional %198 %199 %200
295%199 = OpLabel
296%201 = OpLoad %v4int %expectedB
297%202 = OpIEqual %v4bool %56 %201
298%203 = OpAll %bool %202
299OpBranch %200
300%200 = OpLabel
301%204 = OpPhi %bool %false %192 %203 %199
302OpSelectionMerge %209 None
303OpBranchConditional %204 %207 %208
304%207 = OpLabel
305%210 = OpAccessChain %_ptr_Uniform_v4float %10 %int_1
306%212 = OpLoad %v4float %210
307OpStore %205 %212
308OpBranch %209
309%208 = OpLabel
310%213 = OpAccessChain %_ptr_Uniform_v4float %10 %int_2
311%215 = OpLoad %v4float %213
312OpStore %205 %215
313OpBranch %209
314%209 = OpLabel
315%216 = OpLoad %v4float %205
316OpReturnValue %216
317OpFunctionEnd
318