summaryrefslogtreecommitdiff
path: root/test/emcc_hello_world.fromasm.imprecise
diff options
context:
space:
mode:
Diffstat (limited to 'test/emcc_hello_world.fromasm.imprecise')
-rw-r--r--test/emcc_hello_world.fromasm.imprecise955
1 files changed, 36 insertions, 919 deletions
diff --git a/test/emcc_hello_world.fromasm.imprecise b/test/emcc_hello_world.fromasm.imprecise
index c13902e50..815fee11e 100644
--- a/test/emcc_hello_world.fromasm.imprecise
+++ b/test/emcc_hello_world.fromasm.imprecise
@@ -17592,944 +17592,61 @@
(get_local $0)
)
)
- (func $___udivmoddi4 (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (result i32)
- (local $5 i32)
- (local $6 i32)
- (local $7 i32)
- (local $8 i32)
- (local $9 i32)
- (local $10 i32)
- (local $11 i32)
- (local $12 i32)
- (local $13 i32)
- (local $14 i32)
- (set_local $8
- (get_local $0)
- )
- (set_local $5
- (get_local $2)
- )
- (set_local $7
- (tee_local $14
- (get_local $3)
- )
- )
- (if
- (i32.eqz
- (tee_local $6
- (tee_local $9
- (get_local $1)
- )
- )
- )
- (block
- (set_local $2
- (i32.ne
- (get_local $4)
- (i32.const 0)
- )
+ (func $___udivmoddi4 (param $xl i32) (param $xh i32) (param $yl i32) (param $yh i32) (param $r i32) (result i32)
+ (local $x64 i64)
+ (local $y64 i64)
+ (set_local $x64
+ (i64.or
+ (i64.extend_u/i32
+ (get_local $xl)
)
- (if
- (get_local $7)
- (block
- (if
- (i32.eqz
- (get_local $2)
- )
- (block
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.const 0)
- )
- )
- )
- (i32.store
- (get_local $4)
- (i32.and
- (get_local $0)
- (i32.const -1)
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.and
- (get_local $1)
- (i32.const 0)
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.const 0)
- )
- )
- (block
- (if
- (get_local $2)
- (block
- (i32.store
- (get_local $4)
- (i32.rem_u
- (get_local $8)
- (get_local $5)
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.const 0)
- )
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.div_u
- (get_local $8)
- (get_local $5)
- )
- )
+ (i64.shl
+ (i64.extend_u/i32
+ (get_local $xh)
)
+ (i64.const 32)
)
)
)
- (set_local $10
- (i32.eqz
- (get_local $7)
- )
- )
- (block $do-once$0
- (if
- (get_local $5)
- (block
- (if
- (i32.eqz
- (get_local $10)
- )
- (block
- (if
- (i32.le_u
- (tee_local $5
- (i32.sub
- (i32.clz
- (get_local $7)
- )
- (i32.clz
- (get_local $6)
- )
- )
- )
- (i32.const 31)
- )
- (block
- (set_local $12
- (tee_local $0
- (i32.add
- (get_local $5)
- (i32.const 1)
- )
- )
- )
- (set_local $11
- (i32.or
- (i32.and
- (i32.shr_u
- (get_local $8)
- (get_local $0)
- )
- (tee_local $9
- (i32.shr_s
- (i32.sub
- (get_local $5)
- (i32.const 31)
- )
- (i32.const 31)
- )
- )
- )
- (i32.shl
- (get_local $6)
- (tee_local $1
- (i32.sub
- (i32.const 31)
- (get_local $5)
- )
- )
- )
- )
- )
- (set_local $13
- (i32.and
- (i32.shr_u
- (get_local $6)
- (get_local $0)
- )
- (get_local $9)
- )
- )
- (set_local $10
- (i32.const 0)
- )
- (set_local $0
- (i32.shl
- (get_local $8)
- (get_local $1)
- )
- )
- (br $do-once$0)
- )
- )
- (if
- (i32.eqz
- (get_local $4)
- )
- (block
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.const 0)
- )
- )
- )
- (i32.store
- (get_local $4)
- (i32.or
- (i32.const 0)
- (i32.and
- (get_local $0)
- (i32.const -1)
- )
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.or
- (get_local $9)
- (i32.and
- (get_local $1)
- (i32.const 0)
- )
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.const 0)
- )
- )
- )
- (if
- (i32.ne
- (i32.and
- (tee_local $7
- (i32.sub
- (get_local $5)
- (i32.const 1)
- )
- )
- (get_local $5)
- )
- (i32.const 0)
- )
- (block
- (set_local $1
- (i32.sub
- (i32.const 64)
- (tee_local $0
- (i32.sub
- (i32.add
- (i32.clz
- (get_local $5)
- )
- (i32.const 33)
- )
- (i32.clz
- (get_local $6)
- )
- )
- )
- )
- )
- (set_local $5
- (i32.shr_s
- (tee_local $9
- (i32.sub
- (i32.const 32)
- (get_local $0)
- )
- )
- (i32.const 31)
- )
- )
- (set_local $10
- (i32.shr_s
- (tee_local $7
- (i32.sub
- (get_local $0)
- (i32.const 32)
- )
- )
- (i32.const 31)
- )
- )
- (set_local $12
- (get_local $0)
- )
- (set_local $11
- (i32.or
- (i32.and
- (i32.shr_s
- (i32.sub
- (get_local $9)
- (i32.const 1)
- )
- (i32.const 31)
- )
- (i32.shr_u
- (get_local $6)
- (get_local $7)
- )
- )
- (i32.and
- (i32.or
- (i32.shl
- (get_local $6)
- (get_local $9)
- )
- (i32.shr_u
- (get_local $8)
- (get_local $0)
- )
- )
- (get_local $10)
- )
- )
- )
- (set_local $13
- (i32.and
- (get_local $10)
- (i32.shr_u
- (get_local $6)
- (get_local $0)
- )
- )
- )
- (set_local $10
- (i32.and
- (i32.shl
- (get_local $8)
- (get_local $1)
- )
- (get_local $5)
- )
- )
- (set_local $0
- (i32.or
- (i32.and
- (i32.or
- (i32.shl
- (get_local $6)
- (get_local $1)
- )
- (i32.shr_u
- (get_local $8)
- (get_local $7)
- )
- )
- (get_local $5)
- )
- (i32.and
- (i32.shl
- (get_local $8)
- (get_local $9)
- )
- (i32.shr_s
- (i32.sub
- (get_local $0)
- (i32.const 33)
- )
- (i32.const 31)
- )
- )
- )
- )
- (br $do-once$0)
- )
- )
- (if
- (i32.ne
- (get_local $4)
- (i32.const 0)
- )
- (block
- (i32.store
- (get_local $4)
- (i32.and
- (get_local $7)
- (get_local $8)
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.const 0)
- )
- )
- )
- (if
- (i32.eq
- (get_local $5)
- (i32.const 1)
- )
- (block
- (set_global $tempRet0
- (i32.or
- (get_local $9)
- (i32.and
- (get_local $1)
- (i32.const 0)
- )
- )
- )
- (return
- (i32.or
- (i32.const 0)
- (i32.and
- (get_local $0)
- (i32.const -1)
- )
- )
- )
- )
- (block
- (set_global $tempRet0
- (i32.or
- (i32.const 0)
- (i32.shr_u
- (get_local $6)
- (tee_local $0
- (i32.ctz
- (get_local $5)
- )
- )
- )
- )
- )
- (return
- (i32.or
- (i32.shl
- (get_local $6)
- (i32.sub
- (i32.const 32)
- (get_local $0)
- )
- )
- (i32.shr_u
- (get_local $8)
- (get_local $0)
- )
- )
- )
- )
- )
+ (set_local $y64
+ (i64.or
+ (i64.extend_u/i32
+ (get_local $yl)
)
- (block
- (if
- (get_local $10)
- (block
- (if
- (i32.ne
- (get_local $4)
- (i32.const 0)
- )
- (block
- (i32.store
- (get_local $4)
- (i32.rem_u
- (get_local $6)
- (get_local $5)
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.const 0)
- )
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.div_u
- (get_local $6)
- (get_local $5)
- )
- )
- )
- )
- (if
- (i32.eqz
- (get_local $8)
- )
- (block
- (if
- (i32.ne
- (get_local $4)
- (i32.const 0)
- )
- (block
- (i32.store
- (get_local $4)
- (i32.const 0)
- )
- (i32.store offset=4
- (get_local $4)
- (i32.rem_u
- (get_local $6)
- (get_local $7)
- )
- )
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.div_u
- (get_local $6)
- (get_local $7)
- )
- )
- )
- )
- (if
- (i32.eqz
- (i32.and
- (tee_local $5
- (i32.sub
- (get_local $7)
- (i32.const 1)
- )
- )
- (get_local $7)
- )
- )
- (block
- (if
- (i32.ne
- (get_local $4)
- (i32.const 0)
- )
- (block
- (i32.store
- (get_local $4)
- (i32.or
- (i32.const 0)
- (i32.and
- (get_local $0)
- (i32.const -1)
- )
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.or
- (i32.and
- (get_local $5)
- (get_local $6)
- )
- (i32.and
- (get_local $1)
- (i32.const 0)
- )
- )
- )
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.shr_u
- (get_local $6)
- (i32.ctz
- (get_local $7)
- )
- )
- )
- )
- )
- (if
- (i32.le_u
- (tee_local $5
- (i32.sub
- (i32.clz
- (get_local $7)
- )
- (i32.clz
- (get_local $6)
- )
- )
- )
- (i32.const 30)
- )
- (block
- (set_local $12
- (tee_local $0
- (i32.add
- (get_local $5)
- (i32.const 1)
- )
- )
- )
- (set_local $11
- (i32.or
- (i32.shl
- (get_local $6)
- (tee_local $1
- (i32.sub
- (i32.const 31)
- (get_local $5)
- )
- )
- )
- (i32.shr_u
- (get_local $8)
- (get_local $0)
- )
- )
- )
- (set_local $13
- (i32.shr_u
- (get_local $6)
- (get_local $0)
- )
- )
- (set_local $10
- (i32.const 0)
- )
- (set_local $0
- (i32.shl
- (get_local $8)
- (get_local $1)
- )
- )
- (br $do-once$0)
- )
- )
- (if
- (i32.eqz
- (get_local $4)
- )
- (block
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.const 0)
- )
- )
- )
- (i32.store
- (get_local $4)
- (i32.or
- (i32.const 0)
- (i32.and
- (get_local $0)
- (i32.const -1)
- )
- )
- )
- (i32.store offset=4
- (get_local $4)
- (i32.or
- (get_local $9)
- (i32.and
- (get_local $1)
- (i32.const 0)
- )
- )
- )
- (set_global $tempRet0
- (i32.const 0)
- )
- (return
- (i32.const 0)
+ (i64.shl
+ (i64.extend_u/i32
+ (get_local $yh)
)
+ (i64.const 32)
)
)
)
- (set_local $0
- (if
- (get_local $12)
- (block
- (set_local $3
- (call $_i64Add
- (tee_local $1
- (i32.or
- (i32.const 0)
- (i32.and
- (get_local $2)
- (i32.const -1)
- )
- )
- )
- (tee_local $2
- (i32.or
- (get_local $14)
- (i32.and
- (get_local $3)
- (i32.const 0)
- )
- )
- )
- (i32.const -1)
- (i32.const -1)
- )
- )
- (set_local $8
- (get_global $tempRet0)
- )
- (set_local $9
- (get_local $0)
- )
- (set_local $0
- (i32.const 0)
- )
- (loop $while-in$3
- (block $while-out$2
- (set_local $6
- (i32.or
- (i32.shr_u
- (get_local $10)
- (i32.const 31)
- )
- (i32.shl
- (get_local $9)
- (i32.const 1)
- )
- )
- )
- (set_local $10
- (i32.or
- (get_local $0)
- (i32.shl
- (get_local $10)
- (i32.const 1)
- )
- )
- )
- (drop
- (call $_i64Subtract
- (get_local $3)
- (get_local $8)
- (tee_local $0
- (i32.or
- (i32.const 0)
- (i32.or
- (i32.shl
- (get_local $11)
- (i32.const 1)
- )
- (i32.shr_u
- (get_local $9)
- (i32.const 31)
- )
- )
- )
- )
- (tee_local $9
- (i32.or
- (i32.shr_u
- (get_local $11)
- (i32.const 31)
- )
- (i32.shl
- (get_local $13)
- (i32.const 1)
- )
- )
- )
- )
- )
- (set_local $7
- (i32.and
- (tee_local $14
- (i32.or
- (i32.shr_s
- (tee_local $5
- (get_global $tempRet0)
- )
- (i32.const 31)
- )
- (i32.shl
- (select
- (i32.const -1)
- (i32.const 0)
- (i32.lt_s
- (get_local $5)
- (i32.const 0)
- )
- )
- (i32.const 1)
- )
- )
- )
- (i32.const 1)
- )
- )
- (set_local $11
- (call $_i64Subtract
- (get_local $0)
- (get_local $9)
- (i32.and
- (get_local $14)
- (get_local $1)
- )
- (i32.and
- (i32.or
- (i32.shr_s
- (select
- (i32.const -1)
- (i32.const 0)
- (i32.lt_s
- (get_local $5)
- (i32.const 0)
- )
- )
- (i32.const 31)
- )
- (i32.shl
- (select
- (i32.const -1)
- (i32.const 0)
- (i32.lt_s
- (get_local $5)
- (i32.const 0)
- )
- )
- (i32.const 1)
- )
- )
- (get_local $2)
- )
- )
- )
- (set_local $13
- (get_global $tempRet0)
- )
- (if
- (tee_local $12
- (i32.sub
- (get_local $12)
- (i32.const 1)
- )
- )
- (block
- (set_local $9
- (get_local $6)
- )
- (set_local $0
- (get_local $7)
- )
- )
- (br $while-out$2)
- )
- (br $while-in$3)
- )
- )
- (set_local $1
- (i32.const 0)
- )
- (get_local $7)
- )
- (block
- (set_local $6
- (get_local $0)
- )
- (set_local $1
- (i32.const 0)
- )
- (i32.const 0)
+ (if
+ (get_local $r)
+ (i64.store
+ (get_local $r)
+ (i64.rem_u
+ (get_local $x64)
+ (get_local $y64)
)
)
)
- (set_local $3
- (i32.or
- (get_local $6)
- (tee_local $2
- (i32.const 0)
- )
- )
- )
- (if
- (i32.ne
- (get_local $4)
- (i32.const 0)
- )
- (block
- (i32.store
- (get_local $4)
- (i32.or
- (i32.const 0)
- (get_local $11)
- )
- )
- (i32.store offset=4
- (get_local $4)
- (get_local $13)
- )
+ (set_local $x64
+ (i64.div_u
+ (get_local $x64)
+ (get_local $y64)
)
)
(set_global $tempRet0
- (i32.or
- (i32.or
- (i32.or
- (i32.shr_u
- (i32.or
- (i32.const 0)
- (get_local $10)
- )
- (i32.const 31)
- )
- (i32.shl
- (get_local $3)
- (i32.const 1)
- )
- )
- (i32.and
- (i32.or
- (i32.shl
- (get_local $2)
- (i32.const 1)
- )
- (i32.shr_u
- (get_local $10)
- (i32.const 31)
- )
- )
- (i32.const 0)
- )
+ (i32.wrap/i64
+ (i64.shr_u
+ (get_local $x64)
+ (i64.const 32)
)
- (get_local $1)
)
)
- (i32.or
- (i32.and
- (i32.or
- (i32.shl
- (get_local $10)
- (i32.const 1)
- )
- (i32.const 0)
- )
- (i32.const -2)
- )
- (get_local $0)
+ (i32.wrap/i64
+ (get_local $x64)
)
)
(func $dynCall_ii (param $0 i32) (param $1 i32) (result i32)