blob: 6f5c5f8917ec338bc2814e2145e16554f81a97ff [file] [log] [blame]
; SPIR-V
; Version: 1.3
; Generator: Google Tint Compiler; 0
; Bound: 521
; Schema: 0
OpCapability Shader
%339 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Vertex %main "main" %tint_pointsize %tint_symbol %tint_symbol_2 %tint_symbol_3
OpName %tint_pointsize "tint_pointsize"
OpName %QuicksortObject "QuicksortObject"
OpMemberName %QuicksortObject 0 "numbers"
OpName %obj "obj"
OpName %x_GLF_FragCoord "x_GLF_FragCoord"
OpName %x_GLF_pos "x_GLF_pos"
OpName %buf0 "buf0"
OpMemberName %buf0 0 "resolution"
OpName %x_34 "x_34"
OpName %frag_color "frag_color"
OpName %gl_Position "gl_Position"
OpName %tint_symbol "tint_symbol"
OpName %tint_symbol_2 "tint_symbol_2"
OpName %tint_symbol_3 "tint_symbol_3"
OpName %main_1 "main_1"
OpName %x_90 "x_90"
OpName %x_91 "x_91"
OpName %x_92 "x_92"
OpName %x_93 "x_93"
OpName %x_94 "x_94"
OpName %x_95 "x_95"
OpName %x_96 "x_96"
OpName %x_97 "x_97"
OpName %x_98 "x_98"
OpName %x_99 "x_99"
OpName %x_100 "x_100"
OpName %x_101 "x_101"
OpName %x_102 "x_102"
OpName %x_103 "x_103"
OpName %x_104 "x_104"
OpName %x_105 "x_105"
OpName %x_106 "x_106"
OpName %i_2 "i_2"
OpName %uv "uv"
OpName %color "color"
OpName %main_out "main_out"
OpMemberName %main_out 0 "frag_color_1"
OpMemberName %main_out 1 "gl_Position"
OpName %tint_symbol_4 "tint_symbol_4"
OpName %tint_symbol_1 "tint_symbol_1"
OpName %main "main"
OpName %swap_i1_i1_ "swap_i1_i1_"
OpName %i "i"
OpName %j "j"
OpName %temp "temp"
OpName %performPartition_i1_i1_ "performPartition_i1_i1_"
OpName %l "l"
OpName %h "h"
OpName %pivot "pivot"
OpName %i_1 "i_1"
OpName %j_1 "j_1"
OpName %param "param"
OpName %param_1 "param_1"
OpName %param_2 "param_2"
OpName %param_3 "param_3"
OpName %quicksort_ "quicksort_"
OpName %l_1 "l_1"
OpName %h_1 "h_1"
OpName %top "top"
OpName %stack "stack"
OpName %p "p"
OpName %param_4 "param_4"
OpName %param_5 "param_5"
OpDecorate %tint_pointsize BuiltIn PointSize
OpMemberDecorate %QuicksortObject 0 Offset 0
OpDecorate %_arr_int_uint_10 ArrayStride 4
OpDecorate %buf0 Block
OpMemberDecorate %buf0 0 Offset 0
OpDecorate %x_34 NonWritable
OpDecorate %x_34 DescriptorSet 0
OpDecorate %x_34 Binding 0
OpDecorate %tint_symbol Location 0
OpDecorate %tint_symbol_2 Location 0
OpDecorate %tint_symbol_3 BuiltIn Position
OpMemberDecorate %main_out 0 Offset 0
OpMemberDecorate %main_out 1 Offset 16
%float = OpTypeFloat 32
%_ptr_Output_float = OpTypePointer Output %float
%4 = OpConstantNull %float
%tint_pointsize = OpVariable %_ptr_Output_float Output %4
%int = OpTypeInt 32 1
%uint = OpTypeInt 32 0
%uint_10 = OpConstant %uint 10
%_arr_int_uint_10 = OpTypeArray %int %uint_10
%QuicksortObject = OpTypeStruct %_arr_int_uint_10
%_ptr_Private_QuicksortObject = OpTypePointer Private %QuicksortObject
%12 = OpConstantNull %QuicksortObject
%obj = OpVariable %_ptr_Private_QuicksortObject Private %12
%v4float = OpTypeVector %float 4
%_ptr_Private_v4float = OpTypePointer Private %v4float
%16 = OpConstantNull %v4float
%x_GLF_FragCoord = OpVariable %_ptr_Private_v4float Private %16
%x_GLF_pos = OpVariable %_ptr_Private_v4float Private %16
%v2float = OpTypeVector %float 2
%buf0 = OpTypeStruct %v2float
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
%x_34 = OpVariable %_ptr_Uniform_buf0 Uniform
%frag_color = OpVariable %_ptr_Private_v4float Private %16
%gl_Position = OpVariable %_ptr_Private_v4float Private %16
%_ptr_Input_v4float = OpTypePointer Input %v4float
%tint_symbol = OpVariable %_ptr_Input_v4float Input
%_ptr_Output_v4float = OpTypePointer Output %v4float
%tint_symbol_2 = OpVariable %_ptr_Output_v4float Output %16
%tint_symbol_3 = OpVariable %_ptr_Output_v4float Output %16
%void = OpTypeVoid
%29 = OpTypeFunction %void
%_ptr_Function_int = OpTypePointer Function %int
%35 = OpConstantNull %int
%_ptr_Function__arr_int_uint_10 = OpTypePointer Function %_arr_int_uint_10
%50 = OpConstantNull %_arr_int_uint_10
%_ptr_Function_v2float = OpTypePointer Function %v2float
%57 = OpConstantNull %v2float
%v3float = OpTypeVector %float 3
%_ptr_Function_v3float = OpTypePointer Function %v3float
%61 = OpConstantNull %v3float
%float_1 = OpConstant %float 1
%float_0 = OpConstant %float 0
%65 = OpConstantComposite %v4float %float_1 %float_1 %float_0 %float_0
%float_128 = OpConstant %float 128
%68 = OpConstantComposite %v4float %float_128 %float_128 %float_1 %float_1
%int_0 = OpConstant %int 0
%int_10 = OpConstant %int 10
%bool = OpTypeBool
%uint_0 = OpConstant %uint 0
%_ptr_Private_int = OpTypePointer Private %int
%int_1 = OpConstant %int 1
%int_9 = OpConstant %int 9
%int_n1 = OpConstant %int -1
%_ptr_Uniform_v2float = OpTypePointer Uniform %v2float
%float_2 = OpConstant %float 2
%float_3 = OpConstant %float 3
%227 = OpConstantComposite %v3float %float_1 %float_2 %float_3
%_ptr_Function_float = OpTypePointer Function %float
%float_0_25 = OpConstant %float 0.25
%float_0_5 = OpConstant %float 0.5
%int_2 = OpConstant %int 2
%uint_1 = OpConstant %uint 1
%float_0_75 = OpConstant %float 0.75
%int_3 = OpConstant %int 3
%uint_2 = OpConstant %uint 2
%int_4 = OpConstant %int 4
%int_5 = OpConstant %int 5
%int_6 = OpConstant %int 6
%int_7 = OpConstant %int 7
%int_8 = OpConstant %int 8
%main_out = OpTypeStruct %v4float %v4float
%358 = OpTypeFunction %void %main_out
%373 = OpTypeFunction %void %_ptr_Function_int %_ptr_Function_int
%394 = OpTypeFunction %int %_ptr_Function_int %_ptr_Function_int
%main_1 = OpFunction %void None %29
%32 = OpLabel
%x_90 = OpVariable %_ptr_Function_int Function %35
%x_91 = OpVariable %_ptr_Function_int Function %35
%x_92 = OpVariable %_ptr_Function_int Function %35
%x_93 = OpVariable %_ptr_Function_int Function %35
%x_94 = OpVariable %_ptr_Function_int Function %35
%x_95 = OpVariable %_ptr_Function_int Function %35
%x_96 = OpVariable %_ptr_Function_int Function %35
%x_97 = OpVariable %_ptr_Function_int Function %35
%x_98 = OpVariable %_ptr_Function_int Function %35
%x_99 = OpVariable %_ptr_Function_int Function %35
%x_100 = OpVariable %_ptr_Function_int Function %35
%x_101 = OpVariable %_ptr_Function_int Function %35
%x_102 = OpVariable %_ptr_Function_int Function %35
%x_103 = OpVariable %_ptr_Function__arr_int_uint_10 Function %50
%x_104 = OpVariable %_ptr_Function_int Function %35
%x_105 = OpVariable %_ptr_Function_int Function %35
%x_106 = OpVariable %_ptr_Function_int Function %35
%i_2 = OpVariable %_ptr_Function_int Function %35
%uv = OpVariable %_ptr_Function_v2float Function %57
%color = OpVariable %_ptr_Function_v3float Function %61
%62 = OpLoad %v4float %x_GLF_pos
%66 = OpFAdd %v4float %62 %65
%69 = OpFMul %v4float %66 %68
OpStore %x_GLF_FragCoord %69
OpStore %i_2 %int_0
OpBranch %71
%71 = OpLabel
OpLoopMerge %72 %73 None
OpBranch %74
%74 = OpLabel
%75 = OpLoad %int %i_2
%77 = OpSLessThan %bool %75 %int_10
OpSelectionMerge %79 None
OpBranchConditional %77 %80 %81
%80 = OpLabel
OpBranch %79
%81 = OpLabel
OpBranch %72
%79 = OpLabel
%82 = OpLoad %int %i_2
%83 = OpLoad %int %i_2
%86 = OpAccessChain %_ptr_Private_int %obj %uint_0 %82
%87 = OpISub %int %int_10 %83
OpStore %86 %87
%88 = OpLoad %int %i_2
%89 = OpLoad %int %i_2
%90 = OpAccessChain %_ptr_Private_int %obj %uint_0 %89
%91 = OpLoad %int %90
%92 = OpLoad %int %i_2
%93 = OpAccessChain %_ptr_Private_int %obj %uint_0 %92
%94 = OpLoad %int %93
%95 = OpAccessChain %_ptr_Private_int %obj %uint_0 %88
%96 = OpIMul %int %91 %94
OpStore %95 %96
OpBranch %73
%73 = OpLabel
%97 = OpLoad %int %i_2
%99 = OpIAdd %int %97 %int_1
OpStore %i_2 %99
OpBranch %71
%72 = OpLabel
OpStore %x_100 %int_0
OpStore %x_101 %int_9
OpStore %x_102 %int_n1
%102 = OpLoad %int %x_102
%103 = OpIAdd %int %102 %int_1
OpStore %x_102 %103
%104 = OpLoad %int %x_100
%105 = OpAccessChain %_ptr_Function_int %x_103 %103
OpStore %105 %104
%106 = OpLoad %int %x_102
%107 = OpIAdd %int %106 %int_1
OpStore %x_102 %107
%108 = OpLoad %int %x_101
%109 = OpAccessChain %_ptr_Function_int %x_103 %107
OpStore %109 %108
OpBranch %110
%110 = OpLabel
OpLoopMerge %111 %112 None
OpBranch %113
%113 = OpLabel
%114 = OpLoad %int %x_102
%115 = OpSGreaterThanEqual %bool %114 %int_0
OpSelectionMerge %116 None
OpBranchConditional %115 %117 %118
%117 = OpLabel
OpBranch %116
%118 = OpLabel
OpBranch %111
%116 = OpLabel
%119 = OpLoad %int %x_102
%120 = OpISub %int %119 %int_1
OpStore %x_102 %120
%121 = OpAccessChain %_ptr_Function_int %x_103 %119
%122 = OpLoad %int %121
OpStore %x_101 %122
%123 = OpLoad %int %x_102
%124 = OpISub %int %123 %int_1
OpStore %x_102 %124
%125 = OpAccessChain %_ptr_Function_int %x_103 %123
%126 = OpLoad %int %125
OpStore %x_100 %126
%127 = OpLoad %int %x_100
OpStore %x_105 %127
%128 = OpLoad %int %x_101
OpStore %x_106 %128
%129 = OpLoad %int %x_106
%130 = OpAccessChain %_ptr_Private_int %obj %uint_0 %129
%131 = OpLoad %int %130
OpStore %x_92 %131
%132 = OpLoad %int %x_105
%133 = OpISub %int %132 %int_1
OpStore %x_93 %133
%134 = OpLoad %int %x_105
OpStore %x_94 %134
OpBranch %135
%135 = OpLabel
OpLoopMerge %136 %137 None
OpBranch %138
%138 = OpLabel
%139 = OpLoad %int %x_94
%140 = OpLoad %int %x_106
%141 = OpISub %int %140 %int_1
%142 = OpSLessThanEqual %bool %139 %141
OpSelectionMerge %143 None
OpBranchConditional %142 %144 %145
%144 = OpLabel
OpBranch %143
%145 = OpLabel
OpBranch %136
%143 = OpLabel
%146 = OpLoad %int %x_94
%147 = OpAccessChain %_ptr_Private_int %obj %uint_0 %146
%148 = OpLoad %int %147
%149 = OpLoad %int %x_92
%150 = OpSLessThanEqual %bool %148 %149
OpSelectionMerge %151 None
OpBranchConditional %150 %152 %151
%152 = OpLabel
%153 = OpLoad %int %x_93
%154 = OpIAdd %int %153 %int_1
OpStore %x_93 %154
%155 = OpLoad %int %x_93
OpStore %x_95 %155
%156 = OpLoad %int %x_94
OpStore %x_96 %156
%157 = OpLoad %int %x_95
%158 = OpAccessChain %_ptr_Private_int %obj %uint_0 %157
%159 = OpLoad %int %158
OpStore %x_91 %159
%160 = OpLoad %int %x_95
%161 = OpLoad %int %x_96
%162 = OpAccessChain %_ptr_Private_int %obj %uint_0 %161
%163 = OpLoad %int %162
%164 = OpAccessChain %_ptr_Private_int %obj %uint_0 %160
OpStore %164 %163
%165 = OpLoad %int %x_96
%166 = OpLoad %int %x_91
%167 = OpAccessChain %_ptr_Private_int %obj %uint_0 %165
OpStore %167 %166
OpBranch %151
%151 = OpLabel
OpBranch %137
%137 = OpLabel
%168 = OpLoad %int %x_94
%169 = OpIAdd %int %168 %int_1
OpStore %x_94 %169
OpBranch %135
%136 = OpLabel
%170 = OpLoad %int %x_93
%171 = OpIAdd %int %170 %int_1
OpStore %x_97 %171
%172 = OpLoad %int %x_106
OpStore %x_98 %172
%173 = OpLoad %int %x_97
%174 = OpAccessChain %_ptr_Private_int %obj %uint_0 %173
%175 = OpLoad %int %174
OpStore %x_90 %175
%176 = OpLoad %int %x_97
%177 = OpLoad %int %x_98
%178 = OpAccessChain %_ptr_Private_int %obj %uint_0 %177
%179 = OpLoad %int %178
%180 = OpAccessChain %_ptr_Private_int %obj %uint_0 %176
OpStore %180 %179
%181 = OpLoad %int %x_98
%182 = OpLoad %int %x_90
%183 = OpAccessChain %_ptr_Private_int %obj %uint_0 %181
OpStore %183 %182
%184 = OpLoad %int %x_93
%185 = OpIAdd %int %184 %int_1
OpStore %x_99 %185
%186 = OpLoad %int %x_99
OpStore %x_104 %186
%187 = OpLoad %int %x_104
%188 = OpLoad %int %x_100
%189 = OpISub %int %187 %int_1
%190 = OpSGreaterThan %bool %189 %188
OpSelectionMerge %191 None
OpBranchConditional %190 %192 %191
%192 = OpLabel
%193 = OpLoad %int %x_102
%194 = OpIAdd %int %193 %int_1
OpStore %x_102 %194
%195 = OpLoad %int %x_100
%196 = OpAccessChain %_ptr_Function_int %x_103 %194
OpStore %196 %195
%197 = OpLoad %int %x_102
%198 = OpIAdd %int %197 %int_1
OpStore %x_102 %198
%199 = OpLoad %int %x_104
%200 = OpAccessChain %_ptr_Function_int %x_103 %198
%201 = OpISub %int %199 %int_1
OpStore %200 %201
OpBranch %191
%191 = OpLabel
%202 = OpLoad %int %x_104
%203 = OpLoad %int %x_101
%204 = OpIAdd %int %202 %int_1
%205 = OpSLessThan %bool %204 %203
OpSelectionMerge %206 None
OpBranchConditional %205 %207 %206
%207 = OpLabel
%208 = OpLoad %int %x_102
%209 = OpIAdd %int %208 %int_1
OpStore %x_102 %209
%210 = OpLoad %int %x_104
%211 = OpAccessChain %_ptr_Function_int %x_103 %209
%212 = OpIAdd %int %210 %int_1
OpStore %211 %212
%213 = OpLoad %int %x_102
%214 = OpIAdd %int %213 %int_1
OpStore %x_102 %214
%215 = OpLoad %int %x_101
%216 = OpAccessChain %_ptr_Function_int %x_103 %214
OpStore %216 %215
OpBranch %206
%206 = OpLabel
OpBranch %112
%112 = OpLabel
OpBranch %110
%111 = OpLabel
%217 = OpLoad %v4float %x_GLF_FragCoord
%219 = OpAccessChain %_ptr_Uniform_v2float %x_34 %uint_0
%220 = OpLoad %v2float %219
%221 = OpCompositeExtract %float %217 0
%222 = OpCompositeExtract %float %217 1
%223 = OpCompositeConstruct %v2float %221 %222
%224 = OpFDiv %v2float %223 %220
OpStore %uv %224
OpStore %color %227
%228 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_0
%229 = OpLoad %int %228
%231 = OpAccessChain %_ptr_Function_float %color %uint_0
%232 = OpLoad %float %231
%233 = OpAccessChain %_ptr_Function_float %color %uint_0
%234 = OpConvertSToF %float %229
%235 = OpFAdd %float %232 %234
OpStore %233 %235
%236 = OpAccessChain %_ptr_Function_float %uv %uint_0
%237 = OpLoad %float %236
%239 = OpFOrdGreaterThan %bool %237 %float_0_25
OpSelectionMerge %240 None
OpBranchConditional %239 %241 %240
%241 = OpLabel
%242 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_1
%243 = OpLoad %int %242
%244 = OpAccessChain %_ptr_Function_float %color %uint_0
%245 = OpLoad %float %244
%246 = OpAccessChain %_ptr_Function_float %color %uint_0
%247 = OpConvertSToF %float %243
%248 = OpFAdd %float %245 %247
OpStore %246 %248
OpBranch %240
%240 = OpLabel
%249 = OpAccessChain %_ptr_Function_float %uv %uint_0
%250 = OpLoad %float %249
%252 = OpFOrdGreaterThan %bool %250 %float_0_5
OpSelectionMerge %253 None
OpBranchConditional %252 %254 %253
%254 = OpLabel
%256 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_2
%257 = OpLoad %int %256
%259 = OpAccessChain %_ptr_Function_float %color %uint_1
%260 = OpLoad %float %259
%261 = OpAccessChain %_ptr_Function_float %color %uint_1
%262 = OpConvertSToF %float %257
%263 = OpFAdd %float %260 %262
OpStore %261 %263
OpBranch %253
%253 = OpLabel
%264 = OpAccessChain %_ptr_Function_float %uv %uint_0
%265 = OpLoad %float %264
%267 = OpFOrdGreaterThan %bool %265 %float_0_75
OpSelectionMerge %268 None
OpBranchConditional %267 %269 %268
%269 = OpLabel
%271 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_3
%272 = OpLoad %int %271
%274 = OpAccessChain %_ptr_Function_float %color %uint_2
%275 = OpLoad %float %274
%276 = OpAccessChain %_ptr_Function_float %color %uint_2
%277 = OpConvertSToF %float %272
%278 = OpFAdd %float %275 %277
OpStore %276 %278
OpBranch %268
%268 = OpLabel
%280 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_4
%281 = OpLoad %int %280
%282 = OpAccessChain %_ptr_Function_float %color %uint_1
%283 = OpLoad %float %282
%284 = OpAccessChain %_ptr_Function_float %color %uint_1
%285 = OpConvertSToF %float %281
%286 = OpFAdd %float %283 %285
OpStore %284 %286
%287 = OpAccessChain %_ptr_Function_float %uv %uint_1
%288 = OpLoad %float %287
%289 = OpFOrdGreaterThan %bool %288 %float_0_25
OpSelectionMerge %290 None
OpBranchConditional %289 %291 %290
%291 = OpLabel
%293 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_5
%294 = OpLoad %int %293
%295 = OpAccessChain %_ptr_Function_float %color %uint_0
%296 = OpLoad %float %295
%297 = OpAccessChain %_ptr_Function_float %color %uint_0
%298 = OpConvertSToF %float %294
%299 = OpFAdd %float %296 %298
OpStore %297 %299
OpBranch %290
%290 = OpLabel
%300 = OpAccessChain %_ptr_Function_float %uv %uint_1
%301 = OpLoad %float %300
%302 = OpFOrdGreaterThan %bool %301 %float_0_5
OpSelectionMerge %303 None
OpBranchConditional %302 %304 %303
%304 = OpLabel
%306 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_6
%307 = OpLoad %int %306
%308 = OpAccessChain %_ptr_Function_float %color %uint_1
%309 = OpLoad %float %308
%310 = OpAccessChain %_ptr_Function_float %color %uint_1
%311 = OpConvertSToF %float %307
%312 = OpFAdd %float %309 %311
OpStore %310 %312
OpBranch %303
%303 = OpLabel
%313 = OpAccessChain %_ptr_Function_float %uv %uint_1
%314 = OpLoad %float %313
%315 = OpFOrdGreaterThan %bool %314 %float_0_75
OpSelectionMerge %316 None
OpBranchConditional %315 %317 %316
%317 = OpLabel
%319 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_7
%320 = OpLoad %int %319
%321 = OpAccessChain %_ptr_Function_float %color %uint_2
%322 = OpLoad %float %321
%323 = OpAccessChain %_ptr_Function_float %color %uint_2
%324 = OpConvertSToF %float %320
%325 = OpFAdd %float %322 %324
OpStore %323 %325
OpBranch %316
%316 = OpLabel
%327 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_8
%328 = OpLoad %int %327
%329 = OpAccessChain %_ptr_Function_float %color %uint_2
%330 = OpLoad %float %329
%331 = OpAccessChain %_ptr_Function_float %color %uint_2
%332 = OpConvertSToF %float %328
%333 = OpFAdd %float %330 %332
OpStore %331 %333
%334 = OpAccessChain %_ptr_Function_float %uv %uint_0
%335 = OpLoad %float %334
%336 = OpAccessChain %_ptr_Function_float %uv %uint_1
%337 = OpLoad %float %336
%340 = OpFSub %float %335 %337
%338 = OpExtInst %float %339 FAbs %340
%341 = OpFOrdLessThan %bool %338 %float_0_25
OpSelectionMerge %342 None
OpBranchConditional %341 %343 %342
%343 = OpLabel
%344 = OpAccessChain %_ptr_Private_int %obj %uint_0 %int_9
%345 = OpLoad %int %344
%346 = OpAccessChain %_ptr_Function_float %color %uint_0
%347 = OpLoad %float %346
%348 = OpAccessChain %_ptr_Function_float %color %uint_0
%349 = OpConvertSToF %float %345
%350 = OpFAdd %float %347 %349
OpStore %348 %350
OpBranch %342
%342 = OpLabel
%351 = OpLoad %v3float %color
%352 = OpExtInst %v3float %339 Normalize %351
%353 = OpCompositeExtract %float %352 0
%354 = OpCompositeExtract %float %352 1
%355 = OpCompositeExtract %float %352 2
%356 = OpCompositeConstruct %v4float %353 %354 %355 %float_1
OpStore %frag_color %356
%357 = OpLoad %v4float %x_GLF_pos
OpStore %gl_Position %357
OpReturn
OpFunctionEnd
%tint_symbol_4 = OpFunction %void None %358
%tint_symbol_1 = OpFunctionParameter %main_out
%362 = OpLabel
%363 = OpCompositeExtract %v4float %tint_symbol_1 0
OpStore %tint_symbol_2 %363
%364 = OpCompositeExtract %v4float %tint_symbol_1 1
OpStore %tint_symbol_3 %364
OpReturn
OpFunctionEnd
%main = OpFunction %void None %29
%366 = OpLabel
OpStore %tint_pointsize %float_1
%367 = OpLoad %v4float %tint_symbol
OpStore %x_GLF_pos %367
%368 = OpFunctionCall %void %main_1
%370 = OpLoad %v4float %frag_color
%371 = OpLoad %v4float %gl_Position
%372 = OpCompositeConstruct %main_out %370 %371
%369 = OpFunctionCall %void %tint_symbol_4 %372
OpReturn
OpFunctionEnd
%swap_i1_i1_ = OpFunction %void None %373
%i = OpFunctionParameter %_ptr_Function_int
%j = OpFunctionParameter %_ptr_Function_int
%377 = OpLabel
%temp = OpVariable %_ptr_Function_int Function %35
%380 = OpLoad %int %i
%381 = OpAccessChain %_ptr_Private_int %obj %uint_0 %380
%382 = OpLoad %int %381
OpStore %temp %382
%384 = OpLoad %int %i
%386 = OpLoad %int %j
%387 = OpAccessChain %_ptr_Private_int %obj %uint_0 %386
%388 = OpLoad %int %387
%389 = OpAccessChain %_ptr_Private_int %obj %uint_0 %384
OpStore %389 %388
%391 = OpLoad %int %j
%392 = OpLoad %int %temp
%393 = OpAccessChain %_ptr_Private_int %obj %uint_0 %391
OpStore %393 %392
OpReturn
OpFunctionEnd
%performPartition_i1_i1_ = OpFunction %int None %394
%l = OpFunctionParameter %_ptr_Function_int
%h = OpFunctionParameter %_ptr_Function_int
%398 = OpLabel
%pivot = OpVariable %_ptr_Function_int Function %35
%i_1 = OpVariable %_ptr_Function_int Function %35
%j_1 = OpVariable %_ptr_Function_int Function %35
%param = OpVariable %_ptr_Function_int Function %35
%param_1 = OpVariable %_ptr_Function_int Function %35
%param_2 = OpVariable %_ptr_Function_int Function %35
%param_3 = OpVariable %_ptr_Function_int Function %35
%407 = OpLoad %int %h
%408 = OpAccessChain %_ptr_Private_int %obj %uint_0 %407
%409 = OpLoad %int %408
OpStore %pivot %409
%411 = OpLoad %int %l
%412 = OpISub %int %411 %int_1
OpStore %i_1 %412
%414 = OpLoad %int %l
OpStore %j_1 %414
OpBranch %415
%415 = OpLabel
OpLoopMerge %416 %417 None
OpBranch %418
%418 = OpLabel
%419 = OpLoad %int %j_1
%421 = OpLoad %int %h
%422 = OpISub %int %421 %int_1
%423 = OpSLessThanEqual %bool %419 %422
OpSelectionMerge %424 None
OpBranchConditional %423 %425 %426
%425 = OpLabel
OpBranch %424
%426 = OpLabel
OpBranch %416
%424 = OpLabel
%427 = OpLoad %int %j_1
%428 = OpAccessChain %_ptr_Private_int %obj %uint_0 %427
%429 = OpLoad %int %428
%430 = OpLoad %int %pivot
%431 = OpSLessThanEqual %bool %429 %430
OpSelectionMerge %432 None
OpBranchConditional %431 %433 %432
%433 = OpLabel
%434 = OpLoad %int %i_1
%435 = OpIAdd %int %434 %int_1
OpStore %i_1 %435
%436 = OpLoad %int %i_1
OpStore %param %436
%437 = OpLoad %int %j_1
OpStore %param_1 %437
%438 = OpFunctionCall %void %swap_i1_i1_ %param %param_1
OpBranch %432
%432 = OpLabel
OpBranch %417
%417 = OpLabel
%441 = OpLoad %int %j_1
%442 = OpIAdd %int %441 %int_1
OpStore %j_1 %442
OpBranch %415
%416 = OpLabel
%443 = OpLoad %int %i_1
%444 = OpIAdd %int %443 %int_1
OpStore %param_2 %444
%446 = OpLoad %int %h
OpStore %param_3 %446
%447 = OpFunctionCall %void %swap_i1_i1_ %param_2 %param_3
%450 = OpLoad %int %i_1
%451 = OpIAdd %int %450 %int_1
OpReturnValue %451
OpFunctionEnd
%quicksort_ = OpFunction %void None %29
%453 = OpLabel
%l_1 = OpVariable %_ptr_Function_int Function %35
%h_1 = OpVariable %_ptr_Function_int Function %35
%top = OpVariable %_ptr_Function_int Function %35
%stack = OpVariable %_ptr_Function__arr_int_uint_10 Function %50
%p = OpVariable %_ptr_Function_int Function %35
%param_4 = OpVariable %_ptr_Function_int Function %35
%param_5 = OpVariable %_ptr_Function_int Function %35
OpStore %l_1 %int_0
OpStore %h_1 %int_9
OpStore %top %int_n1
%461 = OpLoad %int %top
%462 = OpIAdd %int %461 %int_1
OpStore %top %462
%463 = OpLoad %int %l_1
%464 = OpAccessChain %_ptr_Function_int %stack %462
OpStore %464 %463
%465 = OpLoad %int %top
%466 = OpIAdd %int %465 %int_1
OpStore %top %466
%467 = OpLoad %int %h_1
%468 = OpAccessChain %_ptr_Function_int %stack %466
OpStore %468 %467
OpBranch %469
%469 = OpLabel
OpLoopMerge %470 %471 None
OpBranch %472
%472 = OpLabel
%473 = OpLoad %int %top
%474 = OpSGreaterThanEqual %bool %473 %int_0
OpSelectionMerge %475 None
OpBranchConditional %474 %476 %477
%476 = OpLabel
OpBranch %475
%477 = OpLabel
OpBranch %470
%475 = OpLabel
%478 = OpLoad %int %top
%479 = OpISub %int %478 %int_1
OpStore %top %479
%480 = OpAccessChain %_ptr_Function_int %stack %478
%481 = OpLoad %int %480
OpStore %h_1 %481
%482 = OpLoad %int %top
%483 = OpISub %int %482 %int_1
OpStore %top %483
%484 = OpAccessChain %_ptr_Function_int %stack %482
%485 = OpLoad %int %484
OpStore %l_1 %485
%486 = OpLoad %int %l_1
OpStore %param_4 %486
%487 = OpLoad %int %h_1
OpStore %param_5 %487
%488 = OpFunctionCall %int %performPartition_i1_i1_ %param_4 %param_5
OpStore %p %488
%491 = OpLoad %int %p
%492 = OpLoad %int %l_1
%493 = OpISub %int %491 %int_1
%494 = OpSGreaterThan %bool %493 %492
OpSelectionMerge %495 None
OpBranchConditional %494 %496 %495
%496 = OpLabel
%497 = OpLoad %int %top
%498 = OpIAdd %int %497 %int_1
OpStore %top %498
%499 = OpLoad %int %l_1
%500 = OpAccessChain %_ptr_Function_int %stack %498
OpStore %500 %499
%501 = OpLoad %int %top
%502 = OpIAdd %int %501 %int_1
OpStore %top %502
%503 = OpLoad %int %p
%504 = OpAccessChain %_ptr_Function_int %stack %502
%505 = OpISub %int %503 %int_1
OpStore %504 %505
OpBranch %495
%495 = OpLabel
%506 = OpLoad %int %p
%507 = OpLoad %int %h_1
%508 = OpIAdd %int %506 %int_1
%509 = OpSLessThan %bool %508 %507
OpSelectionMerge %510 None
OpBranchConditional %509 %511 %510
%511 = OpLabel
%512 = OpLoad %int %top
%513 = OpIAdd %int %512 %int_1
OpStore %top %513
%514 = OpLoad %int %p
%515 = OpAccessChain %_ptr_Function_int %stack %513
%516 = OpIAdd %int %514 %int_1
OpStore %515 %516
%517 = OpLoad %int %top
%518 = OpIAdd %int %517 %int_1
OpStore %top %518
%519 = OpLoad %int %h_1
%520 = OpAccessChain %_ptr_Function_int %stack %518
OpStore %520 %519
OpBranch %510
%510 = OpLabel
OpBranch %471
%471 = OpLabel
OpBranch %469
%470 = OpLabel
OpReturn
OpFunctionEnd