summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2016-04-04 10:07:01 -0700
committerAlon Zakai <alonzakai@gmail.com>2016-04-04 10:07:01 -0700
commite959e9b05a7e24b4bfff252ac9b959e9eecd35af (patch)
tree2d524696189e8f67bd1bdc94708a63d1bbae6768
parentc70c7513aa97229d0008aa22319ac44caad8205e (diff)
parenta76de5b15b946b677faca9b830071761cd969579 (diff)
downloadbinaryen-e959e9b05a7e24b4bfff252ac9b959e9eecd35af.tar.gz
binaryen-e959e9b05a7e24b4bfff252ac9b959e9eecd35af.tar.bz2
binaryen-e959e9b05a7e24b4bfff252ac9b959e9eecd35af.zip
Merge pull request #309 from WebAssembly/update-4893
Update to waterfall 4893
-rw-r--r--test/revision2
-rw-r--r--test/s2wasm_known_binaryen_shell_test_failures.txt1
-rw-r--r--test/torture-s/20041214-1.c.s48
-rw-r--r--test/torture-s/20050502-1.c.s4
-rw-r--r--test/torture-s/20051110-2.c.s137
-rw-r--r--test/torture-s/20090113-2.c.s2
-rw-r--r--test/torture-s/20090113-3.c.s188
-rw-r--r--test/torture-s/930111-1.c.s34
-rw-r--r--test/torture-s/930719-1.c.s4
-rw-r--r--test/torture-s/980716-1.c.s4
-rw-r--r--test/torture-s/pr17133.c.s2
-rw-r--r--test/torture-s/pr38051.c.s978
-rw-r--r--test/torture-s/pr42691.c.s4
-rw-r--r--test/torture-s/pr48809.c.s282
-rw-r--r--test/torture-s/pr57860.c.s4
-rw-r--r--test/torture-s/pr58640.c.s2
-rw-r--r--test/torture-s/pr59387.c.s2
-rw-r--r--test/torture-s/printf-1.c.s151
18 files changed, 1438 insertions, 411 deletions
diff --git a/test/revision b/test/revision
index 40236f0d8..074c6c29d 100644
--- a/test/revision
+++ b/test/revision
@@ -1 +1 @@
-4425
+4893
diff --git a/test/s2wasm_known_binaryen_shell_test_failures.txt b/test/s2wasm_known_binaryen_shell_test_failures.txt
index 799a100fe..e99dcdee1 100644
--- a/test/s2wasm_known_binaryen_shell_test_failures.txt
+++ b/test/s2wasm_known_binaryen_shell_test_failures.txt
@@ -29,6 +29,7 @@ memcpy-1.c.s.wast
mode-dependent-address.c.s.wast
multi-ix.c.s.wast
pr37573.c.s.wast
+pr38051.c.s.wast
pr43236.c.s.wast
pr44852.c.s.wast
pr44942.c.s.wast
diff --git a/test/torture-s/20041214-1.c.s b/test/torture-s/20041214-1.c.s
index e9fa0fc85..5b45c718e 100644
--- a/test/torture-s/20041214-1.c.s
+++ b/test/torture-s/20041214-1.c.s
@@ -43,20 +43,42 @@ g: # @g
.type f,@function
f: # @f
.param i32, i32, i32
- .local i32
+ .local i32, i32
# BB#0: # %entry
- i32.const $push1=, __stack_pointer
- i32.load $push2=, 0($pop1)
- i32.const $push3=, 16
- i32.sub $3=, $pop2, $pop3
i32.const $push4=, __stack_pointer
- i32.store $discard=, 0($pop4), $3
- i32.store $push0=, 12($3), $2
- i32.call $discard=, g@FUNCTION, $0, $1, $pop0
+ i32.load $push5=, 0($pop4)
+ i32.const $push6=, 16
+ i32.sub $4=, $pop5, $pop6
i32.const $push7=, __stack_pointer
- i32.const $push5=, 16
- i32.add $push6=, $3, $pop5
- i32.store $discard=, 0($pop7), $pop6
+ i32.store $discard=, 0($pop7), $4
+ i32.load8_u $3=, 0($1)
+ i32.store $discard=, 12($4), $2
+ block
+ i32.const $push11=, 0
+ i32.eq $push12=, $3, $pop11
+ br_if 0, $pop12 # 0: down to label3
+# BB#1: # %do_form_string.i.preheader
+ i32.load $2=, 12($4)
+ i32.const $push1=, 2
+ i32.add $1=, $1, $pop1
+.LBB1_2: # %do_form_string.i
+ # =>This Inner Loop Header: Depth=1
+ loop # label4:
+ i32.load $push0=, 0($2)
+ i32.call $discard=, strcpy@FUNCTION, $0, $pop0
+ i32.load8_u $3=, 0($1)
+ i32.const $push3=, 4
+ i32.add $2=, $2, $pop3
+ i32.const $push2=, 2
+ i32.add $1=, $1, $pop2
+ br_if 0, $3 # 0: up to label4
+.LBB1_3: # %g.exit
+ end_loop # label5:
+ end_block # label3:
+ i32.const $push10=, __stack_pointer
+ i32.const $push8=, 16
+ i32.add $push9=, $4, $pop8
+ i32.store $discard=, 0($pop10), $pop9
return
.endfunc
.Lfunc_end1:
@@ -88,7 +110,7 @@ main: # @main
i32.const $push13=, 22
i32.add $push14=, $2, $pop13
i32.call $push3=, strcmp@FUNCTION, $pop14, $1
- br_if 0, $pop3 # 0: down to label3
+ br_if 0, $pop3 # 0: down to label6
# BB#1: # %if.end
i32.const $push10=, __stack_pointer
i32.const $push8=, 32
@@ -96,7 +118,7 @@ main: # @main
i32.store $discard=, 0($pop10), $pop9
return $0
.LBB2_2: # %if.then
- end_block # label3:
+ end_block # label6:
call abort@FUNCTION
unreachable
.endfunc
diff --git a/test/torture-s/20050502-1.c.s b/test/torture-s/20050502-1.c.s
index 0c02d2e05..819858e2a 100644
--- a/test/torture-s/20050502-1.c.s
+++ b/test/torture-s/20050502-1.c.s
@@ -79,7 +79,7 @@ foo: # @foo
i32.const $push30=, 0
i32.eq $push31=, $pop10, $pop30
br_if 2, $pop31 # 2: down to label2
-.LBB2_5: # %while.body.backedge
+.LBB2_5: # %while.cond.backedge
# in Loop: Header=BB2_3 Depth=1
end_block # label3:
i32.add $push12=, $1, $5
@@ -94,7 +94,7 @@ foo: # @foo
i32.eq $push13=, $pop25, $pop24
i32.and $push14=, $pop13, $2
br_if 2, $pop14 # 2: down to label0
-# BB#6: # %while.body.backedge
+# BB#6: # %while.cond.backedge
# in Loop: Header=BB2_3 Depth=1
copy_local $5=, $6
i32.const $push29=, 34
diff --git a/test/torture-s/20051110-2.c.s b/test/torture-s/20051110-2.c.s
index 40d36aa5e..30fe7ebfc 100644
--- a/test/torture-s/20051110-2.c.s
+++ b/test/torture-s/20051110-2.c.s
@@ -8,46 +8,39 @@ add_unwind_adjustsp: # @add_unwind_adjustsp
.param i32
.local i32, i32, i32
# BB#0: # %entry
- i32.const $push13=, 0
i32.const $push0=, -516
i32.add $push1=, $0, $pop0
i32.const $push2=, 2
- i32.shr_s $push12=, $pop1, $pop2
- tee_local $push11=, $3=, $pop12
- i32.const $push10=, 127
- i32.and $push3=, $pop11, $pop10
- i32.store8 $discard=, bytes($pop13), $pop3
- block
- i32.const $push9=, 7
- i32.shr_u $push8=, $3, $pop9
- tee_local $push7=, $2=, $pop8
- i32.const $push20=, 0
- i32.eq $push21=, $pop7, $pop20
- br_if 0, $pop21 # 0: down to label0
-# BB#1: # %if.then.lr.ph
- i32.const $push14=, 0
- i32.load $push4=, flag($pop14)
- i32.eqz $1=, $pop4
- i32.const $0=, bytes
-.LBB0_2: # %if.then
+ i32.shr_s $0=, $pop1, $pop2
+ i32.const $2=, 0
+ i32.const $push6=, 0
+ i32.load $1=, flag($pop6)
+.LBB0_1: # %a
# =>This Inner Loop Header: Depth=1
- loop # label1:
- i32.const $push19=, 128
- i32.or $push5=, $3, $pop19
- i32.store8 $discard=, 0($0), $pop5
- i32.add $0=, $0, $1
- copy_local $push18=, $2
- tee_local $push17=, $2=, $pop18
- i32.const $push16=, 127
- i32.and $push6=, $pop17, $pop16
- i32.store8 $discard=, 0($0), $pop6
- copy_local $3=, $2
- i32.const $push15=, 7
- i32.shr_u $2=, $2, $pop15
- br_if 0, $2 # 0: up to label1
-.LBB0_3: # %do.end
- end_loop # label2:
- end_block # label0:
+ loop # label0:
+ copy_local $push9=, $0
+ tee_local $push8=, $3=, $pop9
+ i32.const $push7=, 7
+ i32.shr_u $0=, $pop8, $pop7
+ i32.const $push12=, 0
+ i32.eq $push13=, $0, $pop12
+ br_if 1, $pop13 # 1: down to label1
+# BB#2: # %if.then
+ # in Loop: Header=BB0_1 Depth=1
+ br_if 0, $1 # 0: up to label0
+# BB#3: # %if.end7.thread
+ # in Loop: Header=BB0_1 Depth=1
+ i32.const $push11=, 128
+ i32.or $push3=, $3, $pop11
+ i32.store8 $discard=, bytes($2), $pop3
+ i32.const $push10=, 1
+ i32.add $2=, $2, $pop10
+ br 0 # 0: up to label0
+.LBB0_4: # %do.end
+ end_loop # label1:
+ i32.const $push4=, 127
+ i32.and $push5=, $3, $pop4
+ i32.store8 $discard=, bytes($2), $pop5
return
.endfunc
.Lfunc_end0:
@@ -59,33 +52,57 @@ add_unwind_adjustsp: # @add_unwind_adjustsp
.type main,@function
main: # @main
.result i32
- .local i32, i32
-# BB#0: # %add_unwind_adjustsp.exit
+ .local i32, i32, i32, i32
+# BB#0: # %entry
+ i32.const $1=, 0
i32.const $push12=, 0
i32.load $0=, flag($pop12)
- i32.const $push11=, 0
- i32.const $push2=, 136
- i32.store8 $1=, bytes($pop11), $pop2
- i32.eqz $push1=, $0
- i32.const $push3=, 7
- i32.store8 $0=, bytes($pop1), $pop3
+ i32.const $2=, 904
+.LBB1_1: # %a.i
+ # =>This Inner Loop Header: Depth=1
+ loop # label2:
+ copy_local $push15=, $2
+ tee_local $push14=, $3=, $pop15
+ i32.const $push13=, 7
+ i32.shr_u $2=, $pop14, $pop13
+ i32.const $push20=, 0
+ i32.eq $push21=, $2, $pop20
+ br_if 1, $pop21 # 1: down to label3
+# BB#2: # %if.then.i
+ # in Loop: Header=BB1_1 Depth=1
+ br_if 0, $0 # 0: up to label2
+# BB#3: # %if.end7.thread.i
+ # in Loop: Header=BB1_1 Depth=1
+ i32.const $push17=, 128
+ i32.or $push0=, $3, $pop17
+ i32.store8 $discard=, bytes($1), $pop0
+ i32.const $push16=, 1
+ i32.add $1=, $1, $pop16
+ br 0 # 0: up to label2
+.LBB1_4: # %add_unwind_adjustsp.exit
+ end_loop # label3:
+ i32.const $push2=, 127
+ i32.and $push3=, $3, $pop2
+ i32.store8 $discard=, bytes($1), $pop3
block
- i32.const $push10=, 0
- i32.load8_u $push4=, bytes($pop10)
- i32.ne $push5=, $1, $pop4
- br_if 0, $pop5 # 0: down to label3
-# BB#1: # %add_unwind_adjustsp.exit
- i32.const $push13=, 0
- i32.load8_u $push0=, bytes+1($pop13)
- i32.const $push6=, 255
- i32.and $push7=, $pop0, $pop6
- i32.ne $push8=, $pop7, $0
- br_if 0, $pop8 # 0: down to label3
-# BB#2: # %if.end
- i32.const $push9=, 0
- return $pop9
-.LBB1_3: # %if.then
- end_block # label3:
+ i32.const $push18=, 0
+ i32.load8_u $push4=, bytes($pop18)
+ i32.const $push5=, 136
+ i32.ne $push6=, $pop4, $pop5
+ br_if 0, $pop6 # 0: down to label4
+# BB#5: # %add_unwind_adjustsp.exit
+ i32.const $push19=, 0
+ i32.load8_u $push1=, bytes+1($pop19)
+ i32.const $push7=, 255
+ i32.and $push8=, $pop1, $pop7
+ i32.const $push9=, 7
+ i32.ne $push10=, $pop8, $pop9
+ br_if 0, $pop10 # 0: down to label4
+# BB#6: # %if.end
+ i32.const $push11=, 0
+ return $pop11
+.LBB1_7: # %if.then
+ end_block # label4:
call abort@FUNCTION
unreachable
.endfunc
diff --git a/test/torture-s/20090113-2.c.s b/test/torture-s/20090113-2.c.s
index fe4dfbdb2..8db40e8cf 100644
--- a/test/torture-s/20090113-2.c.s
+++ b/test/torture-s/20090113-2.c.s
@@ -129,7 +129,7 @@ foobar: # @foobar
i32.const $push22=, 1
i32.add $push1=, $0, $pop22
i32.store $0=, 0($2):p2align=3, $pop1
-.LBB1_6: # %while.cond7.outer.i
+.LBB1_6: # %while.cond5.i
# Parent Loop BB1_1 Depth=1
# => This Loop Header: Depth=2
# Child Loop BB1_8 Depth 3
diff --git a/test/torture-s/20090113-3.c.s b/test/torture-s/20090113-3.c.s
index 5f8aca4e0..9011e5c50 100644
--- a/test/torture-s/20090113-3.c.s
+++ b/test/torture-s/20090113-3.c.s
@@ -58,18 +58,21 @@ foobar: # @foobar
.param i32
.local i32, i32, i32, i32, i32
# BB#0: # %entry
- i32.const $push31=, __stack_pointer
- i32.load $push32=, 0($pop31)
- i32.const $push33=, 32
- i32.sub $5=, $pop32, $pop33
- i32.const $push34=, __stack_pointer
- i32.store $discard=, 0($pop34), $5
- i32.const $push38=, 16
- i32.add $push39=, $5, $pop38
- i32.const $push40=, 12
- i32.add $push41=, $5, $pop40
- call bmp_iter_set_init@FUNCTION, $pop39, $0, $pop41
- i32.load $2=, 24($5):p2align=3
+ i32.const $push37=, __stack_pointer
+ i32.load $push38=, 0($pop37)
+ i32.const $push39=, 32
+ i32.sub $5=, $pop38, $pop39
+ i32.const $push40=, __stack_pointer
+ i32.store $discard=, 0($pop40), $5
+ i32.const $push44=, 16
+ i32.add $push45=, $5, $pop44
+ i32.const $push46=, 12
+ i32.add $push47=, $5, $pop46
+ call bmp_iter_set_init@FUNCTION, $pop45, $0, $pop47
+ i32.const $push48=, 16
+ i32.add $push49=, $5, $pop48
+ i32.const $push4=, 8
+ i32.add $2=, $pop49, $pop4
i32.load $1=, 16($5):p2align=3
i32.load $0=, 28($5)
.LBB1_1: # %for.cond
@@ -77,127 +80,138 @@ foobar: # @foobar
# Child Loop BB1_3 Depth 2
# Child Loop BB1_6 Depth 2
# Child Loop BB1_8 Depth 3
- # Child Loop BB1_12 Depth 2
+ # Child Loop BB1_13 Depth 2
loop # label0:
block
block
- i32.const $push48=, 0
- i32.eq $push49=, $0, $pop48
- br_if 0, $pop49 # 0: down to label3
+ i32.const $push58=, 0
+ i32.eq $push59=, $0, $pop58
+ br_if 0, $pop59 # 0: down to label3
# BB#2: # %while.cond.preheader.i
# in Loop: Header=BB1_1 Depth=1
- i32.const $push12=, 1
- i32.and $push2=, $0, $pop12
- br_if 1, $pop2 # 1: down to label2
+ i32.const $push14=, 1
+ i32.and $push1=, $0, $pop14
+ br_if 1, $pop1 # 1: down to label2
.LBB1_3: # %while.body.i
# Parent Loop BB1_1 Depth=1
# => This Inner Loop Header: Depth=2
loop # label4:
- i32.const $push14=, 1
- i32.shr_u $0=, $0, $pop14
- i32.const $push13=, 1
- i32.and $push3=, $0, $pop13
- i32.const $push50=, 0
- i32.eq $push51=, $pop3, $pop50
- br_if 0, $pop51 # 0: up to label4
-# BB#4: # %while.cond.return.loopexit61_crit_edge.i
+ i32.const $push16=, 1
+ i32.shr_u $0=, $0, $pop16
+ i32.const $push15=, 1
+ i32.and $push2=, $0, $pop15
+ i32.const $push60=, 0
+ i32.eq $push61=, $pop2, $pop60
+ br_if 0, $pop61 # 0: up to label4
+# BB#4: # %while.cond.return.loopexit62_crit_edge.i
# in Loop: Header=BB1_1 Depth=1
end_loop # label5:
- i32.const $push46=, 16
- i32.add $push47=, $5, $pop46
- i32.const $push28=, 12
- i32.add $push4=, $pop47, $pop28
- i32.store $discard=, 0($pop4), $0
+ i32.const $push56=, 16
+ i32.add $push57=, $5, $pop56
+ i32.const $push34=, 12
+ i32.add $push3=, $pop57, $pop34
+ i32.store $discard=, 0($pop3), $0
br 1 # 1: down to label2
.LBB1_5: # %if.end.i
# in Loop: Header=BB1_1 Depth=1
end_block # label3:
- i32.const $push15=, 1
- i32.add $2=, $2, $pop15
-.LBB1_6: # %while.cond7.i.outer
+ i32.load $push5=, 0($2):p2align=3
+ i32.const $push17=, 1
+ i32.add $0=, $pop5, $pop17
+.LBB1_6: # %while.body6.i
# Parent Loop BB1_1 Depth=1
# => This Loop Header: Depth=2
# Child Loop BB1_8 Depth 3
loop # label6:
block
- i32.const $push16=, 2
- i32.eq $push5=, $2, $pop16
- br_if 0, $pop5 # 0: down to label8
+ i32.const $push18=, 2
+ i32.eq $push6=, $0, $pop18
+ br_if 0, $pop6 # 0: down to label8
# BB#7: # %while.body9.i.preheader
# in Loop: Header=BB1_6 Depth=2
- i32.const $push18=, 2
- i32.shl $push6=, $2, $pop18
- i32.add $push7=, $1, $pop6
- i32.const $push17=, 12
- i32.add $3=, $pop7, $pop17
+ i32.const $push20=, 2
+ i32.shl $push7=, $0, $pop20
+ i32.add $push8=, $1, $pop7
+ i32.const $push19=, 12
+ i32.add $3=, $pop8, $pop19
.LBB1_8: # %while.body9.i
# Parent Loop BB1_1 Depth=1
# Parent Loop BB1_6 Depth=2
# => This Inner Loop Header: Depth=3
loop # label9:
- i32.const $push42=, 16
- i32.add $push43=, $5, $pop42
- i32.const $push21=, 12
- i32.add $push20=, $pop43, $pop21
- tee_local $push19=, $4=, $pop20
- i32.load $push0=, 0($3)
- i32.store $0=, 0($pop19), $pop0
- br_if 4, $0 # 4: down to label7
+ i32.load $push22=, 0($3)
+ tee_local $push21=, $4=, $pop22
+ br_if 4, $pop21 # 4: down to label7
# BB#9: # %if.end26.i
# in Loop: Header=BB1_8 Depth=3
- i32.const $push27=, 1
- i32.add $2=, $2, $pop27
- i32.const $push26=, 4
- i32.add $3=, $3, $pop26
- i32.const $push25=, 2
- i32.ne $push11=, $2, $pop25
- br_if 0, $pop11 # 0: up to label9
-.LBB1_10: # %while.end30.i
+ i32.const $push31=, 1
+ i32.add $0=, $0, $pop31
+ i32.const $push30=, 4
+ i32.add $3=, $3, $pop30
+ i32.const $push29=, 2
+ i32.ne $push12=, $0, $pop29
+ br_if 0, $pop12 # 0: up to label9
+# BB#10: # %while.end30.i.loopexit
# in Loop: Header=BB1_6 Depth=2
end_loop # label10:
+ i32.const $push50=, 16
+ i32.add $push51=, $5, $pop50
+ i32.const $push33=, 12
+ i32.add $push13=, $pop51, $pop33
+ i32.const $push32=, 0
+ i32.store $discard=, 0($pop13), $pop32
+.LBB1_11: # %while.end30.i
+ # in Loop: Header=BB1_6 Depth=2
end_block # label8:
i32.load $1=, 0($1)
- i32.const $2=, 0
+ i32.const $0=, 0
br_if 0, $1 # 0: up to label6
br 4 # 4: down to label1
-.LBB1_11: # %while.cond16.preheader.i
+.LBB1_12: # %while.cond16.preheader.i
# in Loop: Header=BB1_1 Depth=1
end_loop # label7:
- i32.const $push22=, 1
- i32.and $push8=, $0, $pop22
- br_if 0, $pop8 # 0: down to label2
-.LBB1_12: # %while.body21.i
+ i32.store $discard=, 0($2):p2align=3, $0
+ i32.const $push52=, 16
+ i32.add $push53=, $5, $pop52
+ i32.const $push26=, 12
+ i32.add $push25=, $pop53, $pop26
+ tee_local $push24=, $3=, $pop25
+ i32.store $0=, 0($pop24), $4
+ i32.const $push23=, 1
+ i32.and $push9=, $0, $pop23
+ br_if 0, $pop9 # 0: down to label2
+.LBB1_13: # %while.body21.i
# Parent Loop BB1_1 Depth=1
# => This Inner Loop Header: Depth=2
loop # label11:
- i32.const $push24=, 1
- i32.shr_u $0=, $0, $pop24
- i32.const $push23=, 1
- i32.and $push9=, $0, $pop23
- i32.const $push52=, 0
- i32.eq $push53=, $pop9, $pop52
- br_if 0, $pop53 # 0: up to label11
-# BB#13: # %while.cond16.return.loopexit_crit_edge.i
+ i32.const $push28=, 1
+ i32.shr_u $0=, $0, $pop28
+ i32.const $push27=, 1
+ i32.and $push10=, $0, $pop27
+ i32.const $push62=, 0
+ i32.eq $push63=, $pop10, $pop62
+ br_if 0, $pop63 # 0: up to label11
+# BB#14: # %while.cond16.return.loopexit_crit_edge.i
# in Loop: Header=BB1_1 Depth=1
end_loop # label12:
- i32.store $discard=, 0($4), $0
-.LBB1_14: # %for.inc
+ i32.store $discard=, 0($3), $0
+.LBB1_15: # %for.inc
# in Loop: Header=BB1_1 Depth=1
end_block # label2:
- i32.const $push44=, 16
- i32.add $push45=, $5, $pop44
- i32.const $push30=, 12
- i32.add $push10=, $pop45, $pop30
- i32.const $push29=, 1
- i32.shr_u $push1=, $0, $pop29
- i32.store $0=, 0($pop10), $pop1
+ i32.const $push54=, 16
+ i32.add $push55=, $5, $pop54
+ i32.const $push36=, 12
+ i32.add $push11=, $pop55, $pop36
+ i32.const $push35=, 1
+ i32.shr_u $push0=, $0, $pop35
+ i32.store $0=, 0($pop11), $pop0
br 0 # 0: up to label0
-.LBB1_15: # %for.end
+.LBB1_16: # %for.end
end_loop # label1:
- i32.const $push37=, __stack_pointer
- i32.const $push35=, 32
- i32.add $push36=, $5, $pop35
- i32.store $discard=, 0($pop37), $pop36
+ i32.const $push43=, __stack_pointer
+ i32.const $push41=, 32
+ i32.add $push42=, $5, $pop41
+ i32.store $discard=, 0($pop43), $pop42
return
.endfunc
.Lfunc_end1:
diff --git a/test/torture-s/930111-1.c.s b/test/torture-s/930111-1.c.s
index 6a2dcbd13..4528ddf09 100644
--- a/test/torture-s/930111-1.c.s
+++ b/test/torture-s/930111-1.c.s
@@ -23,32 +23,24 @@ wwrite: # @wwrite
.result i32
.local i32
# BB#0: # %entry
- i32.const $1=, 0
- block
block
block
- i64.const $push0=, 28
- i64.gt_u $push1=, $0, $pop0
- br_if 0, $pop1 # 0: down to label2
+ i64.const $push1=, -3
+ i64.add $push5=, $0, $pop1
+ tee_local $push4=, $0=, $pop5
+ i64.const $push2=, 44
+ i64.gt_u $push3=, $pop4, $pop2
+ br_if 0, $pop3 # 0: down to label1
# BB#1: # %entry
- i64.const $push2=, 1
- i64.shl $push3=, $pop2, $0
- i64.const $push4=, 276825096
- i64.and $push5=, $pop3, $pop4
- i64.const $push6=, 0
- i64.ne $push7=, $pop5, $pop6
- br_if 1, $pop7 # 1: down to label1
-.LBB1_2: # %entry
- end_block # label2:
- i64.const $push8=, 47
- i64.ne $push9=, $0, $pop8
- br_if 1, $pop9 # 1: down to label0
-.LBB1_3: # %return
+ i32.const $1=, 0
+ i32.wrap/i64 $push0=, $0
+ br_table $pop0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1 # 1: down to label0
+ # 0: down to label1
+.LBB1_2: # %sw.default
end_block # label1:
- return $1
-.LBB1_4: # %sw.default
- end_block # label0:
i32.const $1=, 123
+.LBB1_3: # %return
+ end_block # label0:
return $1
.endfunc
.Lfunc_end1:
diff --git a/test/torture-s/930719-1.c.s b/test/torture-s/930719-1.c.s
index b0a9bd9a4..211ede4db 100644
--- a/test/torture-s/930719-1.c.s
+++ b/test/torture-s/930719-1.c.s
@@ -12,7 +12,7 @@ f: # @f
block
block
br_if 0, $0 # 0: down to label2
-# BB#1: # %while.body.preheader
+# BB#1: # %while.cond.preheader
i32.const $push0=, 1
i32.ne $push1=, $1, $pop0
br_if 1, $pop1 # 1: down to label1
@@ -24,7 +24,7 @@ f: # @f
end_block # label2:
i32.const $push2=, 0
return $pop2
-.LBB0_4: # %while.body
+.LBB0_4: # %while.cond
# =>This Inner Loop Header: Depth=1
end_block # label1:
loop # label3:
diff --git a/test/torture-s/980716-1.c.s b/test/torture-s/980716-1.c.s
index e54c24bfe..f738e8543 100644
--- a/test/torture-s/980716-1.c.s
+++ b/test/torture-s/980716-1.c.s
@@ -14,7 +14,7 @@ stub: # @stub
i32.sub $5=, $pop5, $pop6
i32.store $2=, 12($5), $1
copy_local $1=, $2
-.LBB0_1: # %while.body
+.LBB0_1: # %while.cond
# =>This Inner Loop Header: Depth=1
loop # label0:
i32.const $push2=, 4
@@ -26,7 +26,7 @@ stub: # @stub
# BB#2: # %while.end
end_loop # label1:
i32.store $1=, 12($5), $2
-.LBB0_3: # %while.body.1
+.LBB0_3: # %while.cond.1
# =>This Inner Loop Header: Depth=1
loop # label2:
i32.const $push3=, 4
diff --git a/test/torture-s/pr17133.c.s b/test/torture-s/pr17133.c.s
index 442d39c33..6393e2ce2 100644
--- a/test/torture-s/pr17133.c.s
+++ b/test/torture-s/pr17133.c.s
@@ -31,7 +31,7 @@ pure_alloc: # @pure_alloc
i32.const $push16=, 0
i32.eq $push17=, $1, $pop16
br_if 0, $pop17 # 0: up to label1
-# BB#3: # %while.body.if.then_crit_edge
+# BB#3: # %while.cond.if.then_crit_edge
end_loop # label2:
i32.const $2=, 0
i32.const $push15=, 0
diff --git a/test/torture-s/pr38051.c.s b/test/torture-s/pr38051.c.s
new file mode 100644
index 000000000..f9590bbf8
--- /dev/null
+++ b/test/torture-s/pr38051.c.s
@@ -0,0 +1,978 @@
+ .text
+ .file "/b/build/slave/linux/build/src/src/work/gcc/gcc/testsuite/gcc.c-torture/execute/pr38051.c"
+ .section .text.mymemcmp,"ax",@progbits
+ .hidden mymemcmp
+ .globl mymemcmp
+ .type mymemcmp,@function
+mymemcmp: # @mymemcmp
+ .param i32, i32, i32
+ .result i32
+ .local i32, i32, i32, i32, i32, i32, i32, i32
+# BB#0: # %entry
+ i32.const $push134=, __stack_pointer
+ i32.load $push135=, 0($pop134)
+ i32.const $push136=, 16
+ i32.sub $10=, $pop135, $pop136
+ i32.const $push1=, 2
+ i32.shr_u $2=, $2, $pop1
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ i32.const $push68=, 3
+ i32.and $push0=, $0, $pop68
+ i32.const $push177=, 0
+ i32.eq $push178=, $pop0, $pop177
+ br_if 0, $pop178 # 0: down to label13
+# BB#1: # %if.else
+ i32.const $push5=, -4
+ i32.and $4=, $0, $pop5
+ i32.const $push4=, 32
+ i32.const $push105=, 3
+ i32.shl $push2=, $0, $pop105
+ i32.const $push3=, 24
+ i32.and $push104=, $pop2, $pop3
+ tee_local $push103=, $8=, $pop104
+ i32.sub $3=, $pop4, $pop103
+ i32.const $push102=, 3
+ i32.and $push101=, $2, $pop102
+ tee_local $push100=, $0=, $pop101
+ i32.const $push179=, 0
+ i32.eq $push180=, $pop100, $pop179
+ br_if 1, $pop180 # 1: down to label12
+# BB#2: # %if.else
+ i32.const $push6=, 1
+ i32.eq $push7=, $0, $pop6
+ br_if 2, $pop7 # 2: down to label11
+# BB#3: # %if.else
+ i32.const $push8=, 3
+ i32.ne $push9=, $0, $pop8
+ br_if 3, $pop9 # 3: down to label10
+# BB#4: # %sw.bb6.i
+ i32.load $6=, 0($4)
+ i32.const $push15=, 1
+ i32.add $2=, $2, $pop15
+ i32.const $push14=, -4
+ i32.add $0=, $1, $pop14
+ br 8 # 8: down to label5
+.LBB0_5: # %if.then
+ end_block # label13:
+ i32.const $push71=, 3
+ i32.and $push70=, $2, $pop71
+ tee_local $push69=, $4=, $pop70
+ i32.const $push181=, 0
+ i32.eq $push182=, $pop69, $pop181
+ br_if 10, $pop182 # 10: down to label2
+# BB#6: # %if.then
+ i32.const $push44=, 1
+ i32.eq $push45=, $4, $pop44
+ br_if 3, $pop45 # 3: down to label9
+# BB#7: # %if.then
+ i32.const $push46=, 3
+ i32.ne $push47=, $4, $pop46
+ br_if 4, $pop47 # 4: down to label8
+# BB#8: # %sw.bb3.i
+ copy_local $4=, $0
+ i32.const $push50=, -4
+ i32.add $0=, $0, $pop50
+ copy_local $8=, $1
+ i32.const $push73=, -4
+ i32.add $1=, $1, $pop73
+ i32.const $push51=, 1
+ i32.add $2=, $2, $pop51
+ br 11 # 11: down to label1
+.LBB0_9: # %sw.bb12.i18
+ end_block # label12:
+ i32.load $7=, 0($4)
+ i32.const $push13=, 4
+ i32.add $4=, $4, $pop13
+ copy_local $0=, $1
+ br 5 # 5: down to label6
+.LBB0_10: # %sw.bb17.i
+ end_block # label11:
+ i32.load $6=, 0($4)
+ i32.load $7=, 4($4)
+ i32.const $push10=, 8
+ i32.add $4=, $4, $pop10
+ i32.load $5=, 0($1)
+ i32.const $push11=, 4
+ i32.add $0=, $1, $pop11
+ i32.const $push12=, -1
+ i32.add $2=, $2, $pop12
+ br 3 # 3: down to label7
+.LBB0_11: # %sw.bb.i16
+ end_block # label10:
+ i32.const $push16=, 4
+ i32.add $6=, $4, $pop16
+ i32.load $7=, 0($4)
+ i32.const $push17=, -4
+ i32.add $4=, $4, $pop17
+ i32.const $push19=, 2
+ i32.add $2=, $2, $pop19
+ i32.const $push18=, -8
+ i32.add $0=, $1, $pop18
+ br 5 # 5: down to label4
+.LBB0_12: # %sw.bb12.i
+ end_block # label9:
+ i32.load $4=, 0($0)
+ i32.const $push48=, 4
+ i32.add $0=, $0, $pop48
+ i32.load $8=, 0($1)
+ i32.const $push74=, 4
+ i32.add $1=, $1, $pop74
+ i32.const $push49=, -1
+ i32.add $2=, $2, $pop49
+ br 5 # 5: down to label3
+.LBB0_13: # %sw.bb.i
+ end_block # label8:
+ copy_local $4=, $0
+ i32.const $push52=, -8
+ i32.add $0=, $0, $pop52
+ copy_local $8=, $1
+ i32.const $push72=, -8
+ i32.add $1=, $1, $pop72
+ i32.const $push53=, 2
+ i32.add $2=, $2, $pop53
+# BB#14:
+ i32.const $9=, 33
+ br 7 # 7: down to label0
+.LBB0_15:
+ end_block # label7:
+ i32.const $9=, 1
+ br 6 # 6: down to label0
+.LBB0_16:
+ end_block # label6:
+ i32.const $9=, 6
+ br 5 # 5: down to label0
+.LBB0_17:
+ end_block # label5:
+ i32.const $9=, 10
+ br 4 # 4: down to label0
+.LBB0_18:
+ end_block # label4:
+ i32.const $9=, 14
+ br 3 # 3: down to label0
+.LBB0_19:
+ end_block # label3:
+ i32.const $9=, 22
+ br 2 # 2: down to label0
+.LBB0_20:
+ end_block # label2:
+ i32.const $9=, 25
+ br 1 # 1: down to label0
+.LBB0_21:
+ end_block # label1:
+ i32.const $9=, 29
+.LBB0_22: # =>This Inner Loop Header: Depth=1
+ end_block # label0:
+ loop # label14:
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ block
+ br_table $9, 22, 29, 30, 35, 36, 23, 31, 32, 24, 25, 33, 34, 26, 19, 27, 28, 20, 21, 37, 38, 39, 3, 10, 11, 4, 12, 13, 5, 6, 14, 15, 7, 0, 8, 9, 1, 2, 16, 17, 18, 18 # 22: down to label66
+ # 29: down to label59
+ # 30: down to label58
+ # 35: down to label53
+ # 36: down to label52
+ # 23: down to label65
+ # 31: down to label57
+ # 32: down to label56
+ # 24: down to label64
+ # 25: down to label63
+ # 33: down to label55
+ # 34: down to label54
+ # 26: down to label62
+ # 19: down to label69
+ # 27: down to label61
+ # 28: down to label60
+ # 20: down to label68
+ # 21: down to label67
+ # 37: down to label51
+ # 38: down to label50
+ # 39: down to label49
+ # 3: down to label85
+ # 10: down to label78
+ # 11: down to label77
+ # 4: down to label84
+ # 12: down to label76
+ # 13: down to label75
+ # 5: down to label83
+ # 6: down to label82
+ # 14: down to label74
+ # 15: down to label73
+ # 7: down to label81
+ # 0: down to label88
+ # 8: down to label80
+ # 9: down to label79
+ # 1: down to label87
+ # 2: down to label86
+ # 16: down to label72
+ # 17: down to label71
+ # 18: down to label70
+.LBB0_23: # %do1.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label88:
+ i32.load $push94=, 0($4)
+ tee_local $push93=, $4=, $pop94
+ i32.load $push92=, 0($8)
+ tee_local $push91=, $8=, $pop92
+ i32.ne $push54=, $pop93, $pop91
+ br_if 70, $pop54 # 70: down to label17
+# BB#24: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 36
+ br 72 # 72: up to label14
+.LBB0_25: # %if.end37.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label87:
+ i32.load $4=, 12($0)
+ i32.load $8=, 12($1)
+ i32.const $push57=, -4
+ i32.add $2=, $2, $pop57
+ i32.const $push183=, 0
+ i32.eq $push184=, $2, $pop183
+ br_if 70, $pop184 # 70: down to label16
+# BB#26: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 37
+ br 71 # 71: up to label14
+.LBB0_27: # in Loop: Header=BB0_22 Depth=1
+ end_block # label86:
+ i32.const $push56=, 16
+ i32.add $0=, $0, $pop56
+ i32.const $push97=, 16
+ i32.add $1=, $1, $pop97
+# BB#28: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 22
+ br 70 # 70: up to label14
+.LBB0_29: # %do.body.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label85:
+ i32.ne $push58=, $4, $8
+ br_if 36, $pop58 # 36: down to label48
+# BB#30: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 25
+ br 69 # 69: up to label14
+.LBB0_31: # %do3.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label84:
+ i32.load $push80=, 0($0)
+ tee_local $push79=, $4=, $pop80
+ i32.load $push78=, 0($1)
+ tee_local $push77=, $8=, $pop78
+ i32.ne $push61=, $pop79, $pop77
+ br_if 63, $pop61 # 63: down to label20
+# BB#32: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 28
+ br 68 # 68: up to label14
+.LBB0_33: # in Loop: Header=BB0_22 Depth=1
+ end_block # label83:
+ i32.const $push60=, 4
+ i32.add $4=, $0, $pop60
+ i32.const $push81=, 4
+ i32.add $8=, $1, $pop81
+# BB#34: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 29
+ br 67 # 67: up to label14
+.LBB0_35: # %do2.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label82:
+ i32.load $push87=, 0($4)
+ tee_local $push86=, $4=, $pop87
+ i32.load $push85=, 0($8)
+ tee_local $push84=, $8=, $pop85
+ i32.ne $push64=, $pop86, $pop84
+ br_if 62, $pop64 # 62: down to label19
+# BB#36: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 32
+ br 66 # 66: up to label14
+.LBB0_37: # in Loop: Header=BB0_22 Depth=1
+ end_block # label81:
+ i32.const $push63=, 8
+ i32.add $4=, $0, $pop63
+ i32.const $push88=, 8
+ i32.add $8=, $1, $pop88
+ br 62 # 62: down to label18
+.LBB0_38: # %if.then35.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label80:
+ i32.store $discard=, 12($10), $4
+ i32.store $discard=, 8($10), $8
+ i32.const $push145=, 12
+ i32.add $push146=, $10, $pop145
+ copy_local $0=, $pop146
+ i32.const $push147=, 8
+ i32.add $push148=, $10, $pop147
+ copy_local $2=, $pop148
+# BB#39: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 35
+ br 64 # 64: up to label14
+.LBB0_40: # %do.body.i116.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label79:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push96=, 1
+ i32.add $0=, $0, $pop96
+ i32.const $push95=, 1
+ i32.add $2=, $2, $pop95
+ i32.eq $push55=, $1, $4
+ br_if 42, $pop55 # 42: down to label36
+ br 43 # 43: down to label35
+.LBB0_41: # %if.then.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label78:
+ i32.store $discard=, 12($10), $4
+ i32.store $discard=, 8($10), $8
+ i32.const $push141=, 12
+ i32.add $push142=, $10, $pop141
+ copy_local $0=, $pop142
+ i32.const $push143=, 8
+ i32.add $push144=, $10, $pop143
+ copy_local $2=, $pop144
+# BB#42: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 24
+ br 62 # 62: up to label14
+.LBB0_43: # %do.body.i.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label77:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push76=, 1
+ i32.add $0=, $0, $pop76
+ i32.const $push75=, 1
+ i32.add $2=, $2, $pop75
+ i32.eq $push59=, $1, $4
+ br_if 34, $pop59 # 34: down to label42
+ br 35 # 35: down to label41
+.LBB0_44: # %if.then23.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label76:
+ i32.store $discard=, 12($10), $4
+ i32.store $discard=, 8($10), $8
+ i32.const $push153=, 12
+ i32.add $push154=, $10, $pop153
+ copy_local $0=, $pop154
+ i32.const $push155=, 8
+ i32.add $push156=, $10, $pop155
+ copy_local $2=, $pop156
+# BB#45: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 27
+ br 60 # 60: up to label14
+.LBB0_46: # %do.body.i140.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label75:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push83=, 1
+ i32.add $0=, $0, $pop83
+ i32.const $push82=, 1
+ i32.add $2=, $2, $pop82
+ i32.eq $push62=, $1, $4
+ br_if 34, $pop62 # 34: down to label40
+ br 35 # 35: down to label39
+.LBB0_47: # %if.then29.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label74:
+ i32.store $discard=, 12($10), $4
+ i32.store $discard=, 8($10), $8
+ i32.const $push149=, 12
+ i32.add $push150=, $10, $pop149
+ copy_local $0=, $pop150
+ i32.const $push151=, 8
+ i32.add $push152=, $10, $pop151
+ copy_local $2=, $pop152
+# BB#48: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 31
+ br 58 # 58: up to label14
+.LBB0_49: # %do.body.i128.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label73:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push90=, 1
+ i32.add $0=, $0, $pop90
+ i32.const $push89=, 1
+ i32.add $2=, $2, $pop89
+ i32.eq $push65=, $1, $4
+ br_if 34, $pop65 # 34: down to label38
+ br 35 # 35: down to label37
+.LBB0_50: # %do0.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label72:
+ i32.const $0=, 0
+ i32.eq $push66=, $4, $8
+ br_if 45, $pop66 # 45: down to label26
+# BB#51: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 39
+ br 56 # 56: up to label14
+.LBB0_52: # %if.then43.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label71:
+ i32.store $discard=, 12($10), $4
+ i32.store $discard=, 8($10), $8
+ i32.const $push137=, 12
+ i32.add $push138=, $10, $pop137
+ copy_local $0=, $pop138
+ i32.const $push139=, 8
+ i32.add $push140=, $10, $pop139
+ copy_local $2=, $pop140
+# BB#53: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 40
+ br 55 # 55: up to label14
+.LBB0_54: # %do.body.i104.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label70:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push99=, 1
+ i32.add $0=, $0, $pop99
+ i32.const $push98=, 1
+ i32.add $2=, $2, $pop98
+ i32.eq $push67=, $1, $4
+ br_if 35, $pop67 # 35: down to label34
+ br 36 # 36: down to label33
+.LBB0_55: # %do1.i56
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label69:
+ i32.load $6=, 0($6)
+ i32.shl $push21=, $6, $3
+ i32.shr_u $push20=, $7, $8
+ i32.or $push126=, $pop21, $pop20
+ tee_local $push125=, $7=, $pop126
+ i32.load $push124=, 0($1)
+ tee_local $push123=, $1=, $pop124
+ i32.ne $push22=, $pop125, $pop123
+ br_if 46, $pop22 # 46: down to label22
+# BB#56: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 17
+ br 53 # 53: up to label14
+.LBB0_57: # %if.end54.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label68:
+ i32.load $7=, 12($4)
+ i32.load $5=, 12($0)
+ i32.const $push25=, -4
+ i32.add $2=, $2, $pop25
+ i32.const $push185=, 0
+ i32.eq $push186=, $2, $pop185
+ br_if 46, $pop186 # 46: down to label21
+# BB#58: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 18
+ br 52 # 52: up to label14
+.LBB0_59: # in Loop: Header=BB0_22 Depth=1
+ end_block # label67:
+ i32.const $push24=, 16
+ i32.add $4=, $4, $pop24
+ i32.const $push129=, 16
+ i32.add $0=, $0, $pop129
+# BB#60: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 1
+ br 51 # 51: up to label14
+.LBB0_61: # %do.body.i23
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label66:
+ i32.shl $push27=, $7, $3
+ i32.shr_u $push26=, $6, $8
+ i32.or $push107=, $pop27, $pop26
+ tee_local $push106=, $1=, $pop107
+ i32.ne $push28=, $pop106, $5
+ br_if 18, $pop28 # 18: down to label47
+# BB#62: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 6
+ br 50 # 50: up to label14
+.LBB0_63: # %do3.i42
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label65:
+ i32.load $6=, 0($4)
+ i32.shl $push32=, $6, $3
+ i32.shr_u $push31=, $7, $8
+ i32.or $push113=, $pop32, $pop31
+ tee_local $push112=, $1=, $pop113
+ i32.load $push111=, 0($0)
+ tee_local $push110=, $7=, $pop111
+ i32.ne $push33=, $pop112, $pop110
+ br_if 39, $pop33 # 39: down to label25
+# BB#64: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 9
+ br 49 # 49: up to label14
+.LBB0_65: # in Loop: Header=BB0_22 Depth=1
+ end_block # label64:
+ i32.const $push30=, 4
+ i32.add $1=, $0, $pop30
+# BB#66: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 10
+ br 48 # 48: up to label14
+.LBB0_67: # %do2.i50
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label63:
+ i32.load $7=, 4($4)
+ i32.shl $push37=, $7, $3
+ i32.shr_u $push36=, $6, $8
+ i32.or $push119=, $pop37, $pop36
+ tee_local $push118=, $6=, $pop119
+ i32.load $push117=, 0($1)
+ tee_local $push116=, $1=, $pop117
+ i32.ne $push38=, $pop118, $pop116
+ br_if 38, $pop38 # 38: down to label24
+# BB#68: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 13
+ br 47 # 47: up to label14
+.LBB0_69: # in Loop: Header=BB0_22 Depth=1
+ end_block # label62:
+ i32.const $push35=, 8
+ i32.add $6=, $4, $pop35
+ i32.const $push120=, 8
+ i32.add $1=, $0, $pop120
+ br 38 # 38: down to label23
+.LBB0_70: # %if.then52.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label61:
+ i32.store $discard=, 12($10), $7
+ i32.store $discard=, 8($10), $1
+ i32.const $push165=, 12
+ i32.add $push166=, $10, $pop165
+ copy_local $0=, $pop166
+ i32.const $push167=, 8
+ i32.add $push168=, $10, $pop167
+ copy_local $2=, $pop168
+# BB#71: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 16
+ br 45 # 45: up to label14
+.LBB0_72: # %do.body.i170.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label60:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push128=, 1
+ i32.add $0=, $0, $pop128
+ i32.const $push127=, 1
+ i32.add $2=, $2, $pop127
+ i32.eq $push23=, $1, $4
+ br_if 30, $pop23 # 30: down to label29
+ br 31 # 31: down to label28
+.LBB0_73: # %if.then.i24
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label59:
+ i32.store $discard=, 12($10), $1
+ i32.store $discard=, 8($10), $5
+ i32.const $push161=, 12
+ i32.add $push162=, $10, $pop161
+ copy_local $0=, $pop162
+ i32.const $push163=, 8
+ i32.add $push164=, $10, $pop163
+ copy_local $2=, $pop164
+# BB#74: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 3
+ br 43 # 43: up to label14
+.LBB0_75: # %do.body.i.i30
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label58:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push109=, 1
+ i32.add $0=, $0, $pop109
+ i32.const $push108=, 1
+ i32.add $2=, $2, $pop108
+ i32.eq $push29=, $1, $4
+ br_if 11, $pop29 # 11: down to label46
+ br 12 # 12: down to label45
+.LBB0_76: # %if.then34.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label57:
+ i32.store $discard=, 12($10), $1
+ i32.store $discard=, 8($10), $7
+ i32.const $push173=, 12
+ i32.add $push174=, $10, $pop173
+ copy_local $0=, $pop174
+ i32.const $push175=, 8
+ i32.add $push176=, $10, $pop175
+ copy_local $2=, $pop176
+# BB#77: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 8
+ br 41 # 41: up to label14
+.LBB0_78: # %do.body.i194.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label56:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push115=, 1
+ i32.add $0=, $0, $pop115
+ i32.const $push114=, 1
+ i32.add $2=, $2, $pop114
+ i32.eq $push34=, $1, $4
+ br_if 23, $pop34 # 23: down to label32
+ br 24 # 24: down to label31
+.LBB0_79: # %if.then43.i51
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label55:
+ i32.store $discard=, 12($10), $6
+ i32.store $discard=, 8($10), $1
+ i32.const $push169=, 12
+ i32.add $push170=, $10, $pop169
+ copy_local $0=, $pop170
+ i32.const $push171=, 8
+ i32.add $push172=, $10, $pop171
+ copy_local $2=, $pop172
+# BB#80: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 12
+ br 39 # 39: up to label14
+.LBB0_81: # %do.body.i182.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label54:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push122=, 1
+ i32.add $0=, $0, $pop122
+ i32.const $push121=, 1
+ i32.add $2=, $2, $pop121
+ i32.eq $push39=, $1, $4
+ br_if 23, $pop39 # 23: down to label30
+# BB#82: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 4
+ br 38 # 38: up to label14
+.LBB0_83: # %mymemcmp1.exit162.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label53:
+ i32.sub $0=, $1, $4
+# BB#84: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 5
+ br 37 # 37: up to label14
+.LBB0_85: # %cleanup
+ end_block # label52:
+ return $0
+.LBB0_86: # %do0.i57
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label51:
+ i32.const $0=, 0
+ i32.shl $push41=, $7, $3
+ i32.shr_u $push40=, $6, $8
+ i32.or $push131=, $pop41, $pop40
+ tee_local $push130=, $2=, $pop131
+ i32.eq $push42=, $pop130, $5
+ br_if 23, $pop42 # 23: down to label27
+# BB#87: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 20
+ br 35 # 35: up to label14
+.LBB0_88: # %if.then63.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label50:
+ i32.store $discard=, 12($10), $2
+ i32.store $discard=, 8($10), $5
+ i32.const $push157=, 12
+ i32.add $push158=, $10, $pop157
+ copy_local $0=, $pop158
+ i32.const $push159=, 8
+ i32.add $push160=, $10, $pop159
+ copy_local $2=, $pop160
+# BB#89: # in Loop: Header=BB0_22 Depth=1
+ i32.const $9=, 21
+ br 34 # 34: up to label14
+.LBB0_90: # %do.body.i158.i
+ # in Loop: Header=BB0_22 Depth=1
+ end_block # label49:
+ i32.load8_u $1=, 0($0)
+ i32.load8_u $4=, 0($2)
+ i32.const $push133=, 1
+ i32.add $0=, $0, $pop133
+ i32.const $push132=, 1
+ i32.add $2=, $2, $pop132
+ i32.eq $push43=, $1, $4
+ br_if 4, $pop43 # 4: down to label44
+ br 5 # 5: down to label43
+.LBB0_91: # in Loop: Header=BB0_22 Depth=1
+ end_block # label48:
+ i32.const $9=, 23
+ br 32 # 32: up to label14
+.LBB0_92: # in Loop: Header=BB0_22 Depth=1
+ end_block # label47:
+ i32.const $9=, 2
+ br 31 # 31: up to label14
+.LBB0_93: # in Loop: Header=BB0_22 Depth=1
+ end_block # label46:
+ i32.const $9=, 3
+ br 30 # 30: up to label14
+.LBB0_94: # in Loop: Header=BB0_22 Depth=1
+ end_block # label45:
+ i32.const $9=, 4
+ br 29 # 29: up to label14
+.LBB0_95: # in Loop: Header=BB0_22 Depth=1
+ end_block # label44:
+ i32.const $9=, 21
+ br 28 # 28: up to label14
+.LBB0_96: # in Loop: Header=BB0_22 Depth=1
+ end_block # label43:
+ i32.const $9=, 4
+ br 27 # 27: up to label14
+.LBB0_97: # in Loop: Header=BB0_22 Depth=1
+ end_block # label42:
+ i32.const $9=, 24
+ br 26 # 26: up to label14
+.LBB0_98: # in Loop: Header=BB0_22 Depth=1
+ end_block # label41:
+ i32.const $9=, 4
+ br 25 # 25: up to label14
+.LBB0_99: # in Loop: Header=BB0_22 Depth=1
+ end_block # label40:
+ i32.const $9=, 27
+ br 24 # 24: up to label14
+.LBB0_100: # in Loop: Header=BB0_22 Depth=1
+ end_block # label39:
+ i32.const $9=, 4
+ br 23 # 23: up to label14
+.LBB0_101: # in Loop: Header=BB0_22 Depth=1
+ end_block # label38:
+ i32.const $9=, 31
+ br 22 # 22: up to label14
+.LBB0_102: # in Loop: Header=BB0_22 Depth=1
+ end_block # label37:
+ i32.const $9=, 4
+ br 21 # 21: up to label14
+.LBB0_103: # in Loop: Header=BB0_22 Depth=1
+ end_block # label36:
+ i32.const $9=, 35
+ br 20 # 20: up to label14
+.LBB0_104: # in Loop: Header=BB0_22 Depth=1
+ end_block # label35:
+ i32.const $9=, 4
+ br 19 # 19: up to label14
+.LBB0_105: # in Loop: Header=BB0_22 Depth=1
+ end_block # label34:
+ i32.const $9=, 40
+ br 18 # 18: up to label14
+.LBB0_106: # in Loop: Header=BB0_22 Depth=1
+ end_block # label33:
+ i32.const $9=, 4
+ br 17 # 17: up to label14
+.LBB0_107: # in Loop: Header=BB0_22 Depth=1
+ end_block # label32:
+ i32.const $9=, 8
+ br 16 # 16: up to label14
+.LBB0_108: # in Loop: Header=BB0_22 Depth=1
+ end_block # label31:
+ i32.const $9=, 4
+ br 15 # 15: up to label14
+.LBB0_109: # in Loop: Header=BB0_22 Depth=1
+ end_block # label30:
+ i32.const $9=, 12
+ br 14 # 14: up to label14
+.LBB0_110: # in Loop: Header=BB0_22 Depth=1
+ end_block # label29:
+ i32.const $9=, 16
+ br 13 # 13: up to label14
+.LBB0_111: # in Loop: Header=BB0_22 Depth=1
+ end_block # label28:
+ i32.const $9=, 4
+ br 12 # 12: up to label14
+.LBB0_112: # in Loop: Header=BB0_22 Depth=1
+ end_block # label27:
+ i32.const $9=, 5
+ br 11 # 11: up to label14
+.LBB0_113: # in Loop: Header=BB0_22 Depth=1
+ end_block # label26:
+ i32.const $9=, 5
+ br 10 # 10: up to label14
+.LBB0_114: # in Loop: Header=BB0_22 Depth=1
+ end_block # label25:
+ i32.const $9=, 7
+ br 9 # 9: up to label14
+.LBB0_115: # in Loop: Header=BB0_22 Depth=1
+ end_block # label24:
+ i32.const $9=, 11
+ br 8 # 8: up to label14
+.LBB0_116: # in Loop: Header=BB0_22 Depth=1
+ end_block # label23:
+ i32.const $9=, 14
+ br 7 # 7: up to label14
+.LBB0_117: # in Loop: Header=BB0_22 Depth=1
+ end_block # label22:
+ i32.const $9=, 15
+ br 6 # 6: up to label14
+.LBB0_118: # in Loop: Header=BB0_22 Depth=1
+ end_block # label21:
+ i32.const $9=, 19
+ br 5 # 5: up to label14
+.LBB0_119: # in Loop: Header=BB0_22 Depth=1
+ end_block # label20:
+ i32.const $9=, 26
+ br 4 # 4: up to label14
+.LBB0_120: # in Loop: Header=BB0_22 Depth=1
+ end_block # label19:
+ i32.const $9=, 30
+ br 3 # 3: up to label14
+.LBB0_121: # in Loop: Header=BB0_22 Depth=1
+ end_block # label18:
+ i32.const $9=, 33
+ br 2 # 2: up to label14
+.LBB0_122: # in Loop: Header=BB0_22 Depth=1
+ end_block # label17:
+ i32.const $9=, 34
+ br 1 # 1: up to label14
+.LBB0_123: # in Loop: Header=BB0_22 Depth=1
+ end_block # label16:
+ i32.const $9=, 38
+ br 0 # 0: up to label14
+.LBB0_124:
+ end_loop # label15:
+ .endfunc
+.Lfunc_end0:
+ .size mymemcmp, .Lfunc_end0-mymemcmp
+
+ .section .text.main,"ax",@progbits
+ .hidden main
+ .globl main
+ .type main,@function
+main: # @main
+ .result i32
+# BB#0: # %entry
+ i32.const $push29=, 0
+ i32.const $push28=, 0
+ i32.load8_u $push0=, .L.str+14($pop28)
+ i32.store8 $discard=, buf+39($pop29), $pop0
+ i32.const $push27=, 0
+ i32.const $push26=, 0
+ i32.load16_u $push1=, .L.str+12($pop26):p2align=0
+ i32.store16 $discard=, buf+37($pop27):p2align=0, $pop1
+ i32.const $push25=, 0
+ i32.const $push24=, 0
+ i32.load $push2=, .L.str+8($pop24):p2align=0
+ i32.store $discard=, buf+33($pop25):p2align=0, $pop2
+ i32.const $push23=, 0
+ i32.const $push22=, 0
+ i32.load8_u $push4=, .L.str.1+14($pop22)
+ i32.store8 $discard=, buf+182($pop23):p2align=1, $pop4
+ i32.const $push21=, 0
+ i32.const $push20=, 0
+ i32.load16_u $push5=, .L.str.1+12($pop20):p2align=0
+ i32.store16 $discard=, buf+180($pop21):p2align=2, $pop5
+ i32.const $push19=, 0
+ i32.const $push18=, 0
+ i32.load $push6=, .L.str.1+8($pop18):p2align=0
+ i32.store $discard=, buf+176($pop19):p2align=3, $pop6
+ i32.const $push17=, 0
+ i32.const $push16=, 0
+ i64.load $push3=, .L.str($pop16):p2align=0
+ i64.store $discard=, buf+25($pop17):p2align=0, $pop3
+ i32.const $push15=, 0
+ i32.const $push14=, 0
+ i64.load $push7=, .L.str.1($pop14):p2align=0
+ i64.store $discard=, buf+168($pop15), $pop7
+ block
+ i32.const $push10=, buf+25
+ i32.const $push9=, buf+168
+ i32.const $push8=, 33
+ i32.call $push11=, mymemcmp@FUNCTION, $pop10, $pop9, $pop8
+ i32.const $push12=, -51
+ i32.ne $push13=, $pop11, $pop12
+ br_if 0, $pop13 # 0: down to label89
+# BB#1: # %cleanup
+ i32.const $push30=, 0
+ return $pop30
+.LBB1_2: # %if.then26
+ end_block # label89:
+ call abort@FUNCTION
+ unreachable
+ .endfunc
+.Lfunc_end1:
+ .size main, .Lfunc_end1-main
+
+ .hidden buf # @buf
+ .type buf,@object
+ .section .bss.buf,"aw",@nobits
+ .globl buf
+ .p2align 4
+buf:
+ .skip 256
+ .size buf, 256
+
+ .type .L.str,@object # @.str
+ .section .rodata.str1.1,"aMS",@progbits,1
+.L.str:
+ .asciz "\0017\202\247UI\235\277\370D\266U\027\216\371"
+ .size .L.str, 16
+
+ .type .L.str.1,@object # @.str.1
+.L.str.1:
+ .asciz "\0017\202\247UI\320\363\267*m#qIj"
+ .size .L.str.1, 16
+
+
+ .ident "clang version 3.9.0 "
diff --git a/test/torture-s/pr42691.c.s b/test/torture-s/pr42691.c.s
index 37f99a78d..f92981972 100644
--- a/test/torture-s/pr42691.c.s
+++ b/test/torture-s/pr42691.c.s
@@ -26,7 +26,7 @@ add: # @add
f64.const $push10=, infinity
f64.ne $push1=, $3, $pop10
br_if 3, $pop1 # 3: down to label0
-# BB#3: # %while.body
+# BB#3: # %while.cond
# in Loop: Header=BB0_2 Depth=1
f64.load $3=, 0($1)
i32.const $push9=, 8
@@ -74,7 +74,7 @@ main: # @main
f64.const $push8=, infinity
f64.ne $push2=, $1, $pop8
br_if 2, $pop2 # 2: down to label4
-# BB#2: # %while.body.i
+# BB#2: # %while.cond.i
# in Loop: Header=BB1_1 Depth=1
f64.load $1=, 0($0)
i32.const $push7=, 8
diff --git a/test/torture-s/pr48809.c.s b/test/torture-s/pr48809.c.s
index 8d0ceba50..91a80a7cb 100644
--- a/test/torture-s/pr48809.c.s
+++ b/test/torture-s/pr48809.c.s
@@ -7,8 +7,9 @@
foo: # @foo
.param i32
.result i32
- .local i32
+ .local i32, i32
# BB#0: # %entry
+ i32.const $1=, 0
block
block
block
@@ -41,184 +42,189 @@ foo: # @foo
block
block
block
- i32.const $push0=, 32
- i32.gt_u $push1=, $0, $pop0
- br_if 0, $pop1 # 0: down to label31
+ block
+ block
+ i32.const $push0=, 62
+ i32.add $push4=, $0, $pop0
+ tee_local $push3=, $2=, $pop4
+ i32.const $push1=, 160
+ i32.gt_u $push2=, $pop3, $pop1
+ br_if 0, $pop2 # 0: down to label33
# BB#1: # %entry
block
- br_table $0, 0, 4, 3, 2, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 3, 20, 21, 22, 23, 24, 25, 32, 26, 27, 28, 29, 30, 31, 0 # 0: down to label32
- # 4: down to label28
- # 3: down to label29
- # 2: down to label30
- # 5: down to label27
- # 6: down to label26
- # 7: down to label25
- # 8: down to label24
- # 9: down to label23
- # 10: down to label22
- # 11: down to label21
- # 12: down to label20
- # 13: down to label19
- # 14: down to label18
- # 15: down to label17
- # 16: down to label16
- # 17: down to label15
- # 18: down to label14
- # 19: down to label13
- # 20: down to label12
- # 21: down to label11
- # 22: down to label10
- # 23: down to label9
- # 24: down to label8
- # 25: down to label7
- # 32: down to label0
- # 26: down to label6
- # 27: down to label5
- # 28: down to label4
- # 29: down to label3
- # 30: down to label2
- # 31: down to label1
-.LBB0_2: # %sw.bb
+ br_table $2, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 4, 0, 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, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 34, 0 # 0: down to label34
+ # 1: down to label33
+ # 2: down to label32
+ # 3: down to label31
+ # 4: down to label30
+ # 5: down to label29
+ # 6: down to label28
+ # 7: down to label27
+ # 8: down to label26
+ # 9: down to label25
+ # 10: down to label24
+ # 11: down to label23
+ # 12: down to label22
+ # 13: down to label21
+ # 14: down to label20
+ # 15: down to label19
+ # 16: down to label18
+ # 17: down to label17
+ # 18: down to label16
+ # 19: down to label15
+ # 20: down to label14
+ # 21: down to label13
+ # 22: down to label12
+ # 23: down to label11
+ # 24: down to label10
+ # 25: down to label9
+ # 26: down to label8
+ # 27: down to label7
+ # 28: down to label6
+ # 29: down to label5
+ # 30: down to label4
+ # 31: down to label3
+ # 32: down to label2
+ # 33: down to label1
+ # 34: down to label0
+.LBB0_2: # %sw.bb34
+ end_block # label34:
+ i32.const $1=, 19
+.LBB0_3: # %sw.epilog
+ end_block # label33:
+ return $1
+.LBB0_4: # %sw.bb
end_block # label32:
- i32.const $0=, 1
- return $0
-.LBB0_3: # %entry
+ i32.const $1=, 1
+ return $1
+.LBB0_5: # %sw.bb1
end_block # label31:
- i32.const $push2=, -62
- i32.eq $push3=, $0, $pop2
- br_if 0, $pop3 # 0: down to label30
-# BB#4: # %entry
- i32.const $push4=, 98
- i32.eq $1=, $0, $pop4
- i32.const $0=, 0
- i32.const $push5=, 0
- i32.eq $push6=, $1, $pop5
- br_if 1, $pop6 # 1: down to label29
-# BB#5: # %sw.bb33
- i32.const $0=, 18
- return $0
-.LBB0_6: # %sw.bb34
+ i32.const $1=, 7
+ return $1
+.LBB0_6: # %sw.bb2
end_block # label30:
- i32.const $0=, 19
-.LBB0_7: # %sw.epilog
+ copy_local $1=, $0
+ return $1
+.LBB0_7: # %sw.bb4
end_block # label29:
- return $0
-.LBB0_8: # %sw.bb1
+ i32.const $1=, 5
+ return $1
+.LBB0_8: # %sw.bb5
end_block # label28:
- i32.const $0=, 7
- return $0
-.LBB0_9: # %sw.bb4
+ i32.const $1=, 17
+ return $1
+.LBB0_9: # %sw.bb6
end_block # label27:
- i32.const $0=, 5
- return $0
-.LBB0_10: # %sw.bb5
+ i32.const $1=, 31
+ return $1
+.LBB0_10: # %sw.bb7
end_block # label26:
- i32.const $0=, 17
- return $0
-.LBB0_11: # %sw.bb6
+ i32.const $1=, 8
+ return $1
+.LBB0_11: # %sw.bb8
end_block # label25:
- i32.const $0=, 31
- return $0
-.LBB0_12: # %sw.bb7
+ i32.const $1=, 28
+ return $1
+.LBB0_12: # %sw.bb9
end_block # label24:
- i32.const $0=, 8
- return $0
-.LBB0_13: # %sw.bb8
+ i32.const $1=, 16
+ return $1
+.LBB0_13: # %sw.bb10
end_block # label23:
- i32.const $0=, 28
- return $0
-.LBB0_14: # %sw.bb9
+ i32.const $1=, 31
+ return $1
+.LBB0_14: # %sw.bb11
end_block # label22:
- i32.const $0=, 16
- return $0
-.LBB0_15: # %sw.bb10
+ i32.const $1=, 12
+ return $1
+.LBB0_15: # %sw.bb12
end_block # label21:
- i32.const $0=, 31
- return $0
-.LBB0_16: # %sw.bb11
+ i32.const $1=, 15
+ return $1
+.LBB0_16: # %sw.bb13
end_block # label20:
- i32.const $0=, 12
- return $0
-.LBB0_17: # %sw.bb12
+ i32.const $1=, 111
+ return $1
+.LBB0_17: # %sw.bb14
end_block # label19:
- i32.const $0=, 15
- return $0
-.LBB0_18: # %sw.bb13
+ i32.const $1=, 17
+ return $1
+.LBB0_18: # %sw.bb15
end_block # label18:
- i32.const $0=, 111
- return $0
-.LBB0_19: # %sw.bb14
+ i32.const $1=, 10
+ return $1
+.LBB0_19: # %sw.bb16
end_block # label17:
- i32.const $0=, 17
- return $0
-.LBB0_20: # %sw.bb15
+ i32.const $1=, 31
+ return $1
+.LBB0_20: # %sw.bb17
end_block # label16:
- i32.const $0=, 10
- return $0
-.LBB0_21: # %sw.bb16
+ i32.const $1=, 7
+ return $1
+.LBB0_21: # %sw.bb18
end_block # label15:
- i32.const $0=, 31
- return $0
-.LBB0_22: # %sw.bb17
+ i32.const $1=, 2
+ return $1
+.LBB0_22: # %sw.bb19
end_block # label14:
- i32.const $0=, 7
- return $0
-.LBB0_23: # %sw.bb18
+ copy_local $1=, $0
+ return $1
+.LBB0_23: # %sw.bb20
end_block # label13:
- i32.const $0=, 2
- return $0
-.LBB0_24: # %sw.bb20
+ i32.const $1=, 5
+ return $1
+.LBB0_24: # %sw.bb21
end_block # label12:
- i32.const $0=, 5
- return $0
-.LBB0_25: # %sw.bb21
+ i32.const $1=, 107
+ return $1
+.LBB0_25: # %sw.bb22
end_block # label11:
- i32.const $0=, 107
- return $0
-.LBB0_26: # %sw.bb22
+ i32.const $1=, 31
+ return $1
+.LBB0_26: # %sw.bb23
end_block # label10:
- i32.const $0=, 31
- return $0
-.LBB0_27: # %sw.bb23
+ i32.const $1=, 8
+ return $1
+.LBB0_27: # %sw.bb24
end_block # label9:
- i32.const $0=, 8
- return $0
-.LBB0_28: # %sw.bb24
+ i32.const $1=, 28
+ return $1
+.LBB0_28: # %sw.bb25
end_block # label8:
- i32.const $0=, 28
- return $0
-.LBB0_29: # %sw.bb25
+ i32.const $1=, 106
+ return $1
+.LBB0_29: # %sw.bb26
end_block # label7:
- i32.const $0=, 106
- return $0
+ i32.const $1=, 31
+ return $1
.LBB0_30: # %sw.bb27
end_block # label6:
- i32.const $0=, 102
- return $0
+ i32.const $1=, 102
+ return $1
.LBB0_31: # %sw.bb28
end_block # label5:
- i32.const $0=, 105
- return $0
+ i32.const $1=, 105
+ return $1
.LBB0_32: # %sw.bb29
end_block # label4:
- i32.const $0=, 111
- return $0
+ i32.const $1=, 111
+ return $1
.LBB0_33: # %sw.bb30
end_block # label3:
- i32.const $0=, 17
- return $0
+ i32.const $1=, 17
+ return $1
.LBB0_34: # %sw.bb31
end_block # label2:
- i32.const $0=, 10
- return $0
+ i32.const $1=, 10
+ return $1
.LBB0_35: # %sw.bb32
end_block # label1:
- i32.const $0=, 31
- return $0
-.LBB0_36: # %sw.bb26
+ i32.const $1=, 31
+ return $1
+.LBB0_36: # %sw.bb33
end_block # label0:
- i32.const $0=, 31
- return $0
+ i32.const $1=, 18
+ return $1
.endfunc
.Lfunc_end0:
.size foo, .Lfunc_end0-foo
diff --git a/test/torture-s/pr57860.c.s b/test/torture-s/pr57860.c.s
index 47da41cdf..302bc5d38 100644
--- a/test/torture-s/pr57860.c.s
+++ b/test/torture-s/pr57860.c.s
@@ -16,7 +16,7 @@ foo: # @foo
i32.load $3=, h($pop12)
i32.const $push11=, 0
i32.load $4=, f($pop11)
-.LBB0_1: # %for.cond1thread-pre-split
+.LBB0_1: # %for.cond
# =>This Inner Loop Header: Depth=1
loop # label0:
block
@@ -78,7 +78,7 @@ main: # @main
i32.load $1=, h($pop14)
i32.const $push13=, 0
i32.load $2=, f($pop13)
-.LBB1_1: # %for.cond1thread-pre-split.i
+.LBB1_1: # %for.cond.i
# =>This Inner Loop Header: Depth=1
loop # label3:
block
diff --git a/test/torture-s/pr58640.c.s b/test/torture-s/pr58640.c.s
index b6318a7f4..6ab116be9 100644
--- a/test/torture-s/pr58640.c.s
+++ b/test/torture-s/pr58640.c.s
@@ -18,7 +18,7 @@ main: # @main
i32.const $push10=, 0
i32.load $push2=, d($pop10)
br_if 0, $pop2 # 0: down to label1
-# BB#2: # %for.inc25.i.preheader
+# BB#2: # %for.body3.i.preheader
i32.const $push6=, 0
i32.const $push7=, 1
i32.store $discard=, b($pop6), $pop7
diff --git a/test/torture-s/pr59387.c.s b/test/torture-s/pr59387.c.s
index 27731eec0..f2862137a 100644
--- a/test/torture-s/pr59387.c.s
+++ b/test/torture-s/pr59387.c.s
@@ -13,7 +13,7 @@ main: # @main
i32.store $0=, a($pop7), $pop1
i32.const $push6=, 0
i32.load8_u $1=, c($pop6)
-.LBB0_1: # %for.body2
+.LBB0_1: # %for.cond1.preheader
# =>This Inner Loop Header: Depth=1
loop # label0:
i32.const $push11=, 0
diff --git a/test/torture-s/printf-1.c.s b/test/torture-s/printf-1.c.s
index 22781ce1c..cf1cc45f0 100644
--- a/test/torture-s/printf-1.c.s
+++ b/test/torture-s/printf-1.c.s
@@ -10,26 +10,26 @@ main: # @main
# BB#0: # %entry
i32.const $push59=, __stack_pointer
i32.load $push60=, 0($pop59)
- i32.const $push61=, 192
+ i32.const $push61=, 176
i32.sub $1=, $pop60, $pop61
i32.const $push62=, __stack_pointer
i32.store $discard=, 0($pop62), $1
- i32.const $push45=, .Lstr
- i32.const $push44=, 0
- i32.call $discard=, printf@FUNCTION, $pop45, $pop44
+ i32.const $push46=, .Lstr
+ i32.const $push45=, 0
+ i32.call $discard=, printf@FUNCTION, $pop46, $pop45
block
- i32.const $push43=, .Lstr
- i32.const $push42=, 0
- i32.call $push0=, printf@FUNCTION, $pop43, $pop42
+ i32.const $push44=, .Lstr
+ i32.const $push43=, 0
+ i32.call $push0=, printf@FUNCTION, $pop44, $pop43
i32.const $push1=, 5
i32.ne $push2=, $pop0, $pop1
br_if 0, $pop2 # 0: down to label0
# BB#1: # %if.end
- i32.const $push47=, .Lstr
- i32.call $discard=, puts@FUNCTION, $pop47
+ i32.const $push48=, .Lstr
+ i32.call $discard=, puts@FUNCTION, $pop48
i32.const $push3=, .L.str.1
- i32.const $push46=, 0
- i32.call $push4=, printf@FUNCTION, $pop3, $pop46
+ i32.const $push47=, 0
+ i32.call $push4=, printf@FUNCTION, $pop3, $pop47
i32.const $push5=, 6
i32.ne $push6=, $pop4, $pop5
br_if 0, $pop6 # 0: down to label0
@@ -44,102 +44,99 @@ main: # @main
br_if 0, $pop12 # 0: down to label0
# BB#3: # %if.end16
i32.const $push13=, .Lstr
- i32.store $0=, 176($1):p2align=4, $pop13
- i32.const $push49=, .L.str.4
- i32.const $push66=, 176
+ i32.store $0=, 160($1):p2align=4, $pop13
+ i32.const $push50=, .L.str.4
+ i32.const $push66=, 160
i32.add $push67=, $1, $pop66
- i32.call $discard=, printf@FUNCTION, $pop49, $pop67
- i32.store $discard=, 160($1):p2align=4, $0
- i32.const $push48=, .L.str.4
- i32.const $push68=, 160
+ i32.call $discard=, printf@FUNCTION, $pop50, $pop67
+ i32.store $discard=, 144($1):p2align=4, $0
+ i32.const $push49=, .L.str.4
+ i32.const $push68=, 144
i32.add $push69=, $1, $pop68
- i32.call $push14=, printf@FUNCTION, $pop48, $pop69
+ i32.call $push14=, printf@FUNCTION, $pop49, $pop69
i32.const $push15=, 5
i32.ne $push16=, $pop14, $pop15
br_if 0, $pop16 # 0: down to label0
# BB#4: # %if.end21
i32.const $push17=, .L.str.1
- i32.store $0=, 144($1):p2align=4, $pop17
- i32.const $push51=, .L.str.4
- i32.const $push70=, 144
+ i32.store $0=, 128($1):p2align=4, $pop17
+ i32.const $push52=, .L.str.4
+ i32.const $push70=, 128
i32.add $push71=, $1, $pop70
- i32.call $discard=, printf@FUNCTION, $pop51, $pop71
- i32.store $discard=, 128($1):p2align=4, $0
- i32.const $push50=, .L.str.4
- i32.const $push72=, 128
+ i32.call $discard=, printf@FUNCTION, $pop52, $pop71
+ i32.store $discard=, 112($1):p2align=4, $0
+ i32.const $push51=, .L.str.4
+ i32.const $push72=, 112
i32.add $push73=, $1, $pop72
- i32.call $push18=, printf@FUNCTION, $pop50, $pop73
+ i32.call $push18=, printf@FUNCTION, $pop51, $pop73
i32.const $push19=, 6
i32.ne $push20=, $pop18, $pop19
br_if 0, $pop20 # 0: down to label0
# BB#5: # %if.end26
- i32.const $push21=, .L.str.2
- i32.store $0=, 112($1):p2align=4, $pop21
+ i32.const $push21=, 97
+ i32.call $discard=, putchar@FUNCTION, $pop21
+ i32.const $push22=, .L.str.2
+ i32.store $discard=, 96($1):p2align=4, $pop22
i32.const $push53=, .L.str.4
- i32.const $push74=, 112
+ i32.const $push74=, 96
i32.add $push75=, $1, $pop74
- i32.call $discard=, printf@FUNCTION, $pop53, $pop75
- i32.store $discard=, 96($1):p2align=4, $0
- i32.const $push52=, .L.str.4
- i32.const $push76=, 96
- i32.add $push77=, $1, $pop76
- i32.call $push22=, printf@FUNCTION, $pop52, $pop77
- i32.const $push23=, 1
- i32.ne $push24=, $pop22, $pop23
- br_if 0, $pop24 # 0: down to label0
+ i32.call $push23=, printf@FUNCTION, $pop53, $pop75
+ i32.const $push24=, 1
+ i32.ne $push25=, $pop23, $pop24
+ br_if 0, $pop25 # 0: down to label0
# BB#6: # %if.end31
- i32.const $push25=, .L.str.3
- i32.store $0=, 80($1):p2align=4, $pop25
+ i32.const $push26=, .L.str.3
+ i32.store $0=, 80($1):p2align=4, $pop26
i32.const $push55=, .L.str.4
- i32.const $push78=, 80
- i32.add $push79=, $1, $pop78
- i32.call $discard=, printf@FUNCTION, $pop55, $pop79
+ i32.const $push76=, 80
+ i32.add $push77=, $1, $pop76
+ i32.call $discard=, printf@FUNCTION, $pop55, $pop77
i32.store $discard=, 64($1):p2align=4, $0
i32.const $push54=, .L.str.4
- i32.const $push80=, 64
- i32.add $push81=, $1, $pop80
- i32.call $push26=, printf@FUNCTION, $pop54, $pop81
- br_if 0, $pop26 # 0: down to label0
+ i32.const $push78=, 64
+ i32.add $push79=, $1, $pop78
+ i32.call $push27=, printf@FUNCTION, $pop54, $pop79
+ br_if 0, $pop27 # 0: down to label0
# BB#7: # %if.end36
- i32.const $push27=, 120
- i32.call $discard=, putchar@FUNCTION, $pop27
+ i32.const $push28=, 120
+ i32.call $discard=, putchar@FUNCTION, $pop28
i32.const $push56=, 120
i32.store $discard=, 48($1):p2align=4, $pop56
- i32.const $push28=, .L.str.5
- i32.const $push82=, 48
- i32.add $push83=, $1, $pop82
- i32.call $push29=, printf@FUNCTION, $pop28, $pop83
- i32.const $push30=, 1
- i32.ne $push31=, $pop29, $pop30
- br_if 0, $pop31 # 0: down to label0
+ i32.const $push29=, .L.str.5
+ i32.const $push80=, 48
+ i32.add $push81=, $1, $pop80
+ i32.call $push30=, printf@FUNCTION, $pop29, $pop81
+ i32.const $push31=, 1
+ i32.ne $push32=, $pop30, $pop31
+ br_if 0, $pop32 # 0: down to label0
# BB#8: # %if.end41
- i32.const $push32=, .L.str.1
- i32.call $discard=, puts@FUNCTION, $pop32
+ i32.const $push33=, .L.str.1
+ i32.call $discard=, puts@FUNCTION, $pop33
i32.const $push57=, .L.str.1
i32.store $discard=, 32($1):p2align=4, $pop57
- i32.const $push33=, .L.str.6
- i32.const $push84=, 32
- i32.add $push85=, $1, $pop84
- i32.call $push34=, printf@FUNCTION, $pop33, $pop85
- i32.const $push35=, 7
- i32.ne $push36=, $pop34, $pop35
- br_if 0, $pop36 # 0: down to label0
+ i32.const $push34=, .L.str.6
+ i32.const $push82=, 32
+ i32.add $push83=, $1, $pop82
+ i32.call $push35=, printf@FUNCTION, $pop34, $pop83
+ i32.const $push36=, 7
+ i32.ne $push37=, $pop35, $pop36
+ br_if 0, $pop37 # 0: down to label0
# BB#9: # %if.end46
- i32.const $push37=, 0
- i32.store $0=, 16($1):p2align=4, $pop37
- i32.const $push38=, .L.str.7
- i32.const $push86=, 16
- i32.add $push87=, $1, $pop86
- i32.call $discard=, printf@FUNCTION, $pop38, $pop87
+ i32.const $push38=, 0
+ i32.store $0=, 16($1):p2align=4, $pop38
+ i32.const $push39=, .L.str.7
+ i32.const $push84=, 16
+ i32.add $push85=, $1, $pop84
+ i32.call $discard=, printf@FUNCTION, $pop39, $pop85
i32.store $discard=, 0($1):p2align=4, $0
i32.const $push58=, .L.str.7
- i32.call $push39=, printf@FUNCTION, $pop58, $1
- i32.const $push40=, 2
- i32.ne $push41=, $pop39, $pop40
- br_if 0, $pop41 # 0: down to label0
+ i32.call $push40=, printf@FUNCTION, $pop58, $1
+ i32.const $push41=, 2
+ i32.ne $push42=, $pop40, $pop41
+ br_if 0, $pop42 # 0: down to label0
# BB#10: # %if.end51
i32.const $push65=, __stack_pointer
- i32.const $push63=, 192
+ i32.const $push63=, 176
i32.add $push64=, $1, $pop63
i32.store $discard=, 0($pop65), $pop64
return $0