forked from WebAssembly/binaryen
/
builtin-bitops-1.c.s
1742 lines (1719 loc) · 61.8 KB
/
builtin-bitops-1.c.s
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
.text
.file "/usr/local/google/home/jgravelle/code/wasm/waterfall/src/work/gcc/gcc/testsuite/gcc.c-torture/execute/builtin-bitops-1.c"
.section .text.my_ffs,"ax",@progbits
.hidden my_ffs
.globl my_ffs
.type my_ffs,@function
my_ffs: # @my_ffs
.param i32
.result i32
.local i32, i32, i32
# BB#0: # %entry
block
i32.eqz $push12=, $0
br_if 0, $pop12 # 0: down to label0
# BB#1: # %for.cond.preheader
i32.const $2=, 1
.LBB0_2: # %for.cond
# =>This Inner Loop Header: Depth=1
block
loop # label2:
copy_local $push9=, $2
tee_local $push8=, $3=, $pop9
i32.const $push7=, -1
i32.add $push6=, $pop8, $pop7
tee_local $push5=, $1=, $pop6
i32.const $push4=, 31
i32.gt_u $push0=, $pop5, $pop4
br_if 1, $pop0 # 1: down to label1
# BB#3: # %for.body
# in Loop: Header=BB0_2 Depth=1
i32.const $push11=, 1
i32.add $2=, $3, $pop11
i32.const $push10=, 1
i32.shl $push1=, $pop10, $1
i32.and $push2=, $pop1, $0
i32.eqz $push13=, $pop2
br_if 0, $pop13 # 0: up to label2
.LBB0_4: # %cleanup
end_loop
end_block # label1:
return $3
.LBB0_5:
end_block # label0:
i32.const $push3=, 0
# fallthrough-return: $pop3
.endfunc
.Lfunc_end0:
.size my_ffs, .Lfunc_end0-my_ffs
.section .text.my_ctz,"ax",@progbits
.hidden my_ctz
.globl my_ctz
.type my_ctz,@function
my_ctz: # @my_ctz
.param i32
.result i32
.local i32
# BB#0: # %entry
i32.const $1=, 0
.LBB1_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label4:
i32.const $push3=, 1
i32.shl $push0=, $pop3, $1
i32.and $push1=, $pop0, $0
br_if 1, $pop1 # 1: down to label3
# BB#2: # %for.inc
# in Loop: Header=BB1_1 Depth=1
i32.const $push7=, 1
i32.add $push6=, $1, $pop7
tee_local $push5=, $1=, $pop6
i32.const $push4=, 32
i32.lt_u $push2=, $pop5, $pop4
br_if 0, $pop2 # 0: up to label4
.LBB1_3: # %for.end
end_loop
end_block # label3:
copy_local $push8=, $1
# fallthrough-return: $pop8
.endfunc
.Lfunc_end1:
.size my_ctz, .Lfunc_end1-my_ctz
.section .text.my_clz,"ax",@progbits
.hidden my_clz
.globl my_clz
.type my_clz,@function
my_clz: # @my_clz
.param i32
.result i32
.local i32, i32
# BB#0: # %entry
i32.const $2=, 0
i32.const $1=, 31
.LBB2_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label6:
i32.const $push3=, 1
i32.shl $push0=, $pop3, $1
i32.and $push1=, $pop0, $0
br_if 1, $pop1 # 1: down to label5
# BB#2: # %for.inc
# in Loop: Header=BB2_1 Depth=1
i32.const $push8=, -1
i32.add $1=, $1, $pop8
i32.const $push7=, 1
i32.add $push6=, $2, $pop7
tee_local $push5=, $2=, $pop6
i32.const $push4=, 32
i32.lt_u $push2=, $pop5, $pop4
br_if 0, $pop2 # 0: up to label6
.LBB2_3: # %for.end
end_loop
end_block # label5:
copy_local $push9=, $2
# fallthrough-return: $pop9
.endfunc
.Lfunc_end2:
.size my_clz, .Lfunc_end2-my_clz
.section .text.my_clrsb,"ax",@progbits
.hidden my_clrsb
.globl my_clrsb
.type my_clrsb,@function
my_clrsb: # @my_clrsb
.param i32
.result i32
.local i32, i32, i32
# BB#0: # %entry
i32.const $push0=, 31
i32.shr_u $1=, $0, $pop0
i32.const $2=, 30
i32.const $3=, 1
.LBB3_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label8:
i32.shr_u $push1=, $0, $2
i32.const $push7=, 1
i32.and $push2=, $pop1, $pop7
i32.ne $push3=, $pop2, $1
br_if 1, $pop3 # 1: down to label7
# BB#2: # %for.inc
# in Loop: Header=BB3_1 Depth=1
i32.const $push12=, -1
i32.add $2=, $2, $pop12
i32.const $push11=, 1
i32.add $push10=, $3, $pop11
tee_local $push9=, $3=, $pop10
i32.const $push8=, 32
i32.lt_u $push4=, $pop9, $pop8
br_if 0, $pop4 # 0: up to label8
.LBB3_3: # %for.end
end_loop
end_block # label7:
i32.const $push5=, -1
i32.add $push6=, $3, $pop5
# fallthrough-return: $pop6
.endfunc
.Lfunc_end3:
.size my_clrsb, .Lfunc_end3-my_clrsb
.section .text.my_popcount,"ax",@progbits
.hidden my_popcount
.globl my_popcount
.type my_popcount,@function
my_popcount: # @my_popcount
.param i32
.result i32
.local i32, i32
# BB#0: # %entry
i32.const $1=, 0
i32.const $2=, 0
.LBB4_1: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label9:
i32.const $push9=, 1
i32.shl $push0=, $pop9, $2
i32.and $push1=, $pop0, $0
i32.const $push8=, 0
i32.ne $push2=, $pop1, $pop8
i32.add $1=, $pop2, $1
i32.const $push7=, 1
i32.add $push6=, $2, $pop7
tee_local $push5=, $2=, $pop6
i32.const $push4=, 32
i32.ne $push3=, $pop5, $pop4
br_if 0, $pop3 # 0: up to label9
# BB#2: # %for.end
end_loop
copy_local $push10=, $1
# fallthrough-return: $pop10
.endfunc
.Lfunc_end4:
.size my_popcount, .Lfunc_end4-my_popcount
.section .text.my_parity,"ax",@progbits
.hidden my_parity
.globl my_parity
.type my_parity,@function
my_parity: # @my_parity
.param i32
.result i32
.local i32, i32
# BB#0: # %entry
i32.const $1=, 0
i32.const $2=, 0
.LBB5_1: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label10:
i32.const $push11=, 1
i32.shl $push0=, $pop11, $2
i32.and $push1=, $pop0, $0
i32.const $push10=, 0
i32.ne $push2=, $pop1, $pop10
i32.add $1=, $pop2, $1
i32.const $push9=, 1
i32.add $push8=, $2, $pop9
tee_local $push7=, $2=, $pop8
i32.const $push6=, 32
i32.ne $push3=, $pop7, $pop6
br_if 0, $pop3 # 0: up to label10
# BB#2: # %for.end
end_loop
i32.const $push4=, 1
i32.and $push5=, $1, $pop4
# fallthrough-return: $pop5
.endfunc
.Lfunc_end5:
.size my_parity, .Lfunc_end5-my_parity
.section .text.my_ffsl,"ax",@progbits
.hidden my_ffsl
.globl my_ffsl
.type my_ffsl,@function
my_ffsl: # @my_ffsl
.param i32
.result i32
.local i32, i32, i32
# BB#0: # %entry
block
i32.eqz $push12=, $0
br_if 0, $pop12 # 0: down to label11
# BB#1: # %for.cond.preheader
i32.const $2=, 1
.LBB6_2: # %for.cond
# =>This Inner Loop Header: Depth=1
block
loop # label13:
copy_local $push9=, $2
tee_local $push8=, $3=, $pop9
i32.const $push7=, -1
i32.add $push6=, $pop8, $pop7
tee_local $push5=, $1=, $pop6
i32.const $push4=, 31
i32.gt_u $push0=, $pop5, $pop4
br_if 1, $pop0 # 1: down to label12
# BB#3: # %for.body
# in Loop: Header=BB6_2 Depth=1
i32.const $push11=, 1
i32.add $2=, $3, $pop11
i32.const $push10=, 1
i32.shl $push1=, $pop10, $1
i32.and $push2=, $pop1, $0
i32.eqz $push13=, $pop2
br_if 0, $pop13 # 0: up to label13
.LBB6_4: # %cleanup
end_loop
end_block # label12:
return $3
.LBB6_5:
end_block # label11:
i32.const $push3=, 0
# fallthrough-return: $pop3
.endfunc
.Lfunc_end6:
.size my_ffsl, .Lfunc_end6-my_ffsl
.section .text.my_ctzl,"ax",@progbits
.hidden my_ctzl
.globl my_ctzl
.type my_ctzl,@function
my_ctzl: # @my_ctzl
.param i32
.result i32
.local i32
# BB#0: # %entry
i32.const $1=, 0
.LBB7_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label15:
i32.const $push3=, 1
i32.shl $push0=, $pop3, $1
i32.and $push1=, $pop0, $0
br_if 1, $pop1 # 1: down to label14
# BB#2: # %for.inc
# in Loop: Header=BB7_1 Depth=1
i32.const $push7=, 1
i32.add $push6=, $1, $pop7
tee_local $push5=, $1=, $pop6
i32.const $push4=, 32
i32.lt_u $push2=, $pop5, $pop4
br_if 0, $pop2 # 0: up to label15
.LBB7_3: # %for.end
end_loop
end_block # label14:
copy_local $push8=, $1
# fallthrough-return: $pop8
.endfunc
.Lfunc_end7:
.size my_ctzl, .Lfunc_end7-my_ctzl
.section .text.my_clzl,"ax",@progbits
.hidden my_clzl
.globl my_clzl
.type my_clzl,@function
my_clzl: # @my_clzl
.param i32
.result i32
.local i32, i32
# BB#0: # %entry
i32.const $2=, 0
i32.const $1=, 31
.LBB8_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label17:
i32.const $push3=, 1
i32.shl $push0=, $pop3, $1
i32.and $push1=, $pop0, $0
br_if 1, $pop1 # 1: down to label16
# BB#2: # %for.inc
# in Loop: Header=BB8_1 Depth=1
i32.const $push8=, -1
i32.add $1=, $1, $pop8
i32.const $push7=, 1
i32.add $push6=, $2, $pop7
tee_local $push5=, $2=, $pop6
i32.const $push4=, 32
i32.lt_u $push2=, $pop5, $pop4
br_if 0, $pop2 # 0: up to label17
.LBB8_3: # %for.end
end_loop
end_block # label16:
copy_local $push9=, $2
# fallthrough-return: $pop9
.endfunc
.Lfunc_end8:
.size my_clzl, .Lfunc_end8-my_clzl
.section .text.my_clrsbl,"ax",@progbits
.hidden my_clrsbl
.globl my_clrsbl
.type my_clrsbl,@function
my_clrsbl: # @my_clrsbl
.param i32
.result i32
.local i32, i32, i32
# BB#0: # %entry
i32.const $push0=, 31
i32.shr_u $1=, $0, $pop0
i32.const $2=, 30
i32.const $3=, 1
.LBB9_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label19:
i32.shr_u $push1=, $0, $2
i32.const $push7=, 1
i32.and $push2=, $pop1, $pop7
i32.ne $push3=, $pop2, $1
br_if 1, $pop3 # 1: down to label18
# BB#2: # %for.inc
# in Loop: Header=BB9_1 Depth=1
i32.const $push12=, -1
i32.add $2=, $2, $pop12
i32.const $push11=, 1
i32.add $push10=, $3, $pop11
tee_local $push9=, $3=, $pop10
i32.const $push8=, 32
i32.lt_u $push4=, $pop9, $pop8
br_if 0, $pop4 # 0: up to label19
.LBB9_3: # %for.end
end_loop
end_block # label18:
i32.const $push5=, -1
i32.add $push6=, $3, $pop5
# fallthrough-return: $pop6
.endfunc
.Lfunc_end9:
.size my_clrsbl, .Lfunc_end9-my_clrsbl
.section .text.my_popcountl,"ax",@progbits
.hidden my_popcountl
.globl my_popcountl
.type my_popcountl,@function
my_popcountl: # @my_popcountl
.param i32
.result i32
.local i32, i32
# BB#0: # %entry
i32.const $1=, 0
i32.const $2=, 0
.LBB10_1: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label20:
i32.const $push9=, 1
i32.shl $push0=, $pop9, $2
i32.and $push1=, $pop0, $0
i32.const $push8=, 0
i32.ne $push2=, $pop1, $pop8
i32.add $1=, $pop2, $1
i32.const $push7=, 1
i32.add $push6=, $2, $pop7
tee_local $push5=, $2=, $pop6
i32.const $push4=, 32
i32.ne $push3=, $pop5, $pop4
br_if 0, $pop3 # 0: up to label20
# BB#2: # %for.end
end_loop
copy_local $push10=, $1
# fallthrough-return: $pop10
.endfunc
.Lfunc_end10:
.size my_popcountl, .Lfunc_end10-my_popcountl
.section .text.my_parityl,"ax",@progbits
.hidden my_parityl
.globl my_parityl
.type my_parityl,@function
my_parityl: # @my_parityl
.param i32
.result i32
.local i32, i32
# BB#0: # %entry
i32.const $1=, 0
i32.const $2=, 0
.LBB11_1: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label21:
i32.const $push11=, 1
i32.shl $push0=, $pop11, $2
i32.and $push1=, $pop0, $0
i32.const $push10=, 0
i32.ne $push2=, $pop1, $pop10
i32.add $1=, $pop2, $1
i32.const $push9=, 1
i32.add $push8=, $2, $pop9
tee_local $push7=, $2=, $pop8
i32.const $push6=, 32
i32.ne $push3=, $pop7, $pop6
br_if 0, $pop3 # 0: up to label21
# BB#2: # %for.end
end_loop
i32.const $push4=, 1
i32.and $push5=, $1, $pop4
# fallthrough-return: $pop5
.endfunc
.Lfunc_end11:
.size my_parityl, .Lfunc_end11-my_parityl
.section .text.my_ffsll,"ax",@progbits
.hidden my_ffsll
.globl my_ffsll
.type my_ffsll,@function
my_ffsll: # @my_ffsll
.param i64
.result i32
.local i64, i32, i64, i32
# BB#0: # %entry
block
i64.eqz $push1=, $0
br_if 0, $pop1 # 0: down to label22
# BB#1: # %for.cond.preheader
i64.const $3=, 0
i32.const $2=, 1
.LBB12_2: # %for.cond
# =>This Inner Loop Header: Depth=1
block
loop # label24:
copy_local $4=, $2
i64.const $push6=, 63
i64.gt_u $push2=, $3, $pop6
br_if 1, $pop2 # 1: down to label23
# BB#3: # %for.body
# in Loop: Header=BB12_2 Depth=1
i32.const $push9=, 1
i32.add $2=, $4, $pop9
i64.const $push8=, 1
i64.shl $1=, $pop8, $3
i64.const $push7=, 1
i64.add $push0=, $3, $pop7
copy_local $3=, $pop0
i64.and $push3=, $1, $0
i64.eqz $push4=, $pop3
br_if 0, $pop4 # 0: up to label24
.LBB12_4: # %cleanup
end_loop
end_block # label23:
return $4
.LBB12_5:
end_block # label22:
i32.const $push5=, 0
# fallthrough-return: $pop5
.endfunc
.Lfunc_end12:
.size my_ffsll, .Lfunc_end12-my_ffsll
.section .text.my_ctzll,"ax",@progbits
.hidden my_ctzll
.globl my_ctzll
.type my_ctzll,@function
my_ctzll: # @my_ctzll
.param i64
.result i32
.local i64, i32
# BB#0: # %entry
i32.const $2=, 0
i64.const $1=, 0
.LBB13_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label26:
i64.const $push5=, 1
i64.shl $push0=, $pop5, $1
i64.and $push1=, $pop0, $0
i64.const $push4=, 0
i64.ne $push2=, $pop1, $pop4
br_if 1, $pop2 # 1: down to label25
# BB#2: # %for.inc
# in Loop: Header=BB13_1 Depth=1
i32.const $push10=, 1
i32.add $2=, $2, $pop10
i64.const $push9=, 1
i64.add $push8=, $1, $pop9
tee_local $push7=, $1=, $pop8
i64.const $push6=, 64
i64.lt_u $push3=, $pop7, $pop6
br_if 0, $pop3 # 0: up to label26
.LBB13_3: # %for.end
end_loop
end_block # label25:
copy_local $push11=, $2
# fallthrough-return: $pop11
.endfunc
.Lfunc_end13:
.size my_ctzll, .Lfunc_end13-my_ctzll
.section .text.my_clzll,"ax",@progbits
.hidden my_clzll
.globl my_clzll
.type my_clzll,@function
my_clzll: # @my_clzll
.param i64
.result i32
.local i64, i64, i32
# BB#0: # %entry
i32.const $3=, 0
i64.const $1=, 63
i64.const $2=, 0
.LBB14_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label28:
i64.const $push5=, 1
i64.shl $push0=, $pop5, $1
i64.and $push1=, $pop0, $0
i64.const $push4=, 0
i64.ne $push2=, $pop1, $pop4
br_if 1, $pop2 # 1: down to label27
# BB#2: # %for.inc
# in Loop: Header=BB14_1 Depth=1
i64.const $push11=, -1
i64.add $1=, $1, $pop11
i32.const $push10=, 1
i32.add $3=, $3, $pop10
i64.const $push9=, 1
i64.add $push8=, $2, $pop9
tee_local $push7=, $2=, $pop8
i64.const $push6=, 64
i64.lt_u $push3=, $pop7, $pop6
br_if 0, $pop3 # 0: up to label28
.LBB14_3: # %for.end
end_loop
end_block # label27:
copy_local $push12=, $3
# fallthrough-return: $pop12
.endfunc
.Lfunc_end14:
.size my_clzll, .Lfunc_end14-my_clzll
.section .text.my_clrsbll,"ax",@progbits
.hidden my_clrsbll
.globl my_clrsbll
.type my_clrsbll,@function
my_clrsbll: # @my_clrsbll
.param i64
.result i32
.local i64, i64, i64, i32
# BB#0: # %entry
i64.const $push0=, 63
i64.shr_u $1=, $0, $pop0
i64.const $2=, 62
i64.const $3=, 1
i32.const $4=, 1
.LBB15_1: # %for.body
# =>This Inner Loop Header: Depth=1
block
loop # label30:
i64.shr_u $push1=, $0, $2
i64.const $push7=, 1
i64.and $push2=, $pop1, $pop7
i64.ne $push3=, $pop2, $1
br_if 1, $pop3 # 1: down to label29
# BB#2: # %for.inc
# in Loop: Header=BB15_1 Depth=1
i64.const $push13=, -1
i64.add $2=, $2, $pop13
i32.const $push12=, 1
i32.add $4=, $4, $pop12
i64.const $push11=, 1
i64.add $push10=, $3, $pop11
tee_local $push9=, $3=, $pop10
i64.const $push8=, 64
i64.lt_u $push4=, $pop9, $pop8
br_if 0, $pop4 # 0: up to label30
.LBB15_3: # %for.end
end_loop
end_block # label29:
i32.const $push5=, -1
i32.add $push6=, $4, $pop5
# fallthrough-return: $pop6
.endfunc
.Lfunc_end15:
.size my_clrsbll, .Lfunc_end15-my_clrsbll
.section .text.my_popcountll,"ax",@progbits
.hidden my_popcountll
.globl my_popcountll
.type my_popcountll,@function
my_popcountll: # @my_popcountll
.param i64
.result i32
.local i64, i32
# BB#0: # %entry
i32.const $2=, 0
i64.const $1=, 0
.LBB16_1: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label31:
i64.const $push9=, 1
i64.shl $push0=, $pop9, $1
i64.and $push1=, $pop0, $0
i64.const $push8=, 0
i64.ne $push2=, $pop1, $pop8
i32.add $2=, $pop2, $2
i64.const $push7=, 1
i64.add $push6=, $1, $pop7
tee_local $push5=, $1=, $pop6
i64.const $push4=, 64
i64.ne $push3=, $pop5, $pop4
br_if 0, $pop3 # 0: up to label31
# BB#2: # %for.end
end_loop
copy_local $push10=, $2
# fallthrough-return: $pop10
.endfunc
.Lfunc_end16:
.size my_popcountll, .Lfunc_end16-my_popcountll
.section .text.my_parityll,"ax",@progbits
.hidden my_parityll
.globl my_parityll
.type my_parityll,@function
my_parityll: # @my_parityll
.param i64
.result i32
.local i64, i32
# BB#0: # %entry
i32.const $2=, 0
i64.const $1=, 0
.LBB17_1: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label32:
i64.const $push11=, 1
i64.shl $push0=, $pop11, $1
i64.and $push1=, $pop0, $0
i64.const $push10=, 0
i64.ne $push2=, $pop1, $pop10
i32.add $2=, $pop2, $2
i64.const $push9=, 1
i64.add $push8=, $1, $pop9
tee_local $push7=, $1=, $pop8
i64.const $push6=, 64
i64.ne $push3=, $pop7, $pop6
br_if 0, $pop3 # 0: up to label32
# BB#2: # %for.end
end_loop
i32.const $push4=, 1
i32.and $push5=, $2, $pop4
# fallthrough-return: $pop5
.endfunc
.Lfunc_end17:
.size my_parityll, .Lfunc_end17-my_parityll
.section .text.main,"ax",@progbits
.hidden main
.globl main
.type main,@function
main: # @main
.result i32
.local i32, i32, i32, i32, i64, i32, i32, i64, i64, i64, i32
# BB#0: # %entry
i32.const $0=, 0
.LBB18_1: # %for.body
# =>This Loop Header: Depth=1
# Child Loop BB18_3 Depth 2
# Child Loop BB18_9 Depth 2
# Child Loop BB18_13 Depth 2
# Child Loop BB18_17 Depth 2
# Child Loop BB18_21 Depth 2
# Child Loop BB18_24 Depth 2
block
block
loop # label35:
i32.const $push208=, 2
i32.shl $push1=, $0, $pop208
i32.const $push207=, ints
i32.add $push206=, $pop1, $pop207
tee_local $push205=, $1=, $pop206
i32.load $push204=, 0($pop205)
tee_local $push203=, $10=, $pop204
i32.ctz $push202=, $pop203
tee_local $push201=, $2=, $pop202
i32.const $push200=, 1
i32.add $push2=, $pop201, $pop200
i32.const $push199=, 0
i32.select $6=, $pop2, $pop199, $10
i32.const $3=, 0
block
i32.eqz $push400=, $10
br_if 0, $pop400 # 0: down to label36
# BB#2: # %for.cond.i.preheader
# in Loop: Header=BB18_1 Depth=1
i32.const $5=, 0
.LBB18_3: # %for.cond.i
# Parent Loop BB18_1 Depth=1
# => This Inner Loop Header: Depth=2
block
loop # label38:
copy_local $push211=, $5
tee_local $push210=, $3=, $pop211
i32.const $push209=, 31
i32.gt_u $push3=, $pop210, $pop209
br_if 1, $pop3 # 1: down to label37
# BB#4: # %for.body.i
# in Loop: Header=BB18_3 Depth=2
i32.const $push213=, 1
i32.add $5=, $3, $pop213
i32.const $push212=, 1
i32.shl $push4=, $pop212, $3
i32.and $push5=, $pop4, $10
i32.eqz $push401=, $pop5
br_if 0, $pop401 # 0: up to label38
.LBB18_5: # %my_ffs.exit.loopexit
# in Loop: Header=BB18_1 Depth=1
end_loop
end_block # label37:
i32.const $push214=, 1
i32.add $3=, $3, $pop214
.LBB18_6: # %my_ffs.exit
# in Loop: Header=BB18_1 Depth=1
end_block # label36:
i32.ne $push6=, $6, $3
br_if 1, $pop6 # 1: down to label34
# BB#7: # %if.end
# in Loop: Header=BB18_1 Depth=1
block
i32.eqz $push402=, $10
br_if 0, $pop402 # 0: down to label39
# BB#8: # %land.lhs.true
# in Loop: Header=BB18_1 Depth=1
i32.clz $6=, $10
i32.const $5=, 0
i32.const $3=, 31
.LBB18_9: # %for.body.i816
# Parent Loop BB18_1 Depth=1
# => This Inner Loop Header: Depth=2
block
loop # label41:
i32.const $push215=, 1
i32.shl $push7=, $pop215, $3
i32.and $push8=, $pop7, $10
br_if 1, $pop8 # 1: down to label40
# BB#10: # %for.inc.i819
# in Loop: Header=BB18_9 Depth=2
i32.const $push220=, -1
i32.add $3=, $3, $pop220
i32.const $push219=, 1
i32.add $push218=, $5, $pop219
tee_local $push217=, $5=, $pop218
i32.const $push216=, 32
i32.lt_u $push9=, $pop217, $pop216
br_if 0, $pop9 # 0: up to label41
.LBB18_11: # %my_clz.exit
# in Loop: Header=BB18_1 Depth=1
end_loop
end_block # label40:
i32.ne $push10=, $6, $5
br_if 2, $pop10 # 2: down to label34
# BB#12: # %land.lhs.true13
# in Loop: Header=BB18_1 Depth=1
i32.const $3=, 0
.LBB18_13: # %for.body.i875
# Parent Loop BB18_1 Depth=1
# => This Inner Loop Header: Depth=2
block
loop # label43:
i32.const $push221=, 1
i32.shl $push11=, $pop221, $3
i32.and $push12=, $pop11, $10
br_if 1, $pop12 # 1: down to label42
# BB#14: # %for.inc.i878
# in Loop: Header=BB18_13 Depth=2
i32.const $push225=, 1
i32.add $push224=, $3, $pop225
tee_local $push223=, $3=, $pop224
i32.const $push222=, 32
i32.lt_u $push13=, $pop223, $pop222
br_if 0, $pop13 # 0: up to label43
.LBB18_15: # %my_ctz.exit
# in Loop: Header=BB18_1 Depth=1
end_loop
end_block # label42:
i32.ne $push14=, $2, $3
br_if 2, $pop14 # 2: down to label34
.LBB18_16: # %if.end19
# in Loop: Header=BB18_1 Depth=1
end_block # label39:
i32.call $2=, __builtin_clrsb@FUNCTION, $10
i32.load $push228=, 0($1)
tee_local $push227=, $3=, $pop228
i32.const $push226=, 31
i32.shr_u $6=, $pop227, $pop226
i32.const $5=, 1
i32.const $10=, 30
.LBB18_17: # %for.body.i948
# Parent Loop BB18_1 Depth=1
# => This Inner Loop Header: Depth=2
block
loop # label45:
i32.shr_u $push15=, $3, $10
i32.const $push229=, 1
i32.and $push16=, $pop15, $pop229
i32.ne $push17=, $pop16, $6
br_if 1, $pop17 # 1: down to label44
# BB#18: # %for.inc.i951
# in Loop: Header=BB18_17 Depth=2
i32.const $push234=, -1
i32.add $10=, $10, $pop234
i32.const $push233=, 1
i32.add $push232=, $5, $pop233
tee_local $push231=, $5=, $pop232
i32.const $push230=, 32
i32.lt_u $push18=, $pop231, $pop230
br_if 0, $pop18 # 0: up to label45
.LBB18_19: # %my_clrsb.exit
# in Loop: Header=BB18_1 Depth=1
end_loop
end_block # label44:
i32.const $push235=, -1
i32.add $push19=, $5, $pop235
i32.ne $push20=, $2, $pop19
br_if 1, $pop20 # 1: down to label34
# BB#20: # %for.body.i1030.preheader
# in Loop: Header=BB18_1 Depth=1
i32.const $5=, 0
i32.const $10=, 0
.LBB18_21: # %for.body.i1030
# Parent Loop BB18_1 Depth=1
# => This Inner Loop Header: Depth=2
loop # label46:
i32.const $push241=, 1
i32.shl $push21=, $pop241, $10
i32.and $push22=, $pop21, $3
i32.const $push240=, 0
i32.ne $push23=, $pop22, $pop240
i32.add $5=, $pop23, $5
i32.const $push239=, 1
i32.add $push238=, $10, $pop239
tee_local $push237=, $10=, $pop238
i32.const $push236=, 32
i32.ne $push24=, $pop237, $pop236
br_if 0, $pop24 # 0: up to label46
# BB#22: # %my_popcount.exit
# in Loop: Header=BB18_1 Depth=1
end_loop
i32.popcnt $push25=, $3
i32.ne $push26=, $pop25, $5
br_if 1, $pop26 # 1: down to label34
# BB#23: # %for.body.i1109.preheader
# in Loop: Header=BB18_1 Depth=1
i32.const $6=, 0
i32.const $10=, 0
.LBB18_24: # %for.body.i1109
# Parent Loop BB18_1 Depth=1
# => This Inner Loop Header: Depth=2
loop # label47:
i32.const $push247=, 1
i32.shl $push27=, $pop247, $10
i32.and $push28=, $pop27, $3
i32.const $push246=, 0
i32.ne $push29=, $pop28, $pop246
i32.add $6=, $pop29, $6
i32.const $push245=, 1
i32.add $push244=, $10, $pop245
tee_local $push243=, $10=, $pop244
i32.const $push242=, 32
i32.ne $push30=, $pop243, $pop242
br_if 0, $pop30 # 0: up to label47
# BB#25: # %my_parity.exit
# in Loop: Header=BB18_1 Depth=1
end_loop
i32.xor $push31=, $6, $5
i32.const $push248=, 1
i32.and $push32=, $pop31, $pop248
br_if 1, $pop32 # 1: down to label34
# BB#26: # %for.cond
# in Loop: Header=BB18_1 Depth=1
i32.const $push252=, 1
i32.add $push251=, $0, $pop252
tee_local $push250=, $0=, $pop251
i32.const $push249=, 13
i32.lt_u $push33=, $pop250, $pop249
br_if 0, $pop33 # 0: up to label35
# BB#27: # %for.body41.preheader
end_loop
i32.const $0=, 0
.LBB18_28: # %for.body41
# =>This Loop Header: Depth=1
# Child Loop BB18_30 Depth 2
# Child Loop BB18_36 Depth 2
# Child Loop BB18_40 Depth 2
# Child Loop BB18_44 Depth 2
# Child Loop BB18_48 Depth 2
# Child Loop BB18_51 Depth 2
loop # label48:
i32.const $push262=, 2
i32.shl $push34=, $0, $pop262
i32.const $push261=, longs
i32.add $push260=, $pop34, $pop261
tee_local $push259=, $1=, $pop260
i32.load $push258=, 0($pop259)
tee_local $push257=, $10=, $pop258
i32.ctz $push256=, $pop257
tee_local $push255=, $2=, $pop256
i32.const $push254=, 1
i32.add $push35=, $pop255, $pop254
i32.const $push253=, 0
i32.select $6=, $pop35, $pop253, $10
i32.const $3=, 0
block
i32.eqz $push403=, $10
br_if 0, $pop403 # 0: down to label49
# BB#29: # %for.cond.i1185.preheader
# in Loop: Header=BB18_28 Depth=1
i32.const $5=, 0
.LBB18_30: # %for.cond.i1185
# Parent Loop BB18_28 Depth=1
# => This Inner Loop Header: Depth=2
block
loop # label51:
copy_local $push265=, $5
tee_local $push264=, $3=, $pop265
i32.const $push263=, 31
i32.gt_u $push36=, $pop264, $pop263
br_if 1, $pop36 # 1: down to label50
# BB#31: # %for.body.i1189
# in Loop: Header=BB18_30 Depth=2
i32.const $push267=, 1
i32.add $5=, $3, $pop267
i32.const $push266=, 1
i32.shl $push37=, $pop266, $3
i32.and $push38=, $pop37, $10
i32.eqz $push404=, $pop38
br_if 0, $pop404 # 0: up to label51
.LBB18_32: # %my_ffsl.exit.loopexit
# in Loop: Header=BB18_28 Depth=1
end_loop
end_block # label50:
i32.const $push268=, 1
i32.add $3=, $3, $pop268
.LBB18_33: # %my_ffsl.exit
# in Loop: Header=BB18_28 Depth=1
end_block # label49:
i32.ne $push39=, $6, $3
br_if 1, $pop39 # 1: down to label34