mirror of
https://github.com/fluencelabs/assemblyscript
synced 2025-06-21 18:51:43 +00:00
Rework loop compilation / flows (#644)
This commit is contained in:
@ -27,7 +27,7 @@
|
|||||||
global.set $assembly/index/s
|
global.set $assembly/index/s
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
global.get $assembly/index/h
|
global.get $assembly/index/h
|
||||||
@ -35,7 +35,7 @@
|
|||||||
br_if $break|0
|
br_if $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
global.get $assembly/index/w
|
global.get $assembly/index/w
|
||||||
@ -69,14 +69,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
@ -97,7 +97,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $7
|
local.set $7
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
global.get $assembly/index/h
|
global.get $assembly/index/h
|
||||||
@ -121,7 +121,7 @@
|
|||||||
local.set $5
|
local.set $5
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
global.get $assembly/index/w
|
global.get $assembly/index/w
|
||||||
@ -341,20 +341,20 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
(func $assembly/index/fill (; 3 ;) (type $FUNCSIG$viid) (param $0 i32) (param $1 i32) (param $2 f64)
|
(func $assembly/index/fill (; 3 ;) (type $FUNCSIG$viid) (param $0 i32) (param $1 i32) (param $2 f64)
|
||||||
(local $3 i32)
|
(local $3 i32)
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $3
|
local.get $3
|
||||||
global.get $assembly/index/w
|
global.get $assembly/index/w
|
||||||
@ -382,12 +382,12 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $3
|
local.get $3
|
||||||
global.get $assembly/index/h
|
global.get $assembly/index/h
|
||||||
@ -415,7 +415,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $2
|
local.get $2
|
||||||
global.get $assembly/index/h
|
global.get $assembly/index/h
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -43,13 +43,12 @@
|
|||||||
block $break|1
|
block $break|1
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $3
|
local.get $3
|
||||||
global.get $assembly/index/w
|
global.get $assembly/index/w
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
i32.eqz
|
i32.eqz
|
||||||
br_if $break|1
|
br_if $break|1
|
||||||
block $assembly/index/set|inlined.0
|
|
||||||
local.get $3
|
local.get $3
|
||||||
local.set $6
|
local.set $6
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -78,13 +77,11 @@
|
|||||||
i32.shl
|
i32.shl
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.store
|
i32.store
|
||||||
end
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -92,8 +89,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -127,7 +123,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $2
|
local.get $2
|
||||||
global.get $assembly/index/h
|
global.get $assembly/index/h
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -158,7 +154,7 @@
|
|||||||
block $break|1
|
block $break|1
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $5
|
local.set $5
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $5
|
local.get $5
|
||||||
global.get $assembly/index/w
|
global.get $assembly/index/w
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -186,7 +182,6 @@
|
|||||||
i32.add
|
i32.add
|
||||||
end
|
end
|
||||||
local.set $7
|
local.set $7
|
||||||
block $assembly/index/get|inlined.0 (result i32)
|
|
||||||
local.get $6
|
local.get $6
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -199,10 +194,8 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
block $assembly/index/get|inlined.1 (result i32)
|
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -215,11 +208,9 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
block $assembly/index/get|inlined.2 (result i32)
|
|
||||||
local.get $7
|
local.get $7
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -232,11 +223,9 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
block $assembly/index/get|inlined.3 (result i32)
|
|
||||||
local.get $6
|
local.get $6
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -249,11 +238,9 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
block $assembly/index/get|inlined.4 (result i32)
|
|
||||||
local.get $7
|
local.get $7
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -266,11 +253,9 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
block $assembly/index/get|inlined.5 (result i32)
|
|
||||||
local.get $6
|
local.get $6
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $4
|
local.get $4
|
||||||
@ -283,11 +268,9 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
block $assembly/index/get|inlined.6 (result i32)
|
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $4
|
local.get $4
|
||||||
@ -300,11 +283,9 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
block $assembly/index/get|inlined.7 (result i32)
|
|
||||||
local.get $7
|
local.get $7
|
||||||
local.set $9
|
local.set $9
|
||||||
local.get $4
|
local.get $4
|
||||||
@ -317,12 +298,10 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
i32.add
|
i32.add
|
||||||
local.set $9
|
local.set $9
|
||||||
block $assembly/index/get|inlined.8 (result i32)
|
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $10
|
local.set $10
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -335,7 +314,6 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.shl
|
i32.shl
|
||||||
i32.load
|
i32.load
|
||||||
end
|
|
||||||
local.set $10
|
local.set $10
|
||||||
local.get $10
|
local.get $10
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -366,7 +344,6 @@
|
|||||||
i32.gt_s
|
i32.gt_s
|
||||||
select
|
select
|
||||||
local.set $13
|
local.set $13
|
||||||
block $assembly/index/set|inlined.1
|
|
||||||
local.get $12
|
local.get $12
|
||||||
local.set $16
|
local.set $16
|
||||||
local.get $11
|
local.get $11
|
||||||
@ -390,7 +367,6 @@
|
|||||||
i32.shl
|
i32.shl
|
||||||
local.get $14
|
local.get $14
|
||||||
i32.store
|
i32.store
|
||||||
end
|
|
||||||
else
|
else
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $16
|
local.set $16
|
||||||
@ -456,7 +432,6 @@
|
|||||||
i32.gt_s
|
i32.gt_s
|
||||||
select
|
select
|
||||||
local.set $12
|
local.set $12
|
||||||
block $assembly/index/set|inlined.4
|
|
||||||
local.get $15
|
local.get $15
|
||||||
local.set $11
|
local.set $11
|
||||||
local.get $14
|
local.get $14
|
||||||
@ -482,13 +457,11 @@
|
|||||||
i32.store
|
i32.store
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $5
|
local.set $5
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -496,8 +469,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -510,7 +482,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $3
|
local.get $3
|
||||||
global.get $assembly/index/w
|
global.get $assembly/index/w
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -544,15 +516,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|1
|
block $break|1
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $3
|
local.get $3
|
||||||
global.get $assembly/index/h
|
global.get $assembly/index/h
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -586,8 +557,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
2
examples/mandelbrot/build/optimized.d.ts
vendored
2
examples/mandelbrot/build/optimized.d.ts
vendored
@ -8,6 +8,6 @@ declare module ASModule {
|
|||||||
type f32 = number;
|
type f32 = number;
|
||||||
type f64 = number;
|
type f64 = number;
|
||||||
type bool = any;
|
type bool = any;
|
||||||
function computeLine(y: u32, width: u32, height: u32, limit: u32): void;
|
export function computeLine(y: u32, width: u32, height: u32, limit: u32): void;
|
||||||
}
|
}
|
||||||
export default ASModule;
|
export default ASModule;
|
||||||
|
Binary file not shown.
@ -25,7 +25,6 @@
|
|||||||
local.tee $9
|
local.tee $9
|
||||||
f64.const 0.625
|
f64.const 0.625
|
||||||
f64.mul
|
f64.mul
|
||||||
local.set $4
|
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.convert_i32_u
|
f64.convert_i32_u
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -46,7 +45,6 @@
|
|||||||
local.tee $10
|
local.tee $10
|
||||||
f64.mul
|
f64.mul
|
||||||
local.set $11
|
local.set $11
|
||||||
local.get $4
|
|
||||||
local.get $10
|
local.get $10
|
||||||
f64.mul
|
f64.mul
|
||||||
local.set $13
|
local.set $13
|
||||||
@ -66,7 +64,7 @@
|
|||||||
local.get $6
|
local.get $6
|
||||||
f64.min
|
f64.min
|
||||||
local.set $15
|
local.set $15
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $8
|
local.get $8
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -86,6 +84,7 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $7
|
local.set $7
|
||||||
loop $continue|1
|
loop $continue|1
|
||||||
|
block $break|1
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $4
|
local.get $4
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -97,8 +96,8 @@
|
|||||||
f64.add
|
f64.add
|
||||||
f64.const 4
|
f64.const 4
|
||||||
f64.le
|
f64.le
|
||||||
if
|
i32.eqz
|
||||||
block $break|1
|
br_if $break|1
|
||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $4
|
local.get $4
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -124,7 +123,6 @@
|
|||||||
br $continue|1
|
br $continue|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
|
||||||
loop $continue|2
|
loop $continue|2
|
||||||
local.get $7
|
local.get $7
|
||||||
f64.convert_i32_u
|
f64.convert_i32_u
|
||||||
@ -140,7 +138,6 @@
|
|||||||
f64.sub
|
f64.sub
|
||||||
local.get $12
|
local.get $12
|
||||||
f64.add
|
f64.add
|
||||||
local.set $6
|
|
||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $4
|
local.get $4
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -149,7 +146,6 @@
|
|||||||
local.get $11
|
local.get $11
|
||||||
f64.add
|
f64.add
|
||||||
local.set $5
|
local.set $5
|
||||||
local.get $6
|
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -203,7 +199,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $8
|
local.set $8
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
@ -88,7 +88,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $12
|
local.set $12
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $12
|
local.get $12
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -120,7 +120,8 @@
|
|||||||
f64.add
|
f64.add
|
||||||
f64.const 4
|
f64.const 4
|
||||||
f64.le
|
f64.le
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|1
|
||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $14
|
local.get $14
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -147,7 +148,7 @@
|
|||||||
local.set $18
|
local.set $18
|
||||||
br $continue|1
|
br $continue|1
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|2
|
block $break|2
|
||||||
loop $continue|2
|
loop $continue|2
|
||||||
@ -155,7 +156,8 @@
|
|||||||
f64.convert_i32_u
|
f64.convert_i32_u
|
||||||
local.get $11
|
local.get $11
|
||||||
f64.lt
|
f64.lt
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|2
|
||||||
local.get $14
|
local.get $14
|
||||||
local.get $14
|
local.get $14
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -182,7 +184,7 @@
|
|||||||
local.set $18
|
local.set $18
|
||||||
br $continue|2
|
br $continue|2
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
global.get $assembly/index/NUM_COLORS
|
global.get $assembly/index/NUM_COLORS
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -210,7 +212,6 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
f64.convert_i32_s
|
f64.convert_i32_s
|
||||||
block $assembly/index/clamp<f64>|inlined.0 (result f64)
|
|
||||||
local.get $18
|
local.get $18
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
@ -229,7 +230,6 @@
|
|||||||
f64.max
|
f64.max
|
||||||
local.get $22
|
local.get $22
|
||||||
f64.min
|
f64.min
|
||||||
end
|
|
||||||
f64.mul
|
f64.mul
|
||||||
i32.trunc_f64_u
|
i32.trunc_f64_u
|
||||||
local.set $20
|
local.set $20
|
||||||
@ -245,8 +245,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $12
|
local.set $12
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -50,7 +50,7 @@ function asmFunc(global, env, buffer) {
|
|||||||
function assembly_index_NBodySystem_constructor($0) {
|
function assembly_index_NBodySystem_constructor($0) {
|
||||||
var $1 = 0, $2 = 0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0;
|
var $1 = 0, $2 = 0, $3 = 0.0, $4 = 0.0, $5 = 0.0, $6 = 0.0, $7 = 0;
|
||||||
$7 = HEAP32[($0 + 12 | 0) >> 2];
|
$7 = HEAP32[($0 + 12 | 0) >> 2];
|
||||||
repeat_0 : while (1) {
|
loop_0 : while (1) {
|
||||||
if (($1 | 0) < ($7 | 0)) {
|
if (($1 | 0) < ($7 | 0)) {
|
||||||
$2 = HEAP32[(HEAP32[($0 + 4 | 0) >> 2] + ($1 << 2 | 0) | 0) >> 2];
|
$2 = HEAP32[(HEAP32[($0 + 4 | 0) >> 2] + ($1 << 2 | 0) | 0) >> 2];
|
||||||
$3 = HEAPF64[($2 + 48 | 0) >> 3];
|
$3 = HEAPF64[($2 + 48 | 0) >> 3];
|
||||||
@ -58,9 +58,9 @@ function asmFunc(global, env, buffer) {
|
|||||||
$5 = $5 + HEAPF64[($2 + 32 | 0) >> 3] * $3;
|
$5 = $5 + HEAPF64[($2 + 32 | 0) >> 3] * $3;
|
||||||
$6 = $6 + HEAPF64[($2 + 40 | 0) >> 3] * $3;
|
$6 = $6 + HEAPF64[($2 + 40 | 0) >> 3] * $3;
|
||||||
$1 = $1 + 1 | 0;
|
$1 = $1 + 1 | 0;
|
||||||
continue repeat_0;
|
continue loop_0;
|
||||||
}
|
}
|
||||||
break repeat_0;
|
break loop_0;
|
||||||
};
|
};
|
||||||
$1 = HEAP32[HEAP32[($0 + 4 | 0) >> 2] >> 2];
|
$1 = HEAP32[HEAP32[($0 + 4 | 0) >> 2] >> 2];
|
||||||
HEAPF64[($1 + 24 | 0) >> 3] = -$4 / 39.47841760435743;
|
HEAPF64[($1 + 24 | 0) >> 3] = -$4 / 39.47841760435743;
|
||||||
@ -111,7 +111,7 @@ function asmFunc(global, env, buffer) {
|
|||||||
var $1 = 0, $2 = 0.0, $3 = 0.0, $4 = 0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0, $9 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0, $13 = 0, $14 = 0.0, $15 = 0.0, $16 = 0.0, $17 = 0.0;
|
var $1 = 0, $2 = 0.0, $3 = 0.0, $4 = 0, $5 = 0.0, $6 = 0.0, $7 = 0.0, $8 = 0, $9 = 0.0, $10 = 0.0, $11 = 0.0, $12 = 0, $13 = 0, $14 = 0.0, $15 = 0.0, $16 = 0.0, $17 = 0.0;
|
||||||
$12 = HEAP32[$0 >> 2];
|
$12 = HEAP32[$0 >> 2];
|
||||||
$13 = HEAP32[($12 + 12 | 0) >> 2];
|
$13 = HEAP32[($12 + 12 | 0) >> 2];
|
||||||
repeat_0 : while (1) {
|
loop_0 : while (1) {
|
||||||
if ($4 >>> 0 < $13 >>> 0) {
|
if ($4 >>> 0 < $13 >>> 0) {
|
||||||
$0 = HEAP32[(HEAP32[($12 + 4 | 0) >> 2] + ($4 << 2 | 0) | 0) >> 2];
|
$0 = HEAP32[(HEAP32[($12 + 4 | 0) >> 2] + ($4 << 2 | 0) | 0) >> 2];
|
||||||
$14 = HEAPF64[$0 >> 3];
|
$14 = HEAPF64[$0 >> 3];
|
||||||
@ -122,7 +122,7 @@ function asmFunc(global, env, buffer) {
|
|||||||
$7 = HEAPF64[($0 + 40 | 0) >> 3];
|
$7 = HEAPF64[($0 + 40 | 0) >> 3];
|
||||||
$17 = HEAPF64[($0 + 48 | 0) >> 3];
|
$17 = HEAPF64[($0 + 48 | 0) >> 3];
|
||||||
$8 = $4 + 1 | 0;
|
$8 = $4 + 1 | 0;
|
||||||
repeat_1 : while (1) {
|
loop_1 : while (1) {
|
||||||
if ($8 >>> 0 < $13 >>> 0) {
|
if ($8 >>> 0 < $13 >>> 0) {
|
||||||
$1 = HEAP32[(HEAP32[($12 + 4 | 0) >> 2] + ($8 << 2 | 0) | 0) >> 2];
|
$1 = HEAP32[(HEAP32[($12 + 4 | 0) >> 2] + ($8 << 2 | 0) | 0) >> 2];
|
||||||
$2 = $14 - HEAPF64[$1 >> 3];
|
$2 = $14 - HEAPF64[$1 >> 3];
|
||||||
@ -141,9 +141,9 @@ function asmFunc(global, env, buffer) {
|
|||||||
HEAPF64[($1 + 32 | 0) >> 3] = HEAPF64[($1 + 32 | 0) >> 3] + $9 * $2;
|
HEAPF64[($1 + 32 | 0) >> 3] = HEAPF64[($1 + 32 | 0) >> 3] + $9 * $2;
|
||||||
HEAPF64[($1 + 40 | 0) >> 3] = HEAPF64[($1 + 40 | 0) >> 3] + $10 * $2;
|
HEAPF64[($1 + 40 | 0) >> 3] = HEAPF64[($1 + 40 | 0) >> 3] + $10 * $2;
|
||||||
$8 = $8 + 1 | 0;
|
$8 = $8 + 1 | 0;
|
||||||
continue repeat_1;
|
continue loop_1;
|
||||||
}
|
}
|
||||||
break repeat_1;
|
break loop_1;
|
||||||
};
|
};
|
||||||
HEAPF64[($0 + 24 | 0) >> 3] = $5;
|
HEAPF64[($0 + 24 | 0) >> 3] = $5;
|
||||||
HEAPF64[($0 + 32 | 0) >> 3] = $6;
|
HEAPF64[($0 + 32 | 0) >> 3] = $6;
|
||||||
@ -152,9 +152,9 @@ function asmFunc(global, env, buffer) {
|
|||||||
HEAPF64[($0 + 8 | 0) >> 3] = HEAPF64[($0 + 8 | 0) >> 3] + .01 * $6;
|
HEAPF64[($0 + 8 | 0) >> 3] = HEAPF64[($0 + 8 | 0) >> 3] + .01 * $6;
|
||||||
HEAPF64[($0 + 16 | 0) >> 3] = HEAPF64[($0 + 16 | 0) >> 3] + .01 * $7;
|
HEAPF64[($0 + 16 | 0) >> 3] = HEAPF64[($0 + 16 | 0) >> 3] + .01 * $7;
|
||||||
$4 = $4 + 1 | 0;
|
$4 = $4 + 1 | 0;
|
||||||
continue repeat_0;
|
continue loop_0;
|
||||||
}
|
}
|
||||||
break repeat_0;
|
break loop_0;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -162,7 +162,7 @@ function asmFunc(global, env, buffer) {
|
|||||||
var $1 = 0.0, $2 = 0.0, $3 = 0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0, $8 = 0.0, $9 = 0.0, $10 = 0.0, $11 = 0.0;
|
var $1 = 0.0, $2 = 0.0, $3 = 0, $4 = 0, $5 = 0, $6 = 0.0, $7 = 0, $8 = 0.0, $9 = 0.0, $10 = 0.0, $11 = 0.0;
|
||||||
$5 = HEAP32[$0 >> 2];
|
$5 = HEAP32[$0 >> 2];
|
||||||
$7 = HEAP32[($5 + 12 | 0) >> 2];
|
$7 = HEAP32[($5 + 12 | 0) >> 2];
|
||||||
repeat_0 : while (1) {
|
loop_0 : while (1) {
|
||||||
if ($3 >>> 0 < $7 >>> 0) {
|
if ($3 >>> 0 < $7 >>> 0) {
|
||||||
$0 = HEAP32[(HEAP32[($5 + 4 | 0) >> 2] + ($3 << 2 | 0) | 0) >> 2];
|
$0 = HEAP32[(HEAP32[($5 + 4 | 0) >> 2] + ($3 << 2 | 0) | 0) >> 2];
|
||||||
$9 = HEAPF64[$0 >> 3];
|
$9 = HEAPF64[$0 >> 3];
|
||||||
@ -177,7 +177,7 @@ function asmFunc(global, env, buffer) {
|
|||||||
$1 = HEAPF64[($0 + 40 | 0) >> 3];
|
$1 = HEAPF64[($0 + 40 | 0) >> 3];
|
||||||
$1 = $6 + .5 * $8 * ($2 + $1 * $1);
|
$1 = $6 + .5 * $8 * ($2 + $1 * $1);
|
||||||
$0 = $3 + 1 | 0;
|
$0 = $3 + 1 | 0;
|
||||||
repeat_1 : while (1) {
|
loop_1 : while (1) {
|
||||||
if ($0 >>> 0 < $7 >>> 0) {
|
if ($0 >>> 0 < $7 >>> 0) {
|
||||||
$4 = HEAP32[(HEAP32[($5 + 4 | 0) >> 2] + ($0 << 2 | 0) | 0) >> 2];
|
$4 = HEAP32[(HEAP32[($5 + 4 | 0) >> 2] + ($0 << 2 | 0) | 0) >> 2];
|
||||||
$6 = $1;
|
$6 = $1;
|
||||||
@ -188,14 +188,14 @@ function asmFunc(global, env, buffer) {
|
|||||||
$1 = $11 - HEAPF64[($4 + 16 | 0) >> 3];
|
$1 = $11 - HEAPF64[($4 + 16 | 0) >> 3];
|
||||||
$1 = $6 - $8 * HEAPF64[($4 + 48 | 0) >> 3] / Math_sqrt($2 + $1 * $1);
|
$1 = $6 - $8 * HEAPF64[($4 + 48 | 0) >> 3] / Math_sqrt($2 + $1 * $1);
|
||||||
$0 = $0 + 1 | 0;
|
$0 = $0 + 1 | 0;
|
||||||
continue repeat_1;
|
continue loop_1;
|
||||||
}
|
}
|
||||||
break repeat_1;
|
break loop_1;
|
||||||
};
|
};
|
||||||
$3 = $3 + 1 | 0;
|
$3 = $3 + 1 | 0;
|
||||||
continue repeat_0;
|
continue loop_0;
|
||||||
}
|
}
|
||||||
break repeat_0;
|
break loop_0;
|
||||||
};
|
};
|
||||||
return $1;
|
return $1;
|
||||||
}
|
}
|
||||||
@ -208,13 +208,13 @@ function asmFunc(global, env, buffer) {
|
|||||||
function assembly_index_bench($0) {
|
function assembly_index_bench($0) {
|
||||||
$0 = $0 | 0;
|
$0 = $0 | 0;
|
||||||
var $1 = 0;
|
var $1 = 0;
|
||||||
repeat_0 : while (1) {
|
loop_0 : while (1) {
|
||||||
if (!($1 >>> 0 >= $0 >>> 0)) {
|
if (!($1 >>> 0 >= $0 >>> 0)) {
|
||||||
assembly_index_NBodySystem_advance(assembly_index_system);
|
assembly_index_NBodySystem_advance(assembly_index_system);
|
||||||
$1 = $1 + 1 | 0;
|
$1 = $1 + 1 | 0;
|
||||||
continue repeat_0;
|
continue loop_0;
|
||||||
}
|
}
|
||||||
break repeat_0;
|
break loop_0;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -102,7 +102,7 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
local.set $7
|
local.set $7
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $1
|
local.get $1
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -142,7 +142,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -308,7 +308,7 @@
|
|||||||
local.tee $12
|
local.tee $12
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
local.set $13
|
local.set $13
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $13
|
local.get $13
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -345,7 +345,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $7
|
local.set $7
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $7
|
local.get $7
|
||||||
local.get $13
|
local.get $13
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -441,7 +441,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $7
|
local.set $7
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -481,7 +481,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
@ -501,7 +501,7 @@
|
|||||||
local.tee $4
|
local.tee $4
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
local.set $5
|
local.set $5
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -552,7 +552,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -601,14 +601,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -622,7 +622,7 @@
|
|||||||
(func $assembly/index/bench (; 8 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $assembly/index/bench (; 8 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block $break|0
|
block $break|0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $1
|
local.get $1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
@ -633,8 +633,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
File diff suppressed because it is too large
Load Diff
62
lib/i64/build/optimized.d.ts
vendored
62
lib/i64/build/optimized.d.ts
vendored
@ -8,36 +8,36 @@ declare module ASModule {
|
|||||||
type f32 = number;
|
type f32 = number;
|
||||||
type f64 = number;
|
type f64 = number;
|
||||||
type bool = any;
|
type bool = any;
|
||||||
function getLo(): u32;
|
export function getLo(): u32;
|
||||||
function getHi(): u32;
|
export function getHi(): u32;
|
||||||
function clz(loLeft: u32, hiLeft: u32): void;
|
export function clz(loLeft: u32, hiLeft: u32): void;
|
||||||
function ctz(loLeft: u32, hiLeft: u32): void;
|
export function ctz(loLeft: u32, hiLeft: u32): void;
|
||||||
function popcnt(loLeft: u32, hiLeft: u32): void;
|
export function popcnt(loLeft: u32, hiLeft: u32): void;
|
||||||
function eqz(loLeft: u32, hiLeft: u32): void;
|
export function eqz(loLeft: u32, hiLeft: u32): void;
|
||||||
function add(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function add(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function sub(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function sub(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function mul(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function mul(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function div_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function div_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function div_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function div_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function rem_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function rem_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function rem_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function rem_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function and(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function and(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function or(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function or(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function xor(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function xor(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function shl(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function shl(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function shr_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function shr_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function shr_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function shr_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function rotl(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function rotl(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function rotr(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function rotr(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function eq(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function eq(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function ne(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function ne(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function lt_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function lt_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function lt_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function lt_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function le_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function le_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function le_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function le_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function gt_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function gt_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function gt_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function gt_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function ge_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function ge_s(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
function ge_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
export function ge_u(loLeft: u32, hiLeft: u32, loRight: u32, hiRight: u32): void;
|
||||||
}
|
}
|
||||||
export default ASModule;
|
export default ASModule;
|
||||||
|
@ -2174,10 +2174,8 @@
|
|||||||
i64.lt_u
|
i64.lt_u
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
local.set $11
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $11
|
|
||||||
local.set $2
|
local.set $2
|
||||||
end
|
end
|
||||||
local.get $4
|
local.get $4
|
||||||
|
@ -2382,10 +2382,8 @@
|
|||||||
i32.lt_u
|
i32.lt_u
|
||||||
if
|
if
|
||||||
local.get $3
|
local.get $3
|
||||||
local.set $6
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.set $3
|
local.set $3
|
||||||
local.get $6
|
|
||||||
local.set $2
|
local.set $2
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
|
@ -236,12 +236,10 @@
|
|||||||
global.get $assembly/index/off
|
global.get $assembly/index/off
|
||||||
local.tee $1
|
local.tee $1
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
local.set $0
|
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $assembly/index/off
|
global.set $assembly/index/off
|
||||||
local.get $0
|
|
||||||
i32.const 11
|
i32.const 11
|
||||||
i32.ne
|
i32.ne
|
||||||
if
|
if
|
||||||
@ -267,12 +265,10 @@
|
|||||||
global.get $assembly/index/off
|
global.get $assembly/index/off
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.load
|
i32.load
|
||||||
local.set $2
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
global.set $assembly/index/off
|
global.set $assembly/index/off
|
||||||
local.get $2
|
|
||||||
i32.const 1836278016
|
i32.const 1836278016
|
||||||
i32.ne
|
i32.ne
|
||||||
if
|
if
|
||||||
@ -281,12 +277,10 @@
|
|||||||
global.get $assembly/index/off
|
global.get $assembly/index/off
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.load
|
i32.load
|
||||||
local.set $2
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
global.set $assembly/index/off
|
global.set $assembly/index/off
|
||||||
local.get $2
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.ne
|
i32.ne
|
||||||
if
|
if
|
||||||
@ -368,7 +362,7 @@
|
|||||||
local.set $4
|
local.set $4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -383,7 +377,7 @@
|
|||||||
local.set $5
|
local.set $5
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -399,14 +393,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
call $assembly/index/readVaruint
|
call $assembly/index/readVaruint
|
||||||
local.set $5
|
local.set $5
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|4
|
loop $loop|4
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -422,14 +416,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|4
|
br $loop|4
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -438,7 +432,7 @@
|
|||||||
local.set $7
|
local.set $7
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $4
|
local.set $4
|
||||||
loop $repeat|5
|
loop $loop|5
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -560,7 +554,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $4
|
local.set $4
|
||||||
br $repeat|5
|
br $loop|5
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -569,7 +563,7 @@
|
|||||||
local.set $4
|
local.set $4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|7
|
loop $loop|7
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -586,7 +580,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|7
|
br $loop|7
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -595,7 +589,7 @@
|
|||||||
local.set $7
|
local.set $7
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $4
|
local.set $4
|
||||||
loop $repeat|8
|
loop $loop|8
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -628,7 +622,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $4
|
local.set $4
|
||||||
br $repeat|8
|
br $loop|8
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -637,7 +631,7 @@
|
|||||||
local.set $6
|
local.set $6
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|9
|
loop $loop|9
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $6
|
local.get $6
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -665,7 +659,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|9
|
br $loop|9
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -674,7 +668,7 @@
|
|||||||
local.set $4
|
local.set $4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|10
|
loop $loop|10
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -700,7 +694,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|10
|
br $loop|10
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -709,7 +703,7 @@
|
|||||||
local.set $3
|
local.set $3
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|11
|
loop $loop|11
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -738,7 +732,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|11
|
br $loop|11
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|1
|
br $break|1
|
||||||
@ -762,9 +756,7 @@
|
|||||||
call $assembly/index/readVaruint
|
call $assembly/index/readVaruint
|
||||||
local.set $2
|
local.set $2
|
||||||
call $assembly/index/readVaruint
|
call $assembly/index/readVaruint
|
||||||
local.set $4
|
|
||||||
global.get $assembly/index/off
|
global.get $assembly/index/off
|
||||||
local.set $5
|
|
||||||
block $break|12
|
block $break|12
|
||||||
block $case3|12
|
block $case3|12
|
||||||
block $case2|12
|
block $case2|12
|
||||||
@ -792,20 +784,18 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|13
|
loop $loop|13
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
if
|
if
|
||||||
call $assembly/index/readVaruint
|
call $assembly/index/readVaruint
|
||||||
local.set $6
|
|
||||||
call $assembly/index/readVaruint
|
call $assembly/index/readVaruint
|
||||||
local.tee $7
|
local.tee $7
|
||||||
global.get $assembly/index/off
|
global.get $assembly/index/off
|
||||||
local.tee $8
|
local.tee $8
|
||||||
i32.add
|
i32.add
|
||||||
global.set $assembly/index/off
|
global.set $assembly/index/off
|
||||||
local.get $6
|
|
||||||
local.get $8
|
local.get $8
|
||||||
local.get $7
|
local.get $7
|
||||||
call $assembly/options/onFunctionName
|
call $assembly/options/onFunctionName
|
||||||
@ -813,7 +803,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|13
|
br $loop|13
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|12
|
br $break|12
|
||||||
@ -822,7 +812,7 @@
|
|||||||
local.set $6
|
local.set $6
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|14
|
loop $loop|14
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $6
|
local.get $6
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -833,7 +823,7 @@
|
|||||||
local.set $8
|
local.set $8
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|15
|
loop $loop|15
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $8
|
local.get $8
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -855,22 +845,20 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|15
|
br $loop|15
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|14
|
br $loop|14
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
br $break|12
|
br $break|12
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $4
|
|
||||||
local.get $5
|
|
||||||
i32.add
|
i32.add
|
||||||
global.set $assembly/index/off
|
global.set $assembly/index/off
|
||||||
br $break|1
|
br $break|1
|
||||||
|
348
src/compiler.ts
348
src/compiler.ts
@ -38,11 +38,11 @@ import {
|
|||||||
getBlockChildCount,
|
getBlockChildCount,
|
||||||
getBlockChild,
|
getBlockChild,
|
||||||
getBlockName,
|
getBlockName,
|
||||||
needsExplicitUnreachable,
|
|
||||||
getLocalGetIndex,
|
getLocalGetIndex,
|
||||||
FeatureFlags,
|
|
||||||
isLocalTee,
|
isLocalTee,
|
||||||
getLocalSetIndex
|
getLocalSetIndex,
|
||||||
|
FeatureFlags,
|
||||||
|
needsExplicitUnreachable
|
||||||
} from "./module";
|
} from "./module";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
@ -1144,7 +1144,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
);
|
);
|
||||||
if (!stmts) stmts = [ expr ];
|
if (!stmts) stmts = [ expr ];
|
||||||
else stmts.push(expr);
|
else stmts.push(expr);
|
||||||
if (!flow.isAny(FlowFlags.ANY_TERMINATING)) { // TODO: detect if returning an autorelease local?
|
if (!flow.is(FlowFlags.TERMINATES)) { // TODO: detect if returning an autorelease local?
|
||||||
let indexBefore = stmts.length;
|
let indexBefore = stmts.length;
|
||||||
this.performAutoreleases(flow, stmts);
|
this.performAutoreleases(flow, stmts);
|
||||||
this.finishAutoreleases(flow, stmts);
|
this.finishAutoreleases(flow, stmts);
|
||||||
@ -1159,7 +1159,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
}
|
}
|
||||||
if (!canOverflow) flow.set(FlowFlags.RETURNS_WRAPPED);
|
if (!canOverflow) flow.set(FlowFlags.RETURNS_WRAPPED);
|
||||||
if (nonNull) flow.set(FlowFlags.RETURNS_NONNULL);
|
if (nonNull) flow.set(FlowFlags.RETURNS_NONNULL);
|
||||||
flow.set(FlowFlags.RETURNS); // now is terminating
|
flow.set(FlowFlags.RETURNS | FlowFlags.TERMINATES);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1169,7 +1169,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
assert(instance.is(CommonFlags.INSTANCE));
|
assert(instance.is(CommonFlags.INSTANCE));
|
||||||
let classInstance = assert(instance.parent); assert(classInstance.kind == ElementKind.CLASS);
|
let classInstance = assert(instance.parent); assert(classInstance.kind == ElementKind.CLASS);
|
||||||
|
|
||||||
if (!flow.isAny(FlowFlags.ANY_TERMINATING)) {
|
if (!flow.is(FlowFlags.TERMINATES)) {
|
||||||
let thisLocal = assert(flow.lookupLocal(CommonSymbols.this_));
|
let thisLocal = assert(flow.lookupLocal(CommonSymbols.this_));
|
||||||
|
|
||||||
// if `this` wasn't accessed before, allocate if necessary and initialize `this`
|
// if `this` wasn't accessed before, allocate if necessary and initialize `this`
|
||||||
@ -1196,7 +1196,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
this.performAutoreleases(flow, stmts); // `this` is excluded anyway
|
this.performAutoreleases(flow, stmts); // `this` is excluded anyway
|
||||||
this.finishAutoreleases(flow, stmts);
|
this.finishAutoreleases(flow, stmts);
|
||||||
stmts.push(module.local_get(thisLocal.index, this.options.nativeSizeType));
|
stmts.push(module.local_get(thisLocal.index, this.options.nativeSizeType));
|
||||||
flow.set(FlowFlags.RETURNS | FlowFlags.RETURNS_NONNULL);
|
flow.set(FlowFlags.RETURNS | FlowFlags.RETURNS_NONNULL | FlowFlags.TERMINATES);
|
||||||
}
|
}
|
||||||
|
|
||||||
// check that super has been called if this is a derived class
|
// check that super has been called if this is a derived class
|
||||||
@ -1207,8 +1207,8 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
// if this is a normal function, make sure that all branches return
|
// if this is a normal function, make sure that all branches terminate
|
||||||
} else if (returnType != Type.void && !flow.is(FlowFlags.RETURNS)) {
|
} else if (returnType != Type.void && !flow.is(FlowFlags.TERMINATES)) {
|
||||||
this.error(
|
this.error(
|
||||||
DiagnosticCode.A_function_whose_declared_type_is_not_void_must_return_a_value,
|
DiagnosticCode.A_function_whose_declared_type_is_not_void_must_return_a_value,
|
||||||
instance.prototype.signatureNode.returnType.range
|
instance.prototype.signatureNode.returnType.range
|
||||||
@ -1283,7 +1283,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.compileFunctionBody(instance, stmts);
|
this.compileFunctionBody(instance, stmts);
|
||||||
if (!flow.isAny(FlowFlags.ANY_TERMINATING)) {
|
if (!flow.is(FlowFlags.TERMINATES)) {
|
||||||
this.performAutoreleases(flow, stmts);
|
this.performAutoreleases(flow, stmts);
|
||||||
this.finishAutoreleases(flow, stmts);
|
this.finishAutoreleases(flow, stmts);
|
||||||
}
|
}
|
||||||
@ -1780,6 +1780,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
stmts = new Array<ExpressionRef>(numStatements);
|
stmts = new Array<ExpressionRef>(numStatements);
|
||||||
stmts.length = 0;
|
stmts.length = 0;
|
||||||
}
|
}
|
||||||
|
var module = this.module;
|
||||||
var flow = this.currentFlow;
|
var flow = this.currentFlow;
|
||||||
for (let i = 0; i < numStatements; ++i) {
|
for (let i = 0; i < numStatements; ++i) {
|
||||||
let stmt = this.compileStatement(statements[i],
|
let stmt = this.compileStatement(statements[i],
|
||||||
@ -1798,8 +1799,8 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
default: stmts.push(stmt);
|
default: stmts.push(stmt);
|
||||||
case ExpressionId.Nop:
|
case ExpressionId.Nop:
|
||||||
}
|
}
|
||||||
if (flow.isAny(FlowFlags.ANY_TERMINATING)) {
|
if (flow.isAny(FlowFlags.TERMINATES | FlowFlags.BREAKS)) {
|
||||||
if (needsExplicitUnreachable(stmt)) stmts.push(this.module.unreachable());
|
if (needsExplicitUnreachable(stmt)) stmts.push(module.unreachable());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1816,7 +1817,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
this.currentFlow = innerFlow;
|
this.currentFlow = innerFlow;
|
||||||
|
|
||||||
var stmts = this.compileStatements(statements);
|
var stmts = this.compileStatements(statements);
|
||||||
if (!innerFlow.isAny(FlowFlags.ANY_TERMINATING)) this.performAutoreleases(innerFlow, stmts);
|
if (!innerFlow.isAny(FlowFlags.TERMINATES | FlowFlags.BREAKS)) this.performAutoreleases(innerFlow, stmts);
|
||||||
innerFlow.freeScopedLocals();
|
innerFlow.freeScopedLocals();
|
||||||
outerFlow.inherit(innerFlow); // TODO: only if not terminated?
|
outerFlow.inherit(innerFlow); // TODO: only if not terminated?
|
||||||
this.currentFlow = outerFlow;
|
this.currentFlow = outerFlow;
|
||||||
@ -1846,10 +1847,10 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
}
|
}
|
||||||
var stmts = new Array<ExpressionRef>();
|
var stmts = new Array<ExpressionRef>();
|
||||||
this.performAutoreleases(flow, stmts);
|
this.performAutoreleases(flow, stmts);
|
||||||
var current: Flow | null = flow.parent;
|
var parent = flow.parent;
|
||||||
while (current && current.breakLabel === breakLabel) {
|
while (parent !== null && parent.breakLabel == breakLabel) {
|
||||||
this.performAutoreleases(current, stmts, /* clearFlags */ false);
|
this.performAutoreleases(parent, stmts, /* clearFlags */ false);
|
||||||
current = current.parent;
|
parent = parent.parent;
|
||||||
}
|
}
|
||||||
flow.freeScopedLocals();
|
flow.freeScopedLocals();
|
||||||
stmts.push(module.br(breakLabel));
|
stmts.push(module.br(breakLabel));
|
||||||
@ -1880,7 +1881,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
);
|
);
|
||||||
return module.unreachable();
|
return module.unreachable();
|
||||||
}
|
}
|
||||||
flow.set(FlowFlags.CONTINUES);
|
flow.set(FlowFlags.CONTINUES | FlowFlags.TERMINATES);
|
||||||
var stmts = new Array<ExpressionRef>();
|
var stmts = new Array<ExpressionRef>();
|
||||||
this.performAutoreleases(flow, stmts);
|
this.performAutoreleases(flow, stmts);
|
||||||
var current: Flow | null = flow.parent;
|
var current: Flow | null = flow.parent;
|
||||||
@ -1916,18 +1917,44 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
this.compileStatement(statement.statement)
|
this.compileStatement(statement.statement)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
var condExpr = this.makeIsTrueish(
|
var condExpr = module.precomputeExpression(
|
||||||
|
this.makeIsTrueish(
|
||||||
this.compileExpression(statement.condition, Type.i32),
|
this.compileExpression(statement.condition, Type.i32),
|
||||||
this.currentType
|
this.currentType
|
||||||
|
)
|
||||||
);
|
);
|
||||||
// TODO: check if condition is always false and if so, omit it (just a block)
|
var alwaysFalse = false;
|
||||||
|
if (getExpressionId(condExpr) == ExpressionId.Const) {
|
||||||
|
assert(getExpressionType(condExpr) == NativeType.I32);
|
||||||
|
if (!getConstValueI32(condExpr)) alwaysFalse = true;
|
||||||
|
}
|
||||||
|
var terminates = innerFlow.is(FlowFlags.TERMINATES);
|
||||||
|
var continues = innerFlow.isAny(FlowFlags.CONTINUES | FlowFlags.CONDITIONALLY_CONTINUES);
|
||||||
|
var breaks = innerFlow.isAny(FlowFlags.BREAKS | FlowFlags.CONDITIONALLY_BREAKS);
|
||||||
|
|
||||||
|
// (block $break ;; (1) skip if no breaks
|
||||||
|
// (loop $continue ;; (2) skip if skipping (4) + no continues
|
||||||
|
// (...) ;; (3)
|
||||||
|
// (br_if cond $continue) ;; (4) skip if (3) does not fall through or always false
|
||||||
|
// )
|
||||||
|
// )
|
||||||
|
var fallsThrough = !terminates && !innerFlow.is(FlowFlags.BREAKS);
|
||||||
|
|
||||||
|
if (fallsThrough && !alwaysFalse) { // (4)
|
||||||
|
stmts.push(module.br(continueLabel, condExpr));
|
||||||
|
}
|
||||||
|
var expr = flatten(module, stmts, NativeType.None);
|
||||||
|
if (fallsThrough && !alwaysFalse || continues) { // (2)
|
||||||
|
expr = module.loop(continueLabel, expr);
|
||||||
|
}
|
||||||
|
if (breaks) { // (1)
|
||||||
|
expr = module.block(breakLabel, [ expr ]);
|
||||||
|
}
|
||||||
|
|
||||||
// Switch back to the parent flow
|
// Switch back to the parent flow
|
||||||
var terminated = innerFlow.isAny(FlowFlags.ANY_TERMINATING);
|
if (!terminates) this.performAutoreleases(innerFlow, stmts);
|
||||||
if (!terminated) this.performAutoreleases(innerFlow, stmts);
|
|
||||||
innerFlow.freeScopedLocals();
|
innerFlow.freeScopedLocals();
|
||||||
outerFlow.popBreakLabel();
|
outerFlow.popBreakLabel();
|
||||||
this.currentFlow = outerFlow;
|
|
||||||
innerFlow.unset(
|
innerFlow.unset(
|
||||||
FlowFlags.BREAKS |
|
FlowFlags.BREAKS |
|
||||||
FlowFlags.CONDITIONALLY_BREAKS |
|
FlowFlags.CONDITIONALLY_BREAKS |
|
||||||
@ -1935,19 +1962,8 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
FlowFlags.CONDITIONALLY_CONTINUES
|
FlowFlags.CONDITIONALLY_CONTINUES
|
||||||
);
|
);
|
||||||
outerFlow.inherit(innerFlow);
|
outerFlow.inherit(innerFlow);
|
||||||
|
this.currentFlow = outerFlow;
|
||||||
var block: ExpressionRef[] = [
|
return expr;
|
||||||
module.loop(continueLabel,
|
|
||||||
terminated
|
|
||||||
? flatten(module, stmts, NativeType.None) // skip trailing continue if unnecessary
|
|
||||||
: module.block(null, [
|
|
||||||
flatten(module, stmts, NativeType.None),
|
|
||||||
module.br(continueLabel, condExpr)
|
|
||||||
], NativeType.None)
|
|
||||||
)
|
|
||||||
];
|
|
||||||
if (terminated) block.push(module.unreachable());
|
|
||||||
return module.block(breakLabel, block);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
compileEmptyStatement(
|
compileEmptyStatement(
|
||||||
@ -1970,23 +1986,20 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
statement: ForStatement,
|
statement: ForStatement,
|
||||||
contextualFlags: ContextualFlags
|
contextualFlags: ContextualFlags
|
||||||
): ExpressionRef {
|
): ExpressionRef {
|
||||||
// A for statement initiates a new branch with its own scoped variables
|
var module = this.module;
|
||||||
// possibly declared in its initializer, and break context.
|
|
||||||
|
// Set up and use the inner flow
|
||||||
var outerFlow = this.currentFlow;
|
var outerFlow = this.currentFlow;
|
||||||
var label = outerFlow.pushBreakLabel();
|
var label = outerFlow.pushBreakLabel();
|
||||||
var innerFlow = outerFlow.fork();
|
var innerFlow = outerFlow.fork();
|
||||||
this.currentFlow = innerFlow;
|
this.currentFlow = innerFlow;
|
||||||
var breakLabel = innerFlow.breakLabel = "break|" + label;
|
|
||||||
innerFlow.breakLabel = breakLabel;
|
|
||||||
var continueLabel = "continue|" + label;
|
|
||||||
innerFlow.continueLabel = continueLabel;
|
|
||||||
var repeatLabel = "repeat|" + label;
|
|
||||||
|
|
||||||
// Compile in correct order
|
// Compile the initializer
|
||||||
var module = this.module;
|
var initializer = statement.initializer;
|
||||||
var initExpr = statement.initializer
|
var initExpr: ExpressionRef = 0;
|
||||||
? this.compileStatement(<Statement>statement.initializer)
|
if (initializer) initExpr = this.compileStatement(initializer);
|
||||||
: 0;
|
|
||||||
|
// Compile the condition
|
||||||
var condExpr: ExpressionRef = 0;
|
var condExpr: ExpressionRef = 0;
|
||||||
var alwaysTrue = false;
|
var alwaysTrue = false;
|
||||||
if (statement.condition) {
|
if (statement.condition) {
|
||||||
@ -1996,40 +2009,97 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
this.currentType
|
this.currentType
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
// check if the condition is always true
|
// Simplify if the condition is constant
|
||||||
if (getExpressionId(condExpr) == ExpressionId.Const) {
|
if (getExpressionId(condExpr) == ExpressionId.Const) {
|
||||||
assert(getExpressionType(condExpr) == NativeType.I32);
|
assert(getExpressionType(condExpr) == NativeType.I32);
|
||||||
if (getConstValueI32(condExpr) != 0) alwaysTrue = true;
|
if (getConstValueI32(condExpr) == /* false */ 0) {
|
||||||
// TODO: could skip compilation if the condition is always false here, but beware that the
|
let stmts = new Array<ExpressionRef>();
|
||||||
// initializer could still declare new 'var's that are used later on.
|
if (initExpr) stmts.push(initExpr);
|
||||||
|
this.performAutoreleases(innerFlow, stmts);
|
||||||
|
innerFlow.freeScopedLocals();
|
||||||
|
outerFlow.popBreakLabel();
|
||||||
|
this.currentFlow = outerFlow;
|
||||||
|
return flatten(module, stmts, NativeType.None);
|
||||||
}
|
}
|
||||||
} else {
|
alwaysTrue = true;
|
||||||
// omitted condition is always true
|
}
|
||||||
|
} else { // Omitted condition is always true
|
||||||
condExpr = module.i32(1);
|
condExpr = module.i32(1);
|
||||||
alwaysTrue = true;
|
alwaysTrue = true;
|
||||||
}
|
}
|
||||||
innerFlow.inheritNonnullIfTrue(condExpr);
|
innerFlow.inheritNonnullIfTrue(condExpr);
|
||||||
var incrExpr = statement.incrementor
|
|
||||||
? this.compileExpression(<Expression>statement.incrementor, Type.void,
|
// Compile incrementor
|
||||||
ContextualFlags.IMPLICIT | ContextualFlags.WILL_DROP
|
var incrementor = statement.incrementor;
|
||||||
)
|
var incrExpr: ExpressionRef = 0;
|
||||||
: 0;
|
if (incrementor) incrExpr = this.compileExpression(incrementor, Type.void, ContextualFlags.IMPLICIT | ContextualFlags.WILL_DROP);
|
||||||
|
|
||||||
|
// Compile body (break: drop out, continue: fall through to incrementor, + loop)
|
||||||
|
var breakLabel = innerFlow.breakLabel = "break|" + label; innerFlow.breakLabel = breakLabel;
|
||||||
|
innerFlow.breakLabel = breakLabel;
|
||||||
|
var continueLabel = "continue|" + label;
|
||||||
|
innerFlow.continueLabel = continueLabel;
|
||||||
|
var loopLabel = "loop|" + label;
|
||||||
var bodyStatement = statement.statement;
|
var bodyStatement = statement.statement;
|
||||||
var stmts = new Array<ExpressionRef>();
|
var stmts = new Array<ExpressionRef>();
|
||||||
if (bodyStatement.kind == NodeKind.BLOCK) {
|
if (bodyStatement.kind == NodeKind.BLOCK) {
|
||||||
this.compileStatements((<BlockStatement>bodyStatement).statements, false, stmts);
|
this.compileStatements((<BlockStatement>bodyStatement).statements, false, stmts);
|
||||||
} else {
|
} else {
|
||||||
stmts.push(
|
stmts.push(this.compileStatement(bodyStatement));
|
||||||
this.compileStatement(bodyStatement)
|
}
|
||||||
);
|
var terminates = innerFlow.is(FlowFlags.TERMINATES);
|
||||||
|
var continues = innerFlow.isAny(FlowFlags.CONTINUES | FlowFlags.CONDITIONALLY_CONTINUES);
|
||||||
|
var breaks = innerFlow.isAny(FlowFlags.BREAKS | FlowFlags.CONDITIONALLY_BREAKS);
|
||||||
|
|
||||||
|
// (block $break ;; (1) skip label (needed anyway) if skipping (4) + no breaks
|
||||||
|
// (initializer) ;; (2) [may be empty]
|
||||||
|
// (loop $loop ;; (3) skip if (6) does not fall through + no continues
|
||||||
|
// (br_if !cond $break) ;; (4) skip if always true
|
||||||
|
// (block $continue ;; (5) skip if no continues or nothing else than continue
|
||||||
|
// (...) ;; (6)
|
||||||
|
// )
|
||||||
|
// (incrementor) ;; (7) skip if skipping (3) [may be empty]
|
||||||
|
// (br $loop) ;; (8) skip if skipping (3)
|
||||||
|
// )
|
||||||
|
// )
|
||||||
|
var fallsThrough = !terminates && !innerFlow.is(FlowFlags.BREAKS);
|
||||||
|
var needsLabel = !alwaysTrue || breaks;
|
||||||
|
|
||||||
|
var loop = new Array<ExpressionRef>();
|
||||||
|
if (!alwaysTrue) { // (4)
|
||||||
|
loop.push(module.br(breakLabel, module.unary(UnaryOp.EqzI32, condExpr)));
|
||||||
|
}
|
||||||
|
if (continues) { // (5)
|
||||||
|
if (stmts.length > 1 || getExpressionId(stmts[0]) != ExpressionId.Break) { // otherwise lonely continue
|
||||||
|
loop.push(module.block(continueLabel, stmts));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
for (let i = 0, k = stmts.length; i < k; ++i) loop.push(stmts[i]);
|
||||||
|
}
|
||||||
|
var expr: ExpressionRef;
|
||||||
|
if (fallsThrough || continues) { // (3)
|
||||||
|
if (incrExpr) loop.push(incrExpr); // (7)
|
||||||
|
this.performAutoreleases(innerFlow, loop);
|
||||||
|
loop.push(module.br(loopLabel)); // (8)
|
||||||
|
if (initExpr) { // (2)
|
||||||
|
expr = module.block(needsLabel ? breakLabel : null, [
|
||||||
|
initExpr,
|
||||||
|
module.loop(loopLabel, module.block(null, loop))
|
||||||
|
]);
|
||||||
|
} else {
|
||||||
|
expr = module.block(needsLabel ? breakLabel : null, [
|
||||||
|
module.loop(loopLabel, flatten(module, loop, NativeType.None))
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (initExpr) loop.unshift(initExpr); // (2)
|
||||||
|
this.performAutoreleases(innerFlow, loop);
|
||||||
|
expr = module.block(needsLabel ? breakLabel : null, loop);
|
||||||
}
|
}
|
||||||
if (!innerFlow.isAny(FlowFlags.ANY_TERMINATING)) this.performAutoreleases(innerFlow, stmts);
|
|
||||||
|
|
||||||
// Switch back to the parent flow
|
// Switch back to the parent flow
|
||||||
innerFlow.freeScopedLocals();
|
innerFlow.freeScopedLocals();
|
||||||
outerFlow.popBreakLabel();
|
outerFlow.popBreakLabel();
|
||||||
this.currentFlow = outerFlow;
|
|
||||||
var usesContinue = innerFlow.isAny(FlowFlags.CONTINUES | FlowFlags.CONDITIONALLY_CONTINUES);
|
|
||||||
innerFlow.unset(
|
innerFlow.unset(
|
||||||
FlowFlags.BREAKS |
|
FlowFlags.BREAKS |
|
||||||
FlowFlags.CONDITIONALLY_BREAKS |
|
FlowFlags.CONDITIONALLY_BREAKS |
|
||||||
@ -2038,36 +2108,8 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
);
|
);
|
||||||
if (alwaysTrue) outerFlow.inherit(innerFlow);
|
if (alwaysTrue) outerFlow.inherit(innerFlow);
|
||||||
else outerFlow.inheritConditional(innerFlow);
|
else outerFlow.inheritConditional(innerFlow);
|
||||||
|
this.currentFlow = outerFlow;
|
||||||
var breakBlock = new Array<ExpressionRef>(); // outer 'break' block
|
return expr;
|
||||||
if (initExpr) breakBlock.push(initExpr);
|
|
||||||
|
|
||||||
var repeatBlock = new Array<ExpressionRef>(); // block repeating the loop
|
|
||||||
if (usesContinue) {
|
|
||||||
stmts.unshift(
|
|
||||||
module.br(breakLabel, module.unary(UnaryOp.EqzI32, condExpr))
|
|
||||||
);
|
|
||||||
repeatBlock.push(
|
|
||||||
module.block(continueLabel, stmts, NativeType.None)
|
|
||||||
);
|
|
||||||
} else { // can omit the 'continue' block
|
|
||||||
repeatBlock.push(
|
|
||||||
module.br(breakLabel, module.unary(UnaryOp.EqzI32, condExpr))
|
|
||||||
);
|
|
||||||
for (let i = 0, k = stmts.length; i < k; ++i) {
|
|
||||||
repeatBlock.push(stmts[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (incrExpr) repeatBlock.push(incrExpr);
|
|
||||||
repeatBlock.push(
|
|
||||||
module.br(repeatLabel)
|
|
||||||
);
|
|
||||||
|
|
||||||
breakBlock.push(
|
|
||||||
module.loop(repeatLabel, module.block(null, repeatBlock, NativeType.None))
|
|
||||||
);
|
|
||||||
|
|
||||||
return module.block(breakLabel, breakBlock);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
compileIfStatement(
|
compileIfStatement(
|
||||||
@ -2109,7 +2151,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
} else {
|
} else {
|
||||||
ifTrueStmts.push(this.compileStatement(ifTrue));
|
ifTrueStmts.push(this.compileStatement(ifTrue));
|
||||||
}
|
}
|
||||||
if (!ifTrueFlow.isAny(FlowFlags.ANY_TERMINATING)) this.performAutoreleases(ifTrueFlow, ifTrueStmts);
|
if (!ifTrueFlow.isAny(FlowFlags.TERMINATES | FlowFlags.BREAKS)) this.performAutoreleases(ifTrueFlow, ifTrueStmts);
|
||||||
ifTrueFlow.freeScopedLocals();
|
ifTrueFlow.freeScopedLocals();
|
||||||
this.currentFlow = outerFlow;
|
this.currentFlow = outerFlow;
|
||||||
|
|
||||||
@ -2123,7 +2165,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
} else {
|
} else {
|
||||||
ifFalseStmts.push(this.compileStatement(ifFalse));
|
ifFalseStmts.push(this.compileStatement(ifFalse));
|
||||||
}
|
}
|
||||||
if (!ifFalseFlow.isAny(FlowFlags.ANY_TERMINATING)) this.performAutoreleases(ifFalseFlow, ifFalseStmts);
|
if (!ifFalseFlow.isAny(FlowFlags.TERMINATES | FlowFlags.BREAKS)) this.performAutoreleases(ifFalseFlow, ifFalseStmts);
|
||||||
ifFalseFlow.freeScopedLocals();
|
ifFalseFlow.freeScopedLocals();
|
||||||
this.currentFlow = outerFlow;
|
this.currentFlow = outerFlow;
|
||||||
outerFlow.inheritMutual(ifTrueFlow, ifFalseFlow);
|
outerFlow.inheritMutual(ifTrueFlow, ifFalseFlow);
|
||||||
@ -2133,9 +2175,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
outerFlow.inheritConditional(ifTrueFlow);
|
outerFlow.inheritConditional(ifTrueFlow);
|
||||||
if (ifTrueFlow.isAny(FlowFlags.ANY_TERMINATING)) {
|
if (ifTrueFlow.is(FlowFlags.TERMINATES)) outerFlow.inheritNonnullIfFalse(condExpr);
|
||||||
outerFlow.inheritNonnullIfFalse(condExpr);
|
|
||||||
}
|
|
||||||
return module.if(condExpr,
|
return module.if(condExpr,
|
||||||
flatten(module, ifTrueStmts, NativeType.None)
|
flatten(module, ifTrueStmts, NativeType.None)
|
||||||
);
|
);
|
||||||
@ -2157,7 +2197,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
var returnType = flow.returnType;
|
var returnType = flow.returnType;
|
||||||
|
|
||||||
// Remember that this flow returns
|
// Remember that this flow returns
|
||||||
flow.set(FlowFlags.RETURNS);
|
flow.set(FlowFlags.RETURNS | FlowFlags.TERMINATES);
|
||||||
|
|
||||||
var valueExpression = statement.value;
|
var valueExpression = statement.value;
|
||||||
if (valueExpression) {
|
if (valueExpression) {
|
||||||
@ -2294,10 +2334,8 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
|
|
||||||
// nest blocks in order
|
// nest blocks in order
|
||||||
var currentBlock = module.block("case0|" + context, breaks, NativeType.None);
|
var currentBlock = module.block("case0|" + context, breaks, NativeType.None);
|
||||||
var alwaysReturns = true;
|
var commonCategorical = FlowFlags.ANY_CATEGORICAL;
|
||||||
var alwaysReturnsWrapped = true;
|
var commonConditional = 0;
|
||||||
var alwaysThrows = true;
|
|
||||||
var alwaysAllocates = true;
|
|
||||||
for (let i = 0; i < numCases; ++i) {
|
for (let i = 0; i < numCases; ++i) {
|
||||||
let case_ = cases[i];
|
let case_ = cases[i];
|
||||||
let statements = case_.statements;
|
let statements = case_.statements;
|
||||||
@ -2314,27 +2352,25 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
let stmts = new Array<ExpressionRef>(1 + numStatements);
|
let stmts = new Array<ExpressionRef>(1 + numStatements);
|
||||||
stmts[0] = currentBlock;
|
stmts[0] = currentBlock;
|
||||||
let count = 1;
|
let count = 1;
|
||||||
let terminated = false;
|
let terminates = false;
|
||||||
for (let j = 0; j < numStatements; ++j) {
|
for (let j = 0; j < numStatements; ++j) {
|
||||||
let stmt = this.compileStatement(statements[j]);
|
let stmt = this.compileStatement(statements[j]);
|
||||||
if (getExpressionId(stmt) != ExpressionId.Nop) {
|
if (getExpressionId(stmt) != ExpressionId.Nop) {
|
||||||
stmts[count++] = stmt;
|
stmts[count++] = stmt;
|
||||||
if (innerFlow.isAny(FlowFlags.ANY_TERMINATING)) {
|
}
|
||||||
terminated = true;
|
if (innerFlow.isAny(FlowFlags.TERMINATES | FlowFlags.BREAKS)) {
|
||||||
|
if (innerFlow.is(FlowFlags.TERMINATES)) terminates = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
stmts.length = count;
|
stmts.length = count;
|
||||||
if (terminated || isLast) {
|
if (terminates || isLast || innerFlow.isAny(FlowFlags.BREAKS | FlowFlags.CONDITIONALLY_BREAKS)) {
|
||||||
if (!innerFlow.is(FlowFlags.RETURNS)) alwaysReturns = false;
|
commonCategorical &= innerFlow.flags;
|
||||||
if (!innerFlow.is(FlowFlags.RETURNS_WRAPPED)) alwaysReturnsWrapped = false;
|
|
||||||
if (!innerFlow.is(FlowFlags.THROWS)) alwaysThrows = false;
|
|
||||||
if (!innerFlow.is(FlowFlags.ALLOCATES)) alwaysAllocates = false;
|
|
||||||
}
|
}
|
||||||
|
commonConditional |= innerFlow.flags & FlowFlags.ANY_CONDITIONAL;
|
||||||
|
|
||||||
// Switch back to the parent flow
|
// Switch back to the parent flow
|
||||||
if (!innerFlow.isAny(FlowFlags.ANY_TERMINATING)) this.performAutoreleases(innerFlow, stmts);
|
if (!terminates) this.performAutoreleases(innerFlow, stmts);
|
||||||
innerFlow.unset(
|
innerFlow.unset(
|
||||||
FlowFlags.BREAKS |
|
FlowFlags.BREAKS |
|
||||||
FlowFlags.CONDITIONALLY_BREAKS
|
FlowFlags.CONDITIONALLY_BREAKS
|
||||||
@ -2346,12 +2382,9 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
outerFlow.popBreakLabel();
|
outerFlow.popBreakLabel();
|
||||||
|
|
||||||
// If the switch has a default (guaranteed to handle any value), propagate common flags
|
// If the switch has a default (guaranteed to handle any value), propagate common flags
|
||||||
if (defaultIndex >= 0) {
|
if (defaultIndex >= 0) outerFlow.flags |= commonCategorical & ~FlowFlags.BREAKS;
|
||||||
if (alwaysReturns) outerFlow.set(FlowFlags.RETURNS);
|
outerFlow.flags |= commonConditional & ~FlowFlags.CONDITIONALLY_BREAKS;
|
||||||
if (alwaysReturnsWrapped) outerFlow.set(FlowFlags.RETURNS_WRAPPED);
|
// TODO: what about local states?
|
||||||
if (alwaysThrows) outerFlow.set(FlowFlags.THROWS);
|
|
||||||
if (alwaysAllocates) outerFlow.set(FlowFlags.ALLOCATES);
|
|
||||||
}
|
|
||||||
return currentBlock;
|
return currentBlock;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2362,10 +2395,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
var flow = this.currentFlow;
|
var flow = this.currentFlow;
|
||||||
|
|
||||||
// Remember that this branch throws
|
// Remember that this branch throws
|
||||||
flow.set(FlowFlags.THROWS);
|
flow.set(FlowFlags.THROWS | FlowFlags.TERMINATES);
|
||||||
|
|
||||||
// FIXME: without try-catch it is safe to assume RETURNS as well for now
|
|
||||||
flow.set(FlowFlags.RETURNS);
|
|
||||||
|
|
||||||
var stmts = new Array<ExpressionRef>();
|
var stmts = new Array<ExpressionRef>();
|
||||||
this.finishAutoreleases(flow, stmts);
|
this.finishAutoreleases(flow, stmts);
|
||||||
@ -2597,7 +2627,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
var module = this.module;
|
var module = this.module;
|
||||||
var outerFlow = this.currentFlow;
|
var outerFlow = this.currentFlow;
|
||||||
|
|
||||||
// The condition does not yet initialize a branch
|
// Compile condition
|
||||||
var condExpr = module.precomputeExpression(
|
var condExpr = module.precomputeExpression(
|
||||||
this.makeIsTrueish(
|
this.makeIsTrueish(
|
||||||
this.compileExpressionRetainType(statement.condition, Type.bool),
|
this.compileExpressionRetainType(statement.condition, Type.bool),
|
||||||
@ -2605,15 +2635,15 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
// Try to eliminate unnecesssary loops if the condition is constant
|
// Simplify if the condition is constant
|
||||||
if (
|
var alwaysTrue = false;
|
||||||
getExpressionId(condExpr) == ExpressionId.Const &&
|
if (getExpressionId(condExpr) == ExpressionId.Const) {
|
||||||
getExpressionType(condExpr) == NativeType.I32
|
assert(getExpressionType(condExpr) == NativeType.I32);
|
||||||
) {
|
if (!getConstValueI32(condExpr)) return module.nop(); // simplify
|
||||||
if (!getConstValueI32(condExpr)) return module.nop();
|
alwaysTrue = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Statements initiate a new branch with its own break context
|
// Compile body
|
||||||
var label = outerFlow.pushBreakLabel();
|
var label = outerFlow.pushBreakLabel();
|
||||||
var innerFlow = outerFlow.fork();
|
var innerFlow = outerFlow.fork();
|
||||||
this.currentFlow = innerFlow;
|
this.currentFlow = innerFlow;
|
||||||
@ -2621,7 +2651,6 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
innerFlow.breakLabel = breakLabel;
|
innerFlow.breakLabel = breakLabel;
|
||||||
var continueLabel = "continue|" + label;
|
var continueLabel = "continue|" + label;
|
||||||
innerFlow.continueLabel = continueLabel;
|
innerFlow.continueLabel = continueLabel;
|
||||||
|
|
||||||
innerFlow.inheritNonnullIfTrue(condExpr);
|
innerFlow.inheritNonnullIfTrue(condExpr);
|
||||||
var stmts = new Array<ExpressionRef>();
|
var stmts = new Array<ExpressionRef>();
|
||||||
if (statement.statement.kind == NodeKind.BLOCK) {
|
if (statement.statement.kind == NodeKind.BLOCK) {
|
||||||
@ -2629,17 +2658,35 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
} else {
|
} else {
|
||||||
stmts.push(this.compileStatement(statement.statement));
|
stmts.push(this.compileStatement(statement.statement));
|
||||||
}
|
}
|
||||||
var alwaysTrue = false; // TODO
|
var terminates = innerFlow.is(FlowFlags.TERMINATES);
|
||||||
var terminated = innerFlow.isAny(FlowFlags.ANY_TERMINATING);
|
|
||||||
if (!terminated) {
|
// (block $break ;; (1) skip if skipping (3) + no breaks
|
||||||
|
// (loop $continue ;; (2) skip if skipping (5) + no continues
|
||||||
|
// (br_if !cond $break) ;; (3) skip if always true
|
||||||
|
// (...) ;; (4)
|
||||||
|
// (br $continue) ;; (5) skip if (4) does not fall through
|
||||||
|
// )
|
||||||
|
// )
|
||||||
|
var fallsThrough = !terminates && !innerFlow.is(FlowFlags.BREAKS);
|
||||||
|
|
||||||
|
if (fallsThrough) { // (5)
|
||||||
this.performAutoreleases(innerFlow, stmts);
|
this.performAutoreleases(innerFlow, stmts);
|
||||||
stmts.push(module.br(continueLabel));
|
stmts.push(module.br(continueLabel));
|
||||||
}
|
}
|
||||||
innerFlow.freeScopedLocals();
|
if (!alwaysTrue) { // (3)
|
||||||
|
stmts.unshift(module.br(breakLabel, module.unary(UnaryOp.EqzI32, condExpr)));
|
||||||
|
}
|
||||||
|
var expr = flatten(module, stmts, NativeType.None);
|
||||||
|
if (fallsThrough || innerFlow.isAny(FlowFlags.CONTINUES | FlowFlags.CONDITIONALLY_CONTINUES)) { // (2)
|
||||||
|
expr = module.loop(continueLabel, expr);
|
||||||
|
}
|
||||||
|
if (!alwaysTrue || innerFlow.isAny(FlowFlags.BREAKS | FlowFlags.CONDITIONALLY_BREAKS)) { // (1)
|
||||||
|
expr = module.block(breakLabel, [ expr ]);
|
||||||
|
}
|
||||||
|
|
||||||
// Switch back to the parent flow
|
// Switch back to the parent flow
|
||||||
|
innerFlow.freeScopedLocals();
|
||||||
outerFlow.popBreakLabel();
|
outerFlow.popBreakLabel();
|
||||||
this.currentFlow = outerFlow;
|
|
||||||
innerFlow.unset(
|
innerFlow.unset(
|
||||||
FlowFlags.BREAKS |
|
FlowFlags.BREAKS |
|
||||||
FlowFlags.CONDITIONALLY_BREAKS |
|
FlowFlags.CONDITIONALLY_BREAKS |
|
||||||
@ -2648,14 +2695,8 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
);
|
);
|
||||||
if (alwaysTrue) outerFlow.inherit(innerFlow);
|
if (alwaysTrue) outerFlow.inherit(innerFlow);
|
||||||
else outerFlow.inheritConditional(innerFlow);
|
else outerFlow.inheritConditional(innerFlow);
|
||||||
|
this.currentFlow = outerFlow;
|
||||||
return module.block(breakLabel, [
|
return expr;
|
||||||
module.loop(continueLabel,
|
|
||||||
module.if(condExpr,
|
|
||||||
flatten(module, stmts, NativeType.None)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
]);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// === Expressions ==============================================================================
|
// === Expressions ==============================================================================
|
||||||
@ -6282,7 +6323,7 @@ export class Compiler extends DiagnosticEmitter {
|
|||||||
this.compileFunctionBody(instance, body);
|
this.compileFunctionBody(instance, body);
|
||||||
|
|
||||||
// Free any new scoped locals and reset to the original flow
|
// Free any new scoped locals and reset to the original flow
|
||||||
if (!flow.isAny(FlowFlags.ANY_TERMINATING)) {
|
if (!flow.is(FlowFlags.TERMINATES)) {
|
||||||
this.performAutoreleases(flow, body);
|
this.performAutoreleases(flow, body);
|
||||||
this.finishAutoreleases(flow, body);
|
this.finishAutoreleases(flow, body);
|
||||||
}
|
}
|
||||||
@ -9028,7 +9069,16 @@ var mangleImportName_elementName: string;
|
|||||||
export function flatten(module: Module, stmts: ExpressionRef[], type: NativeType): ExpressionRef {
|
export function flatten(module: Module, stmts: ExpressionRef[], type: NativeType): ExpressionRef {
|
||||||
var length = stmts.length;
|
var length = stmts.length;
|
||||||
if (length == 0) return module.nop(); // usually filtered out again
|
if (length == 0) return module.nop(); // usually filtered out again
|
||||||
if (length == 1) return stmts[0];
|
if (length == 1) {
|
||||||
|
let single = stmts[0];
|
||||||
|
if (getExpressionType(single) == type) return single;
|
||||||
|
if (getExpressionId(single) == ExpressionId.Block) {
|
||||||
|
let count = getBlockChildCount(single);
|
||||||
|
let children = new Array<ExpressionRef>(count);
|
||||||
|
for (let i = 0; i < count; ++i) children[i] = getBlockChild(single, i);
|
||||||
|
return module.block(getBlockName(single), children, type);
|
||||||
|
}
|
||||||
|
}
|
||||||
return module.block(null, stmts,
|
return module.block(null, stmts,
|
||||||
type == NativeType.Auto
|
type == NativeType.Auto
|
||||||
? getExpressionType(stmts[length - 1])
|
? getExpressionType(stmts[length - 1])
|
||||||
|
33
src/flow.ts
33
src/flow.ts
@ -91,35 +91,33 @@ export const enum FlowFlags {
|
|||||||
ALLOCATES = 1 << 6,
|
ALLOCATES = 1 << 6,
|
||||||
/** This flow calls super. Constructors only. */
|
/** This flow calls super. Constructors only. */
|
||||||
CALLS_SUPER = 1 << 7,
|
CALLS_SUPER = 1 << 7,
|
||||||
|
/** This flow terminates (returns, throws or continues). */
|
||||||
|
TERMINATES = 1 << 8,
|
||||||
|
|
||||||
// conditional
|
// conditional
|
||||||
|
|
||||||
/** This flow conditionally returns in a child flow. */
|
/** This flow conditionally returns in a child flow. */
|
||||||
CONDITIONALLY_RETURNS = 1 << 8,
|
CONDITIONALLY_RETURNS = 1 << 9,
|
||||||
/** This flow conditionally throws in a child flow. */
|
/** This flow conditionally throws in a child flow. */
|
||||||
CONDITIONALLY_THROWS = 1 << 9,
|
CONDITIONALLY_THROWS = 1 << 10,
|
||||||
|
/** This flow conditionally terminates in a child flow. */
|
||||||
|
CONDITIONALLY_TERMINATES = 1 << 11,
|
||||||
/** This flow conditionally breaks in a child flow. */
|
/** This flow conditionally breaks in a child flow. */
|
||||||
CONDITIONALLY_BREAKS = 1 << 10,
|
CONDITIONALLY_BREAKS = 1 << 12,
|
||||||
/** This flow conditionally continues in a child flow. */
|
/** This flow conditionally continues in a child flow. */
|
||||||
CONDITIONALLY_CONTINUES = 1 << 11,
|
CONDITIONALLY_CONTINUES = 1 << 13,
|
||||||
/** This flow conditionally allocates in a child flow. Constructors only. */
|
/** This flow conditionally allocates in a child flow. Constructors only. */
|
||||||
CONDITIONALLY_ALLOCATES = 1 << 12,
|
CONDITIONALLY_ALLOCATES = 1 << 14,
|
||||||
|
|
||||||
// special
|
// special
|
||||||
|
|
||||||
/** This is an inlining flow. */
|
/** This is an inlining flow. */
|
||||||
INLINE_CONTEXT = 1 << 13,
|
INLINE_CONTEXT = 1 << 15,
|
||||||
/** This is a flow with explicitly disabled bounds checking. */
|
/** This is a flow with explicitly disabled bounds checking. */
|
||||||
UNCHECKED_CONTEXT = 1 << 14,
|
UNCHECKED_CONTEXT = 1 << 16,
|
||||||
|
|
||||||
// masks
|
// masks
|
||||||
|
|
||||||
/** Any terminating flag. */
|
|
||||||
ANY_TERMINATING = FlowFlags.RETURNS
|
|
||||||
| FlowFlags.THROWS
|
|
||||||
| FlowFlags.BREAKS
|
|
||||||
| FlowFlags.CONTINUES,
|
|
||||||
|
|
||||||
/** Any categorical flag. */
|
/** Any categorical flag. */
|
||||||
ANY_CATEGORICAL = FlowFlags.RETURNS
|
ANY_CATEGORICAL = FlowFlags.RETURNS
|
||||||
| FlowFlags.RETURNS_WRAPPED
|
| FlowFlags.RETURNS_WRAPPED
|
||||||
@ -128,7 +126,8 @@ export const enum FlowFlags {
|
|||||||
| FlowFlags.BREAKS
|
| FlowFlags.BREAKS
|
||||||
| FlowFlags.CONTINUES
|
| FlowFlags.CONTINUES
|
||||||
| FlowFlags.ALLOCATES
|
| FlowFlags.ALLOCATES
|
||||||
| FlowFlags.CALLS_SUPER,
|
| FlowFlags.CALLS_SUPER
|
||||||
|
| FlowFlags.TERMINATES,
|
||||||
|
|
||||||
/** Any conditional flag. */
|
/** Any conditional flag. */
|
||||||
ANY_CONDITIONAL = FlowFlags.CONDITIONALLY_RETURNS
|
ANY_CONDITIONAL = FlowFlags.CONDITIONALLY_RETURNS
|
||||||
@ -551,10 +550,14 @@ export class Flow {
|
|||||||
// categorical flags set in both arms
|
// categorical flags set in both arms
|
||||||
this.set(left.flags & right.flags & FlowFlags.ANY_CATEGORICAL);
|
this.set(left.flags & right.flags & FlowFlags.ANY_CATEGORICAL);
|
||||||
|
|
||||||
// conditional flags set in at least one arm
|
// conditional flags set in any arm
|
||||||
this.set(left.flags & FlowFlags.ANY_CONDITIONAL);
|
this.set(left.flags & FlowFlags.ANY_CONDITIONAL);
|
||||||
this.set(right.flags & FlowFlags.ANY_CONDITIONAL);
|
this.set(right.flags & FlowFlags.ANY_CONDITIONAL);
|
||||||
|
|
||||||
|
// categorical flags in either arm as conditional
|
||||||
|
this.inheritConditional(left);
|
||||||
|
this.inheritConditional(right);
|
||||||
|
|
||||||
// categorical local flags set in both arms / conditional local flags set in at least one arm
|
// categorical local flags set in both arms / conditional local flags set in at least one arm
|
||||||
var leftLocalFlags = left.localFlags;
|
var leftLocalFlags = left.localFlags;
|
||||||
var numLeftLocalFlags = leftLocalFlags.length;
|
var numLeftLocalFlags = leftLocalFlags.length;
|
||||||
|
@ -14,7 +14,11 @@ import "./i64";
|
|||||||
import { Module } from "../../module";
|
import { Module } from "../../module";
|
||||||
|
|
||||||
Module.prototype.toText = function(this: Module) {
|
Module.prototype.toText = function(this: Module) {
|
||||||
return binaryen.wrapModule(this.ref).emitStackIR();
|
// NOTE: Conversion to StackIR can yield conversion artifacts like sequences
|
||||||
|
// of unreachable statements not actually emitted by the compiler. Optimizing
|
||||||
|
// StackIR removes these again, but may also suppress useless code emitted by
|
||||||
|
// the compiler that's then no longer visible in tests. Both not ideal.
|
||||||
|
return binaryen.wrapModule(this.ref).emitStackIR(/* optimize-stack-ir */ true);
|
||||||
};
|
};
|
||||||
|
|
||||||
Module.prototype.toAsmjs = function(this: Module) {
|
Module.prototype.toAsmjs = function(this: Module) {
|
||||||
|
@ -1566,7 +1566,7 @@ export class Program extends DiagnosticEmitter {
|
|||||||
this.error(
|
this.error(
|
||||||
DiagnosticCode.Duplicate_identifier_0,
|
DiagnosticCode.Duplicate_identifier_0,
|
||||||
declaration.name.range, "default"
|
declaration.name.range, "default"
|
||||||
)
|
);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
exports.set("default", element);
|
exports.set("default", element);
|
||||||
|
25
tests/binaryen/unreachable-spam.js
Normal file
25
tests/binaryen/unreachable-spam.js
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
var binaryen = require("binaryen");
|
||||||
|
|
||||||
|
var mod = new binaryen.Module();
|
||||||
|
var funcType = mod.addFunctionType("ii", binaryen.i32, [ binaryen.i32 ]);
|
||||||
|
mod.addFunction("0", funcType, [],
|
||||||
|
mod.block(null, [
|
||||||
|
mod.loop("continue",
|
||||||
|
mod.block(null, [
|
||||||
|
mod.if(
|
||||||
|
mod.local.get(0, binaryen.i32),
|
||||||
|
mod.return(mod.i32.const(1)),
|
||||||
|
mod.return(mod.i32.const(2))
|
||||||
|
),
|
||||||
|
mod.unreachable()
|
||||||
|
])
|
||||||
|
),
|
||||||
|
mod.unreachable()
|
||||||
|
], binaryen.i32)
|
||||||
|
);
|
||||||
|
mod.addExport("0", "0");
|
||||||
|
|
||||||
|
if (!mod.validate())
|
||||||
|
console.log("-> does not validate");
|
||||||
|
console.log(mod.emitText());
|
||||||
|
console.log(mod.emitStackIR(/*true*/)); // optimize-stack-ir fixes this
|
@ -25,7 +25,6 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
global.set $abi/condition
|
global.set $abi/condition
|
||||||
block
|
|
||||||
i32.const 256
|
i32.const 256
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -43,8 +42,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 256
|
i32.const 256
|
||||||
local.set $0
|
local.set $0
|
||||||
global.get $abi/condition
|
global.get $abi/condition
|
||||||
@ -82,8 +79,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 256
|
i32.const 256
|
||||||
local.set $0
|
local.set $0
|
||||||
global.get $abi/condition
|
global.get $abi/condition
|
||||||
@ -113,8 +108,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 256
|
i32.const 256
|
||||||
i32.const 24
|
i32.const 24
|
||||||
i32.shl
|
i32.shl
|
||||||
@ -132,8 +125,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.ctz
|
i32.ctz
|
||||||
local.set $0
|
local.set $0
|
||||||
@ -190,7 +181,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $abi/exported (; 3 ;) (type $FUNCSIG$i) (result i32)
|
(func $abi/exported (; 3 ;) (type $FUNCSIG$i) (result i32)
|
||||||
i32.const 128
|
i32.const 128
|
||||||
|
@ -157,13 +157,11 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $0
|
local.tee $0
|
||||||
local.set $1
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $1
|
|
||||||
)
|
)
|
||||||
(func $assert-nonnull/testObjFn (; 13 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $assert-nonnull/testObjFn (; 13 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -180,13 +178,11 @@
|
|||||||
i32.load offset=4
|
i32.load offset=4
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $0
|
local.tee $0
|
||||||
local.set $1
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $1
|
|
||||||
)
|
)
|
||||||
(func $null (; 15 ;) (type $FUNCSIG$v)
|
(func $null (; 15 ;) (type $FUNCSIG$v)
|
||||||
nop
|
nop
|
||||||
|
@ -260,13 +260,11 @@
|
|||||||
(func $assert-nonnull/testFn (; 14 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $assert-nonnull/testFn (; 14 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
(local $2 i32)
|
(local $2 i32)
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $0
|
local.get $0
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $1
|
local.tee $1
|
||||||
end
|
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -285,13 +283,11 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
local.set $2
|
local.set $2
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $2
|
local.get $2
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $1
|
local.tee $1
|
||||||
end
|
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $3
|
local.set $3
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -301,13 +297,11 @@
|
|||||||
(func $assert-nonnull/testRet (; 16 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $assert-nonnull/testRet (; 16 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
(local $2 i32)
|
(local $2 i32)
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $0
|
local.get $0
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $1
|
local.tee $1
|
||||||
end
|
|
||||||
local.tee $2
|
local.tee $2
|
||||||
if (result i32)
|
if (result i32)
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -326,14 +320,12 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
drop
|
drop
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=4
|
i32.load offset=4
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $1
|
local.tee $1
|
||||||
end
|
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -348,14 +340,12 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
drop
|
drop
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=4
|
i32.load offset=4
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $1
|
local.tee $1
|
||||||
end
|
|
||||||
local.tee $2
|
local.tee $2
|
||||||
if (result i32)
|
if (result i32)
|
||||||
local.get $2
|
local.get $2
|
||||||
|
@ -337,7 +337,6 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $8
|
local.get $8
|
||||||
i32.const 1072693248
|
i32.const 1072693248
|
||||||
@ -1344,7 +1343,8 @@
|
|||||||
local.get $4
|
local.get $4
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.gt_s
|
i32.gt_s
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
@ -1373,7 +1373,7 @@
|
|||||||
local.set $4
|
local.set $4
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1688,7 +1688,6 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.const 1065353216
|
i32.const 1065353216
|
||||||
@ -2620,7 +2619,8 @@
|
|||||||
local.get $4
|
local.get $4
|
||||||
local.get $5
|
local.get $5
|
||||||
i64.gt_s
|
i64.gt_s
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
i64.ge_u
|
i64.ge_u
|
||||||
@ -2649,7 +2649,7 @@
|
|||||||
local.set $4
|
local.set $4
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
|
@ -42,14 +42,12 @@
|
|||||||
call $call-optional/opt
|
call $call-optional/opt
|
||||||
)
|
)
|
||||||
(func $start:call-optional (; 3 ;) (type $FUNCSIG$v)
|
(func $start:call-optional (; 3 ;) (type $FUNCSIG$v)
|
||||||
block (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
call $call-optional/opt|trampoline
|
call $call-optional/opt|trampoline
|
||||||
end
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -61,14 +59,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.const 4
|
i32.const 4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
call $call-optional/opt|trampoline
|
call $call-optional/opt|trampoline
|
||||||
end
|
|
||||||
i32.const 5
|
i32.const 5
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -95,7 +91,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 3
|
i32.const 3
|
||||||
@ -103,7 +98,6 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
global.get $call-optional/optIndirect
|
global.get $call-optional/optIndirect
|
||||||
call_indirect (type $FUNCSIG$iiii)
|
call_indirect (type $FUNCSIG$iiii)
|
||||||
end
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -115,7 +109,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 3
|
i32.const 3
|
||||||
@ -123,7 +116,6 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
global.get $call-optional/optIndirect
|
global.get $call-optional/optIndirect
|
||||||
call_indirect (type $FUNCSIG$iiii)
|
call_indirect (type $FUNCSIG$iiii)
|
||||||
end
|
|
||||||
i32.const 5
|
i32.const 5
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -135,7 +127,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 3
|
i32.const 3
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 3
|
i32.const 3
|
||||||
@ -143,7 +134,6 @@
|
|||||||
i32.const 5
|
i32.const 5
|
||||||
global.get $call-optional/optIndirect
|
global.get $call-optional/optIndirect
|
||||||
call_indirect (type $FUNCSIG$iiii)
|
call_indirect (type $FUNCSIG$iiii)
|
||||||
end
|
|
||||||
i32.const 12
|
i32.const 12
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
|
@ -330,9 +330,7 @@
|
|||||||
)
|
)
|
||||||
(func $call-super/test4 (; 10 ;) (type $FUNCSIG$v)
|
(func $call-super/test4 (; 10 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
block (result i32)
|
|
||||||
call $call-super/H#constructor
|
call $call-super/H#constructor
|
||||||
end
|
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.load
|
i32.load
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -381,9 +379,7 @@
|
|||||||
)
|
)
|
||||||
(func $call-super/test5 (; 12 ;) (type $FUNCSIG$v)
|
(func $call-super/test5 (; 12 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
block (result i32)
|
|
||||||
call $call-super/J#constructor
|
call $call-super/J#constructor
|
||||||
end
|
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.load
|
i32.load
|
||||||
i32.const 1
|
i32.const 1
|
||||||
|
@ -110,7 +110,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
)
|
)
|
||||||
(func $call-super/A#constructor (; 3 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $call-super/A#constructor (; 3 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -124,7 +123,6 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
i32.load
|
i32.load
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -312,7 +310,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
)
|
)
|
||||||
(func $call-super/E#constructor (; 10 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $call-super/E#constructor (; 10 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -326,7 +323,6 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
i32.load
|
i32.load
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
|
@ -129,7 +129,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
@ -143,7 +143,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
|
@ -13,19 +13,15 @@
|
|||||||
(func $start:comma (; 1 ;) (type $FUNCSIG$v)
|
(func $start:comma (; 1 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block
|
|
||||||
block (result i32)
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $comma/a
|
global.set $comma/a
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
global.set $comma/b
|
global.set $comma/b
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
drop
|
drop
|
||||||
end
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -50,14 +46,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $comma/a
|
global.set $comma/a
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
global.set $comma/b
|
global.set $comma/b
|
||||||
end
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -82,19 +76,15 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $comma/b
|
global.set $comma/b
|
||||||
global.get $comma/b
|
global.get $comma/b
|
||||||
end
|
|
||||||
global.set $comma/a
|
global.set $comma/a
|
||||||
block (result i32)
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $comma/a
|
global.set $comma/a
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
end
|
|
||||||
global.set $comma/b
|
global.set $comma/b
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -120,17 +110,13 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $comma/a
|
global.set $comma/a
|
||||||
block (result i32)
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
global.set $comma/b
|
global.set $comma/b
|
||||||
global.get $comma/b
|
global.get $comma/b
|
||||||
end
|
|
||||||
end
|
|
||||||
global.set $comma/a
|
global.set $comma/a
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 2
|
i32.const 2
|
||||||
@ -159,14 +145,13 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $1
|
local.get $1
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
i32.eqz
|
i32.eqz
|
||||||
br_if $break|0
|
br_if $break|0
|
||||||
nop
|
nop
|
||||||
block
|
|
||||||
global.get $comma/a
|
global.get $comma/a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -175,9 +160,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
end
|
br $loop|0
|
||||||
br $repeat|0
|
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -193,14 +176,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
drop
|
drop
|
||||||
i32.const 2
|
i32.const 2
|
||||||
drop
|
drop
|
||||||
i32.const 3
|
i32.const 3
|
||||||
drop
|
drop
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $start (; 2 ;) (type $FUNCSIG$v)
|
(func $start (; 2 ;) (type $FUNCSIG$v)
|
||||||
call $start:comma
|
call $start:comma
|
||||||
|
@ -154,7 +154,6 @@
|
|||||||
global.set $constructor/ctorAllocates
|
global.set $constructor/ctorAllocates
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
block (result i32)
|
|
||||||
global.get $constructor/b
|
global.get $constructor/b
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -164,7 +163,6 @@
|
|||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
end
|
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.const 12
|
i32.const 12
|
||||||
|
@ -223,7 +223,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
)
|
)
|
||||||
(func $constructor/CtorAllocates#constructor (; 10 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $constructor/CtorAllocates#constructor (; 10 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -234,14 +233,12 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
drop
|
drop
|
||||||
local.get $0
|
local.get $0
|
||||||
)
|
)
|
||||||
(func $constructor/CtorConditionallyAllocates#constructor (; 11 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $constructor/CtorConditionallyAllocates#constructor (; 11 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
global.get $constructor/b
|
global.get $constructor/b
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -252,7 +249,6 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
drop
|
drop
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
|
@ -13,9 +13,7 @@
|
|||||||
(start $start)
|
(start $start)
|
||||||
(func $start:do (; 1 ;) (type $FUNCSIG$v)
|
(func $start:do (; 1 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
block $break|0
|
|
||||||
loop $continue|0
|
loop $continue|0
|
||||||
block
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -24,11 +22,9 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $do/m
|
global.set $do/m
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
br_if $continue|0
|
br_if $continue|0
|
||||||
end
|
end
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -55,20 +51,16 @@
|
|||||||
end
|
end
|
||||||
i32.const 10
|
i32.const 10
|
||||||
global.set $do/n
|
global.set $do/n
|
||||||
block $break|1
|
|
||||||
loop $continue|1
|
loop $continue|1
|
||||||
nop
|
nop
|
||||||
block (result i32)
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
global.set $do/n
|
global.set $do/n
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
br_if $continue|1
|
br_if $continue|1
|
||||||
end
|
end
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const -1
|
i32.const -1
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -85,9 +77,7 @@
|
|||||||
global.set $do/n
|
global.set $do/n
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $do/m
|
global.set $do/m
|
||||||
block $break|2
|
|
||||||
loop $continue|2
|
loop $continue|2
|
||||||
block
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -96,9 +86,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $do/m
|
global.set $do/m
|
||||||
block $break|3
|
|
||||||
loop $continue|3
|
loop $continue|3
|
||||||
block
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -107,11 +95,9 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $do/o
|
global.set $do/o
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
br_if $continue|3
|
br_if $continue|3
|
||||||
end
|
end
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -136,11 +122,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
br_if $continue|2
|
br_if $continue|2
|
||||||
end
|
end
|
||||||
end
|
|
||||||
global.get $do/n
|
global.get $do/n
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"asc_flags": [
|
"asc_flags": [
|
||||||
"--runtime half",
|
"--runtime none",
|
||||||
"--use ASC_RTRACE=1"
|
"--use ASC_RTRACE=1"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -164,7 +164,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
)
|
)
|
||||||
(func $exports/Car#constructor (; 6 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
(func $exports/Car#constructor (; 6 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -178,7 +177,6 @@
|
|||||||
local.get $1
|
local.get $1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -199,7 +197,6 @@
|
|||||||
global.get $exports/vehicles.Car.TIRES
|
global.get $exports/vehicles.Car.TIRES
|
||||||
)
|
)
|
||||||
(func $exports/vehicles.Car#constructor (; 11 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
(func $exports/vehicles.Car#constructor (; 11 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -213,7 +210,6 @@
|
|||||||
local.get $1
|
local.get $1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 10
|
i32.const 10
|
||||||
@ -22,7 +22,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
@ -36,7 +36,7 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 10
|
i32.const 10
|
||||||
@ -46,10 +46,10 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.le_s
|
i32.le_s
|
||||||
@ -59,7 +59,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
@ -71,7 +71,7 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -81,20 +81,20 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
loop $repeat|4
|
loop $loop|4
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
br_if $repeat|4
|
br_if $loop|4
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|5
|
loop $loop|5
|
||||||
block $break|5
|
block $break|5
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 10
|
i32.const 10
|
||||||
@ -104,7 +104,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|5
|
br $loop|5
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -120,7 +120,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|6
|
loop $loop|6
|
||||||
block $break|6
|
block $break|6
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 10
|
i32.const 10
|
||||||
@ -128,7 +128,7 @@
|
|||||||
br_if $break|6
|
br_if $break|6
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|7
|
loop $loop|7
|
||||||
block $break|7
|
block $break|7
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 10
|
i32.const 10
|
||||||
@ -144,14 +144,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|7
|
br $loop|7
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|6
|
br $loop|6
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -27,8 +27,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -47,7 +46,7 @@
|
|||||||
block $break|1
|
block $break|1
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -57,13 +56,12 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|2
|
block $break|2
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.gt_s
|
i32.gt_s
|
||||||
@ -74,8 +72,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -92,10 +89,7 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|3
|
block $break|3
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
i32.const 1
|
|
||||||
i32.eqz
|
|
||||||
br_if $break|3
|
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -106,51 +100,43 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|4
|
block $break|4
|
||||||
loop $repeat|4
|
loop $loop|4
|
||||||
i32.const 1
|
|
||||||
i32.eqz
|
|
||||||
br_if $break|4
|
|
||||||
block (result i32)
|
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
global.set $for/i
|
global.set $for/i
|
||||||
global.get $for/i
|
global.get $for/i
|
||||||
end
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
if
|
if
|
||||||
br $break|4
|
br $break|4
|
||||||
end
|
end
|
||||||
br $repeat|4
|
br $loop|4
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|5
|
block $break|5
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|5
|
loop $loop|5
|
||||||
block $continue|5
|
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
i32.eqz
|
i32.eqz
|
||||||
br_if $break|5
|
br_if $break|5
|
||||||
|
block $continue|5
|
||||||
br $continue|5
|
br $continue|5
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|5
|
br $loop|5
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -169,7 +155,7 @@
|
|||||||
block $break|6
|
block $break|6
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|6
|
loop $loop|6
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -178,13 +164,13 @@
|
|||||||
block $break|7
|
block $break|7
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|7
|
loop $loop|7
|
||||||
block $continue|7
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
i32.eqz
|
i32.eqz
|
||||||
br_if $break|7
|
br_if $break|7
|
||||||
|
block $continue|7
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -196,8 +182,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|7
|
br $loop|7
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -205,8 +190,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|6
|
br $loop|6
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -68,13 +68,11 @@
|
|||||||
i32.const 10
|
i32.const 10
|
||||||
)
|
)
|
||||||
(func $start:function-expression (; 15 ;) (type $FUNCSIG$v)
|
(func $start:function-expression (; 15 ;) (type $FUNCSIG$v)
|
||||||
block (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 1
|
i32.const 1
|
||||||
global.get $function-expression/f1
|
global.get $function-expression/f1
|
||||||
call_indirect (type $FUNCSIG$ii)
|
call_indirect (type $FUNCSIG$ii)
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -86,13 +84,11 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.get $function-expression/f2
|
global.get $function-expression/f2
|
||||||
call_indirect (type $FUNCSIG$ii)
|
call_indirect (type $FUNCSIG$ii)
|
||||||
end
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -104,18 +100,14 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
global.get $function-expression/f3
|
global.get $function-expression/f3
|
||||||
call_indirect (type $FUNCSIG$v)
|
call_indirect (type $FUNCSIG$v)
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
global.get $function-expression/f4
|
global.get $function-expression/f4
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -166,14 +158,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const 2
|
i32.const 2
|
||||||
call $function-expression/testOmittedReturn1
|
call $function-expression/testOmittedReturn1
|
||||||
call_indirect (type $FUNCSIG$iii)
|
call_indirect (type $FUNCSIG$iii)
|
||||||
end
|
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -185,14 +175,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const 2
|
i32.const 2
|
||||||
call $function-expression/testOmittedReturn2
|
call $function-expression/testOmittedReturn2
|
||||||
call_indirect (type $FUNCSIG$iii)
|
call_indirect (type $FUNCSIG$iii)
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -204,14 +192,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const 2
|
i32.const 2
|
||||||
call $function-expression/testOmittedReturn3
|
call $function-expression/testOmittedReturn3
|
||||||
call_indirect (type $FUNCSIG$iii)
|
call_indirect (type $FUNCSIG$iii)
|
||||||
end
|
|
||||||
i32.const 42
|
i32.const 42
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
|
@ -91,14 +91,12 @@
|
|||||||
(func $start:function-types (; 12 ;) (type $FUNCSIG$v)
|
(func $start:function-types (; 12 ;) (type $FUNCSIG$v)
|
||||||
call $function-types/makeAdder<i32>
|
call $function-types/makeAdder<i32>
|
||||||
global.set $function-types/i32Adder
|
global.set $function-types/i32Adder
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.get $function-types/i32Adder
|
global.get $function-types/i32Adder
|
||||||
call_indirect (type $FUNCSIG$iii)
|
call_indirect (type $FUNCSIG$iii)
|
||||||
end
|
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -112,14 +110,12 @@
|
|||||||
end
|
end
|
||||||
call $function-types/makeAdder<i64>
|
call $function-types/makeAdder<i64>
|
||||||
global.set $function-types/i64Adder
|
global.set $function-types/i64Adder
|
||||||
block (result i64)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i64.const 10
|
i64.const 10
|
||||||
i64.const 20
|
i64.const 20
|
||||||
global.get $function-types/i64Adder
|
global.get $function-types/i64Adder
|
||||||
call_indirect (type $FUNCSIG$jjj)
|
call_indirect (type $FUNCSIG$jjj)
|
||||||
end
|
|
||||||
i64.const 30
|
i64.const 30
|
||||||
i64.eq
|
i64.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -131,14 +127,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result f64)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
f64.const 1.5
|
f64.const 1.5
|
||||||
f64.const 2.5
|
f64.const 2.5
|
||||||
call $function-types/makeAdder<f64>
|
call $function-types/makeAdder<f64>
|
||||||
call_indirect (type $FUNCSIG$ddd)
|
call_indirect (type $FUNCSIG$ddd)
|
||||||
end
|
|
||||||
f64.const 4
|
f64.const 4
|
||||||
f64.eq
|
f64.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -194,14 +188,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.const 0
|
i32.const 0
|
||||||
call $function-types/makeAndAdd<i32>|trampoline
|
call $function-types/makeAndAdd<i32>|trampoline
|
||||||
end
|
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
|
@ -136,13 +136,11 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
call $getter-call/C#constructor
|
call $getter-call/C#constructor
|
||||||
local.set $0
|
local.set $0
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $0
|
local.get $0
|
||||||
call $getter-call/C#get:x
|
call $getter-call/C#get:x
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
|
@ -45,11 +45,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
call $getter-setter/Foo.bar.set:bar
|
call $getter-setter/Foo.bar.set:bar
|
||||||
call $getter-setter/Foo.bar.get:bar
|
call $getter-setter/Foo.bar.get:bar
|
||||||
end
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $if/ifThen (; 2 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $if/ifThen (; 2 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -44,7 +43,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $start:if (; 4 ;) (type $FUNCSIG$v)
|
(func $start:if (; 4 ;) (type $FUNCSIG$v)
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -140,7 +138,6 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $start (; 6 ;) (type $FUNCSIG$v)
|
(func $start (; 6 ;) (type $FUNCSIG$v)
|
||||||
call $start:if
|
call $start:if
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
global.set $infer-type/rf
|
global.set $infer-type/rf
|
||||||
f64.const 0
|
f64.const 0
|
||||||
global.set $infer-type/rF
|
global.set $infer-type/rF
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -27,7 +27,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
@ -80,13 +80,11 @@
|
|||||||
global.get $infer-type/rF
|
global.get $infer-type/rF
|
||||||
drop
|
drop
|
||||||
block $break|0
|
block $break|0
|
||||||
block
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
i32.const 10
|
i32.const 10
|
||||||
local.set $1
|
local.set $1
|
||||||
end
|
loop $loop|0
|
||||||
loop $repeat|0
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -96,8 +94,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -19,24 +19,19 @@
|
|||||||
(local $3 i32)
|
(local $3 i32)
|
||||||
i32.const 1
|
i32.const 1
|
||||||
local.set $0
|
local.set $0
|
||||||
block $inlining-blocklocals/theCall|inlined.0
|
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $1
|
local.tee $1
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
end
|
|
||||||
local.set $3
|
local.set $3
|
||||||
block (result i32)
|
|
||||||
global.get $inlining-blocklocals/b
|
global.get $inlining-blocklocals/b
|
||||||
local.tee $1
|
local.tee $1
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
global.set $inlining-blocklocals/b
|
global.set $inlining-blocklocals/b
|
||||||
local.get $1
|
local.get $1
|
||||||
end
|
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -49,7 +44,6 @@
|
|||||||
global.set $inlining-blocklocals/theCall_b
|
global.set $inlining-blocklocals/theCall_b
|
||||||
local.get $1
|
local.get $1
|
||||||
global.set $inlining-blocklocals/theCall_c
|
global.set $inlining-blocklocals/theCall_c
|
||||||
end
|
|
||||||
global.get $inlining-blocklocals/theCall_a
|
global.get $inlining-blocklocals/theCall_a
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
|
@ -14,9 +14,7 @@
|
|||||||
call $inlining-recursive/bar
|
call $inlining-recursive/bar
|
||||||
)
|
)
|
||||||
(func $inlining-recursive/bar (; 2 ;) (type $FUNCSIG$v)
|
(func $inlining-recursive/bar (; 2 ;) (type $FUNCSIG$v)
|
||||||
block $inlining-recursive/bar|inlined.0
|
|
||||||
call $inlining-recursive/baz
|
call $inlining-recursive/baz
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $null (; 3 ;) (type $FUNCSIG$v)
|
(func $null (; 3 ;) (type $FUNCSIG$v)
|
||||||
)
|
)
|
||||||
|
@ -135,11 +135,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $inlining/func_ii_opt|inlined.0 (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -151,11 +149,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $inlining/func_ii_opt|inlined.1 (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -167,7 +163,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $inlining/func_ii_loc|inlined.0 (result i32)
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -181,7 +176,6 @@
|
|||||||
i32.add
|
i32.add
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $4
|
local.get $4
|
||||||
end
|
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -193,7 +187,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $inlining/func_ii_loc|inlined.1 (result i32)
|
|
||||||
i32.const 3
|
i32.const 3
|
||||||
local.set $5
|
local.set $5
|
||||||
local.get $5
|
local.get $5
|
||||||
@ -207,7 +200,6 @@
|
|||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
local.get $3
|
local.get $3
|
||||||
end
|
|
||||||
i32.const 4
|
i32.const 4
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -219,19 +211,13 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $inlining/func_iv|inlined.0
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
i32.const 2
|
i32.const 2
|
||||||
block $inlining/func_fe|inlined.0 (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
call_indirect (type $FUNCSIG$ii)
|
call_indirect (type $FUNCSIG$ii)
|
||||||
end
|
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -243,7 +229,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $inlining/Foo.method_static|inlined.0 (result i32)
|
|
||||||
i32.const 42
|
i32.const 42
|
||||||
local.set $6
|
local.set $6
|
||||||
i32.const 2
|
i32.const 2
|
||||||
@ -251,7 +236,6 @@
|
|||||||
local.get $6
|
local.get $6
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.add
|
i32.add
|
||||||
end
|
|
||||||
i32.const 44
|
i32.const 44
|
||||||
i32.eq
|
i32.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -266,7 +250,6 @@
|
|||||||
i32.const 123
|
i32.const 123
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $7
|
local.set $7
|
||||||
block $inlining/Foo#method_this|inlined.0 (result i32)
|
|
||||||
local.get $7
|
local.get $7
|
||||||
local.set $4
|
local.set $4
|
||||||
i32.const 43
|
i32.const 43
|
||||||
@ -275,7 +258,6 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
local.get $4
|
local.get $4
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
end
|
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 123
|
i32.const 123
|
||||||
i32.eq
|
i32.eq
|
||||||
@ -391,12 +373,10 @@
|
|||||||
(local $2 i32)
|
(local $2 i32)
|
||||||
(local $3 i32)
|
(local $3 i32)
|
||||||
(local $4 i32)
|
(local $4 i32)
|
||||||
block $inlining/Bar#constructor|inlined.0 (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
i32.const 4
|
i32.const 4
|
||||||
local.set $0
|
local.set $0
|
||||||
block $inlining/Baz#constructor|inlined.0 (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
if (result i32)
|
if (result i32)
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -409,7 +389,6 @@
|
|||||||
local.set $3
|
local.set $3
|
||||||
i32.const 2
|
i32.const 2
|
||||||
local.set $2
|
local.set $2
|
||||||
block (result i32)
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -426,11 +405,9 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
local.get $3
|
local.get $3
|
||||||
end
|
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
local.get $3
|
local.get $3
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 3
|
i32.const 3
|
||||||
@ -442,7 +419,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
i32.store offset=12
|
i32.store offset=12
|
||||||
local.get $1
|
local.get $1
|
||||||
end
|
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load
|
i32.load
|
||||||
|
@ -19,11 +19,9 @@
|
|||||||
(export "memory" (memory $0))
|
(export "memory" (memory $0))
|
||||||
(start $start)
|
(start $start)
|
||||||
(func $instanceof/isI32<i32> (; 1 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $instanceof/isI32<i32> (; 1 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
if
|
if
|
||||||
i32.const 1
|
i32.const 1
|
||||||
return
|
return
|
||||||
@ -32,14 +30,11 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $instanceof/isI32<f64> (; 2 ;) (type $FUNCSIG$id) (param $0 f64) (result i32)
|
(func $instanceof/isI32<f64> (; 2 ;) (type $FUNCSIG$id) (param $0 f64) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
if
|
if
|
||||||
i32.const 1
|
i32.const 1
|
||||||
return
|
return
|
||||||
@ -48,14 +43,11 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $instanceof/isI32<u32> (; 3 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $instanceof/isI32<u32> (; 3 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
if
|
if
|
||||||
i32.const 1
|
i32.const 1
|
||||||
return
|
return
|
||||||
@ -64,14 +56,11 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $instanceof/isI32<u16> (; 4 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $instanceof/isI32<u16> (; 4 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
if
|
if
|
||||||
i32.const 1
|
i32.const 1
|
||||||
return
|
return
|
||||||
@ -80,7 +69,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
)
|
)
|
||||||
(func $~lib/rt/stub/__retain (; 5 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
(func $~lib/rt/stub/__retain (; 5 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -91,11 +79,9 @@
|
|||||||
(func $start:instanceof (; 7 ;) (type $FUNCSIG$v)
|
(func $start:instanceof (; 7 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/a
|
global.get $instanceof/a
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -105,11 +91,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/b
|
global.get $instanceof/b
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -119,11 +103,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/i
|
global.get $instanceof/i
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -134,11 +116,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/I
|
global.get $instanceof/I
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -149,11 +129,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/f
|
global.get $instanceof/f
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -164,11 +142,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/F
|
global.get $instanceof/F
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -179,11 +155,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/b
|
global.get $instanceof/b
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -193,11 +167,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/i
|
global.get $instanceof/i
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -208,11 +180,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/I
|
global.get $instanceof/I
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -223,11 +193,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/f
|
global.get $instanceof/f
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -238,11 +206,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/F
|
global.get $instanceof/F
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -253,11 +219,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/a
|
global.get $instanceof/a
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -268,11 +232,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/b
|
global.get $instanceof/b
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -283,11 +245,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/i
|
global.get $instanceof/i
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -297,11 +257,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/I
|
global.get $instanceof/I
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -312,11 +270,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/f
|
global.get $instanceof/f
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -327,11 +283,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/F
|
global.get $instanceof/F
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -342,11 +296,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/a
|
global.get $instanceof/a
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -357,11 +309,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/b
|
global.get $instanceof/b
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -372,11 +322,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/i
|
global.get $instanceof/i
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -387,11 +335,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/I
|
global.get $instanceof/I
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -401,11 +347,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/f
|
global.get $instanceof/f
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -416,11 +360,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/F
|
global.get $instanceof/F
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -431,11 +373,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/a
|
global.get $instanceof/a
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -446,11 +386,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/b
|
global.get $instanceof/b
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -461,11 +399,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/i
|
global.get $instanceof/i
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -476,11 +412,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/I
|
global.get $instanceof/I
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -491,11 +425,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/f
|
global.get $instanceof/f
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -505,11 +437,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/F
|
global.get $instanceof/F
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -520,11 +450,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/a
|
global.get $instanceof/a
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -535,11 +463,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/b
|
global.get $instanceof/b
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -550,11 +476,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/i
|
global.get $instanceof/i
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -565,11 +489,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/I
|
global.get $instanceof/I
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -580,11 +502,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/f
|
global.get $instanceof/f
|
||||||
drop
|
drop
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -595,11 +515,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/F
|
global.get $instanceof/F
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -669,11 +587,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/an
|
global.get $instanceof/an
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -683,7 +599,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
local.tee $0
|
local.tee $0
|
||||||
global.get $instanceof/an
|
global.get $instanceof/an
|
||||||
@ -697,7 +612,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
global.set $instanceof/an
|
global.set $instanceof/an
|
||||||
global.get $instanceof/an
|
global.get $instanceof/an
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -711,11 +625,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $instanceof/an
|
global.get $instanceof/an
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
|
@ -25,8 +25,6 @@
|
|||||||
f64.ne
|
f64.ne
|
||||||
if (result i32)
|
if (result i32)
|
||||||
unreachable
|
unreachable
|
||||||
f64.const 0
|
|
||||||
unreachable
|
|
||||||
else
|
else
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
end
|
||||||
@ -45,8 +43,6 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
else
|
else
|
||||||
unreachable
|
unreachable
|
||||||
f64.const 0
|
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -75,8 +71,6 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
else
|
else
|
||||||
unreachable
|
unreachable
|
||||||
f64.const 0
|
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
|
5
tests/compiler/loop-flow.json
Normal file
5
tests/compiler/loop-flow.json
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
"asc_flags": [
|
||||||
|
"--runtime none"
|
||||||
|
]
|
||||||
|
}
|
165
tests/compiler/loop-flow.optimized.wat
Normal file
165
tests/compiler/loop-flow.optimized.wat
Normal file
@ -0,0 +1,165 @@
|
|||||||
|
(module
|
||||||
|
(type $FUNCSIG$i (func (result i32)))
|
||||||
|
(type $FUNCSIG$viiii (func (param i32 i32 i32 i32)))
|
||||||
|
(type $FUNCSIG$ii (func (param i32) (result i32)))
|
||||||
|
(type $FUNCSIG$v (func))
|
||||||
|
(import "env" "abort" (func $~lib/builtins/abort (param i32 i32 i32 i32)))
|
||||||
|
(memory $0 1)
|
||||||
|
(data (i32.const 8) "\18\00\00\00\01\00\00\00\01\00\00\00\18\00\00\00l\00o\00o\00p\00-\00f\00l\00o\00w\00.\00t\00s")
|
||||||
|
(data (i32.const 48) "\08\00\00\00\01\00\00\00\01\00\00\00\08\00\00\00t\00e\00r\00m")
|
||||||
|
(export "memory" (memory $0))
|
||||||
|
(export "whileReturn" (func $loop-flow/whileReturn))
|
||||||
|
(export "whileThrow" (func $loop-flow/whileThrow))
|
||||||
|
(export "whileContinue" (func $loop-flow/whileContinue))
|
||||||
|
(export "whileAny" (func $loop-flow/whileAny))
|
||||||
|
(export "forReturn" (func $loop-flow/whileReturn))
|
||||||
|
(export "forThrow" (func $loop-flow/forThrow))
|
||||||
|
(export "forContinue" (func $loop-flow/whileContinue))
|
||||||
|
(export "forAny" (func $loop-flow/forAny))
|
||||||
|
(export "doReturn" (func $loop-flow/whileReturn))
|
||||||
|
(export "doThrow" (func $loop-flow/doThrow))
|
||||||
|
(export "doAny" (func $loop-flow/doAny))
|
||||||
|
(start $start)
|
||||||
|
(func $loop-flow/whileReturn (; 1 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 1
|
||||||
|
)
|
||||||
|
(func $loop-flow/whileAny (; 2 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
|
loop $continue|0 (result i32)
|
||||||
|
local.get $0
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
if (result i32)
|
||||||
|
i32.const 1
|
||||||
|
else
|
||||||
|
local.get $0
|
||||||
|
i32.const 2
|
||||||
|
i32.ne
|
||||||
|
br_if $continue|0
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 24
|
||||||
|
i32.const 21
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
end
|
||||||
|
)
|
||||||
|
(func $loop-flow/forAny (; 3 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
|
loop $loop|0 (result i32)
|
||||||
|
local.get $0
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
if (result i32)
|
||||||
|
i32.const 1
|
||||||
|
else
|
||||||
|
local.get $0
|
||||||
|
i32.const 2
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 54
|
||||||
|
i32.const 21
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
br $loop|0
|
||||||
|
end
|
||||||
|
end
|
||||||
|
)
|
||||||
|
(func $loop-flow/doAny (; 4 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
|
loop $continue|0 (result i32)
|
||||||
|
local.get $0
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
if (result i32)
|
||||||
|
i32.const 1
|
||||||
|
else
|
||||||
|
local.get $0
|
||||||
|
i32.const 2
|
||||||
|
i32.ne
|
||||||
|
br_if $continue|0
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 78
|
||||||
|
i32.const 21
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
end
|
||||||
|
)
|
||||||
|
(func $start:loop-flow (; 5 ;) (type $FUNCSIG$v)
|
||||||
|
i32.const 1
|
||||||
|
call $loop-flow/whileAny
|
||||||
|
i32.const 1
|
||||||
|
i32.ne
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 29
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
i32.const 1
|
||||||
|
call $loop-flow/forAny
|
||||||
|
i32.const 1
|
||||||
|
i32.ne
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 59
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
i32.const 1
|
||||||
|
call $loop-flow/doAny
|
||||||
|
i32.const 1
|
||||||
|
i32.ne
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 83
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
)
|
||||||
|
(func $loop-flow/whileThrow (; 6 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 11
|
||||||
|
i32.const 4
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/whileContinue (; 7 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
loop $continue|0
|
||||||
|
br $continue|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/forThrow (; 8 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 41
|
||||||
|
i32.const 4
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/doThrow (; 9 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 71
|
||||||
|
i32.const 4
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $start (; 10 ;) (type $FUNCSIG$v)
|
||||||
|
call $start:loop-flow
|
||||||
|
)
|
||||||
|
(func $null (; 11 ;) (type $FUNCSIG$v)
|
||||||
|
nop
|
||||||
|
)
|
||||||
|
)
|
83
tests/compiler/loop-flow.ts
Normal file
83
tests/compiler/loop-flow.ts
Normal file
@ -0,0 +1,83 @@
|
|||||||
|
export function whileReturn(): i32 {
|
||||||
|
while (true) {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(whileReturn() == 1);
|
||||||
|
|
||||||
|
export function whileThrow(): i32 {
|
||||||
|
while (true) {
|
||||||
|
throw new Error("term");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export function whileContinue(): i32 {
|
||||||
|
while (true) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export function whileAny(a: i32): i32 {
|
||||||
|
while (true) {
|
||||||
|
if (a == 1) return 1;
|
||||||
|
else if (a == 2) throw new Error("term");
|
||||||
|
else continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(whileAny(1) == 1);
|
||||||
|
|
||||||
|
export function forReturn(): i32 {
|
||||||
|
for (;;) {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(forReturn() == 1);
|
||||||
|
|
||||||
|
export function forThrow(): i32 {
|
||||||
|
for (;;) {
|
||||||
|
throw new Error("term");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export function forContinue(): i32 {
|
||||||
|
for (;;) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export function forAny(a: i32): i32 {
|
||||||
|
for (;;) {
|
||||||
|
if (a == 1) return 1;
|
||||||
|
else if (a == 2) throw new Error("term");
|
||||||
|
else continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(forAny(1) == 1);
|
||||||
|
|
||||||
|
export function doReturn(): i32 {
|
||||||
|
do {
|
||||||
|
return 1;
|
||||||
|
} while (true);
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(doReturn() == 1);
|
||||||
|
|
||||||
|
export function doThrow(): i32 {
|
||||||
|
do {
|
||||||
|
throw new Error("term");
|
||||||
|
} while (true);
|
||||||
|
}
|
||||||
|
|
||||||
|
export function doAny(a: i32): i32 {
|
||||||
|
do {
|
||||||
|
if (a == 1) return 1;
|
||||||
|
else if (a == 2) throw new Error("term");
|
||||||
|
else continue;
|
||||||
|
} while (true);
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(doAny(1) == 1);
|
242
tests/compiler/loop-flow.untouched.wat
Normal file
242
tests/compiler/loop-flow.untouched.wat
Normal file
@ -0,0 +1,242 @@
|
|||||||
|
(module
|
||||||
|
(type $FUNCSIG$i (func (result i32)))
|
||||||
|
(type $FUNCSIG$viiii (func (param i32 i32 i32 i32)))
|
||||||
|
(type $FUNCSIG$ii (func (param i32) (result i32)))
|
||||||
|
(type $FUNCSIG$v (func))
|
||||||
|
(import "env" "abort" (func $~lib/builtins/abort (param i32 i32 i32 i32)))
|
||||||
|
(memory $0 1)
|
||||||
|
(data (i32.const 8) "\18\00\00\00\01\00\00\00\01\00\00\00\18\00\00\00l\00o\00o\00p\00-\00f\00l\00o\00w\00.\00t\00s\00")
|
||||||
|
(data (i32.const 48) "\08\00\00\00\01\00\00\00\01\00\00\00\08\00\00\00t\00e\00r\00m\00")
|
||||||
|
(table $0 1 funcref)
|
||||||
|
(elem (i32.const 0) $null)
|
||||||
|
(export "memory" (memory $0))
|
||||||
|
(export "whileReturn" (func $loop-flow/whileReturn))
|
||||||
|
(export "whileThrow" (func $loop-flow/whileThrow))
|
||||||
|
(export "whileContinue" (func $loop-flow/whileContinue))
|
||||||
|
(export "whileAny" (func $loop-flow/whileAny))
|
||||||
|
(export "forReturn" (func $loop-flow/forReturn))
|
||||||
|
(export "forThrow" (func $loop-flow/forThrow))
|
||||||
|
(export "forContinue" (func $loop-flow/forContinue))
|
||||||
|
(export "forAny" (func $loop-flow/forAny))
|
||||||
|
(export "doReturn" (func $loop-flow/doReturn))
|
||||||
|
(export "doThrow" (func $loop-flow/doThrow))
|
||||||
|
(export "doAny" (func $loop-flow/doAny))
|
||||||
|
(start $start)
|
||||||
|
(func $loop-flow/whileReturn (; 1 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 1
|
||||||
|
return
|
||||||
|
)
|
||||||
|
(func $loop-flow/whileAny (; 2 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
|
loop $continue|0
|
||||||
|
local.get $0
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 1
|
||||||
|
return
|
||||||
|
else
|
||||||
|
local.get $0
|
||||||
|
i32.const 2
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 24
|
||||||
|
i32.const 21
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
else
|
||||||
|
br $continue|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/forReturn (; 3 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 1
|
||||||
|
return
|
||||||
|
)
|
||||||
|
(func $loop-flow/forAny (; 4 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
|
loop $loop|0
|
||||||
|
block $continue|0
|
||||||
|
local.get $0
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 1
|
||||||
|
return
|
||||||
|
else
|
||||||
|
local.get $0
|
||||||
|
i32.const 2
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 54
|
||||||
|
i32.const 21
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
else
|
||||||
|
br $continue|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
br $loop|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/doReturn (; 5 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 1
|
||||||
|
return
|
||||||
|
)
|
||||||
|
(func $loop-flow/doAny (; 6 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
||||||
|
loop $continue|0
|
||||||
|
local.get $0
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 1
|
||||||
|
return
|
||||||
|
else
|
||||||
|
local.get $0
|
||||||
|
i32.const 2
|
||||||
|
i32.eq
|
||||||
|
if
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 78
|
||||||
|
i32.const 21
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
else
|
||||||
|
br $continue|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $start:loop-flow (; 7 ;) (type $FUNCSIG$v)
|
||||||
|
call $loop-flow/whileReturn
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 7
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
i32.const 1
|
||||||
|
call $loop-flow/whileAny
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 29
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
call $loop-flow/forReturn
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 37
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
i32.const 1
|
||||||
|
call $loop-flow/forAny
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 59
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
call $loop-flow/doReturn
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 67
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
i32.const 1
|
||||||
|
call $loop-flow/doAny
|
||||||
|
i32.const 1
|
||||||
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
|
if
|
||||||
|
i32.const 0
|
||||||
|
i32.const 24
|
||||||
|
i32.const 83
|
||||||
|
i32.const 0
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
|
)
|
||||||
|
(func $loop-flow/whileThrow (; 8 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 11
|
||||||
|
i32.const 4
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/whileContinue (; 9 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
loop $continue|0
|
||||||
|
br $continue|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/forThrow (; 10 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 41
|
||||||
|
i32.const 4
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/forContinue (; 11 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
loop $loop|0
|
||||||
|
br $loop|0
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $loop-flow/doThrow (; 12 ;) (type $FUNCSIG$i) (result i32)
|
||||||
|
i32.const 64
|
||||||
|
i32.const 24
|
||||||
|
i32.const 71
|
||||||
|
i32.const 4
|
||||||
|
call $~lib/builtins/abort
|
||||||
|
unreachable
|
||||||
|
)
|
||||||
|
(func $start (; 13 ;) (type $FUNCSIG$v)
|
||||||
|
call $start:loop-flow
|
||||||
|
)
|
||||||
|
(func $null (; 14 ;) (type $FUNCSIG$v)
|
||||||
|
)
|
||||||
|
)
|
@ -430,7 +430,7 @@
|
|||||||
f64.convert_i32_u
|
f64.convert_i32_u
|
||||||
f64.min
|
f64.min
|
||||||
local.set $14
|
local.set $14
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $7
|
local.get $7
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -450,6 +450,7 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $6
|
local.set $6
|
||||||
loop $continue|1
|
loop $continue|1
|
||||||
|
block $break|1
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $4
|
local.get $4
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -461,8 +462,8 @@
|
|||||||
f64.add
|
f64.add
|
||||||
f64.const 4
|
f64.const 4
|
||||||
f64.le
|
f64.le
|
||||||
if
|
i32.eqz
|
||||||
block $break|1
|
br_if $break|1
|
||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $4
|
local.get $4
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -488,7 +489,6 @@
|
|||||||
br $continue|1
|
br $continue|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
|
||||||
loop $continue|2
|
loop $continue|2
|
||||||
local.get $6
|
local.get $6
|
||||||
f64.convert_i32_u
|
f64.convert_i32_u
|
||||||
@ -504,7 +504,6 @@
|
|||||||
f64.sub
|
f64.sub
|
||||||
local.get $11
|
local.get $11
|
||||||
f64.add
|
f64.add
|
||||||
local.set $8
|
|
||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $4
|
local.get $4
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -513,7 +512,6 @@
|
|||||||
local.get $10
|
local.get $10
|
||||||
f64.add
|
f64.add
|
||||||
local.set $5
|
local.set $5
|
||||||
local.get $8
|
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $6
|
local.get $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -567,7 +565,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $7
|
local.set $7
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
@ -549,7 +549,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $12
|
local.set $12
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $12
|
local.get $12
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -581,7 +581,8 @@
|
|||||||
f64.add
|
f64.add
|
||||||
f64.const 4
|
f64.const 4
|
||||||
f64.le
|
f64.le
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|1
|
||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $14
|
local.get $14
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -608,7 +609,7 @@
|
|||||||
local.set $18
|
local.set $18
|
||||||
br $continue|1
|
br $continue|1
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|2
|
block $break|2
|
||||||
loop $continue|2
|
loop $continue|2
|
||||||
@ -616,7 +617,8 @@
|
|||||||
f64.convert_i32_u
|
f64.convert_i32_u
|
||||||
local.get $11
|
local.get $11
|
||||||
f64.lt
|
f64.lt
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|2
|
||||||
local.get $14
|
local.get $14
|
||||||
local.get $14
|
local.get $14
|
||||||
f64.mul
|
f64.mul
|
||||||
@ -643,7 +645,7 @@
|
|||||||
local.set $18
|
local.set $18
|
||||||
br $continue|2
|
br $continue|2
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
global.get $../../examples/mandelbrot/assembly/index/NUM_COLORS
|
global.get $../../examples/mandelbrot/assembly/index/NUM_COLORS
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -671,7 +673,6 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
f64.convert_i32_s
|
f64.convert_i32_s
|
||||||
block $../../examples/mandelbrot/assembly/index/clamp<f64>|inlined.0 (result f64)
|
|
||||||
local.get $18
|
local.get $18
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
@ -690,7 +691,6 @@
|
|||||||
f64.max
|
f64.max
|
||||||
local.get $22
|
local.get $22
|
||||||
f64.min
|
f64.min
|
||||||
end
|
|
||||||
f64.mul
|
f64.mul
|
||||||
i32.trunc_f64_u
|
i32.trunc_f64_u
|
||||||
local.set $20
|
local.set $20
|
||||||
@ -706,8 +706,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $12
|
local.set $12
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -53,7 +53,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 16
|
i32.const 16
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -235,7 +236,8 @@
|
|||||||
loop $continue|3
|
loop $continue|3
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 17
|
i32.const 17
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -344,7 +346,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 18
|
i32.const 18
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -445,7 +448,8 @@
|
|||||||
loop $continue|5
|
loop $continue|5
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 19
|
i32.const 19
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
|
@ -29,23 +29,20 @@
|
|||||||
else
|
else
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
end
|
||||||
if
|
i32.eqz
|
||||||
block (result i32)
|
br_if $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -54,7 +51,7 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 4
|
i32.const 4
|
||||||
@ -67,7 +64,8 @@
|
|||||||
local.get $2
|
local.get $2
|
||||||
i32.const 16
|
i32.const 16
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|1
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.load
|
i32.load
|
||||||
@ -110,7 +108,7 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
br $continue|1
|
br $continue|1
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
@ -175,22 +173,18 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
end
|
end
|
||||||
@ -226,58 +220,46 @@
|
|||||||
local.get $1
|
local.get $1
|
||||||
i32.load
|
i32.load
|
||||||
local.set $4
|
local.set $4
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -289,7 +271,8 @@
|
|||||||
local.get $2
|
local.get $2
|
||||||
i32.const 17
|
i32.const 17
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|3
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
@ -366,47 +349,39 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
br $continue|3
|
br $continue|3
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
br $break|2
|
br $break|2
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.load
|
i32.load
|
||||||
local.set $4
|
local.set $4
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -418,7 +393,8 @@
|
|||||||
local.get $2
|
local.get $2
|
||||||
i32.const 18
|
i32.const 18
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|4
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 2
|
i32.const 2
|
||||||
i32.add
|
i32.add
|
||||||
@ -495,29 +471,25 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
br $continue|4
|
br $continue|4
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
br $break|2
|
br $break|2
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.load
|
i32.load
|
||||||
local.set $4
|
local.set $4
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -529,7 +501,8 @@
|
|||||||
local.get $2
|
local.get $2
|
||||||
i32.const 19
|
i32.const 19
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|5
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 3
|
i32.const 3
|
||||||
i32.add
|
i32.add
|
||||||
@ -606,7 +579,7 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
br $continue|5
|
br $continue|5
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
br $break|2
|
br $break|2
|
||||||
end
|
end
|
||||||
@ -615,292 +588,228 @@
|
|||||||
i32.const 16
|
i32.const 16
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
end
|
end
|
||||||
@ -908,148 +817,116 @@
|
|||||||
i32.const 8
|
i32.const 8
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
end
|
end
|
||||||
@ -1057,76 +934,60 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
end
|
end
|
||||||
@ -1134,40 +995,32 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
end
|
end
|
||||||
@ -1175,22 +1028,18 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $6
|
local.tee $6
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $6
|
local.get $6
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
end
|
end
|
||||||
|
@ -39,11 +39,7 @@
|
|||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.eqz
|
|
||||||
if
|
if
|
||||||
local.get $3
|
|
||||||
return
|
|
||||||
end
|
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -63,12 +59,18 @@
|
|||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
br $continue|0
|
br $continue|0
|
||||||
|
else
|
||||||
|
local.get $3
|
||||||
|
return
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -131,11 +133,7 @@
|
|||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.eqz
|
|
||||||
if
|
if
|
||||||
local.get $3
|
|
||||||
return
|
|
||||||
end
|
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -148,12 +146,18 @@
|
|||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
br $continue|3
|
br $continue|3
|
||||||
|
else
|
||||||
|
local.get $3
|
||||||
|
return
|
||||||
|
end
|
||||||
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
|
@ -40,7 +40,8 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.rem_u
|
i32.rem_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -51,34 +52,31 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $2
|
local.set $2
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $4
|
local.tee $4
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $4
|
local.get $4
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $4
|
local.tee $4
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $4
|
local.get $4
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|1
|
block $break|1
|
||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|1
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i64.load
|
i64.load
|
||||||
@ -97,29 +95,26 @@
|
|||||||
local.set $1
|
local.set $1
|
||||||
br $continue|1
|
br $continue|1
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
block $break|2
|
block $break|2
|
||||||
loop $continue|2
|
loop $continue|2
|
||||||
local.get $2
|
local.get $2
|
||||||
if
|
i32.eqz
|
||||||
block (result i32)
|
br_if $break|2
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $4
|
local.tee $4
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $4
|
local.get $4
|
||||||
end
|
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $4
|
local.tee $4
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $4
|
local.get $4
|
||||||
end
|
|
||||||
i32.load8_u
|
i32.load8_u
|
||||||
i32.store8
|
i32.store8
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -128,7 +123,7 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
br $continue|2
|
br $continue|2
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -146,7 +141,8 @@
|
|||||||
i32.add
|
i32.add
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.rem_u
|
i32.rem_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|3
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -166,14 +162,15 @@
|
|||||||
i32.store8
|
i32.store8
|
||||||
br $continue|3
|
br $continue|3
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|4
|
block $break|4
|
||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|4
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -188,13 +185,14 @@
|
|||||||
i64.store
|
i64.store
|
||||||
br $continue|4
|
br $continue|4
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
block $break|5
|
block $break|5
|
||||||
loop $continue|5
|
loop $continue|5
|
||||||
local.get $2
|
local.get $2
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|5
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -208,7 +206,7 @@
|
|||||||
i32.store8
|
i32.store8
|
||||||
br $continue|5
|
br $continue|5
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
|
@ -80,7 +80,6 @@
|
|||||||
i32.and
|
i32.and
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $3
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.add
|
i32.add
|
||||||
@ -92,7 +91,6 @@
|
|||||||
i32.mul
|
i32.mul
|
||||||
local.tee $1
|
local.tee $1
|
||||||
i32.store
|
i32.store
|
||||||
local.get $3
|
|
||||||
i32.const -4
|
i32.const -4
|
||||||
i32.and
|
i32.and
|
||||||
local.tee $2
|
local.tee $2
|
||||||
|
@ -240,7 +240,8 @@
|
|||||||
local.get $2
|
local.get $2
|
||||||
i32.const 32
|
i32.const 32
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $6
|
local.get $6
|
||||||
i64.store
|
i64.store
|
||||||
@ -269,7 +270,7 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
)
|
)
|
||||||
|
@ -171,8 +171,12 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.div_u
|
i32.rem_u
|
||||||
local.set $3
|
local.set $3
|
||||||
|
local.get $1
|
||||||
|
i32.const 10
|
||||||
|
i32.div_u
|
||||||
|
local.set $1
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -181,14 +185,11 @@
|
|||||||
i32.shl
|
i32.shl
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.add
|
i32.add
|
||||||
local.get $1
|
local.get $3
|
||||||
i32.const 10
|
|
||||||
i32.rem_u
|
|
||||||
i32.const 48
|
i32.const 48
|
||||||
i32.add
|
i32.add
|
||||||
i32.store16
|
i32.store16
|
||||||
local.get $3
|
local.get $1
|
||||||
local.tee $1
|
|
||||||
br_if $continue|0
|
br_if $continue|0
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
@ -523,8 +524,8 @@
|
|||||||
i64.add
|
i64.add
|
||||||
local.tee $1
|
local.tee $1
|
||||||
local.get $5
|
local.get $5
|
||||||
i64.le_u
|
i64.gt_u
|
||||||
if
|
br_if $continue|0
|
||||||
global.get $~lib/util/number/_K
|
global.get $~lib/util/number/_K
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.add
|
i32.add
|
||||||
@ -595,8 +596,6 @@
|
|||||||
local.get $2
|
local.get $2
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
br $continue|0
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
loop $continue|3
|
loop $continue|3
|
||||||
local.get $5
|
local.get $5
|
||||||
@ -773,7 +772,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -855,7 +855,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -923,7 +924,7 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
end
|
||||||
if (result i32)
|
if (result i32)
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $1
|
local.get $1
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -940,7 +941,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1012,7 +1013,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 2
|
i32.const 2
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1029,7 +1030,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1047,7 +1048,6 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.tee $0
|
local.tee $0
|
||||||
block (result i32)
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -1062,7 +1062,6 @@
|
|||||||
local.set $2
|
local.set $2
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.get $2
|
local.get $2
|
||||||
call $~lib/util/number/decimalCount32
|
call $~lib/util/number/decimalCount32
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -1105,7 +1104,6 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.tee $2
|
local.tee $2
|
||||||
block (result i32)
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -1120,7 +1118,6 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/util/number/decimalCount32
|
call $~lib/util/number/decimalCount32
|
||||||
i32.const 1
|
i32.const 1
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -12,7 +12,6 @@
|
|||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
(local $2 i32)
|
(local $2 i32)
|
||||||
block
|
|
||||||
i32.const 127
|
i32.const 127
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -55,14 +54,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 24
|
i32.const 24
|
||||||
@ -80,14 +77,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 24
|
i32.const 24
|
||||||
@ -205,8 +200,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 32767
|
i32.const 32767
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -249,14 +242,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -274,14 +265,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -399,8 +388,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -439,14 +426,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 255
|
i32.const 255
|
||||||
@ -462,14 +447,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 255
|
i32.const 255
|
||||||
@ -575,8 +558,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
block
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -615,14 +596,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 65535
|
i32.const 65535
|
||||||
@ -638,14 +617,12 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 65535
|
i32.const 65535
|
||||||
@ -751,7 +728,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $start (; 2 ;) (type $FUNCSIG$v)
|
(func $start (; 2 ;) (type $FUNCSIG$v)
|
||||||
call $start:overflow
|
call $start:overflow
|
||||||
|
@ -174,8 +174,8 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
block (result i32)
|
br_if $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.tee $1
|
local.tee $1
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -189,11 +189,10 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
@ -210,8 +209,8 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
block (result i32)
|
br_if $break|0
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -225,11 +224,10 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
@ -248,10 +246,10 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
local.get $1
|
local.get $1
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -265,12 +263,11 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
end
|
end
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
@ -387,7 +384,6 @@
|
|||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
drop
|
drop
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -401,7 +397,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
|
@ -719,7 +719,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -734,7 +734,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -755,14 +755,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 304
|
i32.const 304
|
||||||
@ -1175,7 +1175,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1257,7 +1258,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -717,7 +717,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -732,7 +732,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -753,14 +753,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 320
|
i32.const 320
|
||||||
@ -1172,7 +1172,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1254,7 +1255,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -619,7 +619,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -634,7 +634,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -655,14 +655,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 304
|
i32.const 304
|
||||||
@ -1179,7 +1179,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1261,7 +1262,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -619,7 +619,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -634,7 +634,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -655,14 +655,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 304
|
i32.const 304
|
||||||
@ -1179,7 +1179,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1261,7 +1262,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -619,7 +619,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -634,7 +634,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -655,14 +655,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 304
|
i32.const 304
|
||||||
@ -1167,7 +1167,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1249,7 +1250,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1595,7 +1597,7 @@
|
|||||||
local.set $3
|
local.set $3
|
||||||
global.get $~lib/rt/pure/CUR
|
global.get $~lib/rt/pure/CUR
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -1655,14 +1657,14 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
global.set $~lib/rt/pure/CUR
|
global.set $~lib/rt/pure/CUR
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -1675,12 +1677,12 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
block $break|2
|
block $break|2
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -1700,7 +1702,7 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -621,7 +621,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -636,7 +636,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -657,14 +657,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 304
|
i32.const 304
|
||||||
@ -1190,7 +1190,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1272,7 +1273,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -12,7 +12,7 @@
|
|||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
i32.const -128
|
i32.const -128
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 255
|
i32.const 255
|
||||||
i32.le_s
|
i32.le_s
|
||||||
@ -21,7 +21,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const -1
|
i32.const -1
|
||||||
|
@ -404,7 +404,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
global.get $~lib/builtins/i8.MIN_VALUE
|
global.get $~lib/builtins/i8.MIN_VALUE
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 255
|
i32.const 255
|
||||||
i32.le_s
|
i32.le_s
|
||||||
@ -450,8 +450,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -628,7 +628,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -643,7 +643,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -664,14 +664,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 752
|
i32.const 752
|
||||||
@ -1182,7 +1182,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1264,7 +1265,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1786,14 +1788,12 @@
|
|||||||
i32.and
|
i32.and
|
||||||
local.tee $1
|
local.tee $1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $2
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.add
|
i32.add
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.store
|
i32.store
|
||||||
local.get $2
|
|
||||||
i32.const -4
|
i32.const -4
|
||||||
i32.and
|
i32.and
|
||||||
local.tee $1
|
local.tee $1
|
||||||
@ -2110,10 +2110,8 @@
|
|||||||
if
|
if
|
||||||
i32.const 584
|
i32.const 584
|
||||||
call $~lib/rt/pure/__retain
|
call $~lib/rt/pure/__retain
|
||||||
local.set $0
|
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $0
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -2148,12 +2146,10 @@
|
|||||||
select
|
select
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/string/String#concat
|
call $~lib/string/String#concat
|
||||||
local.set $2
|
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $2
|
|
||||||
)
|
)
|
||||||
(func $~lib/rt/pure/markGray (; 36 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $~lib/rt/pure/markGray (; 36 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
@ -2272,7 +2268,7 @@
|
|||||||
local.set $3
|
local.set $3
|
||||||
global.get $~lib/rt/pure/CUR
|
global.get $~lib/rt/pure/CUR
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -2332,14 +2328,14 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
global.set $~lib/rt/pure/CUR
|
global.set $~lib/rt/pure/CUR
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -2352,12 +2348,12 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
block $break|2
|
block $break|2
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -2377,7 +2373,7 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
@ -2422,8 +2418,7 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
i32.store offset=12
|
i32.store offset=12
|
||||||
local.get $0
|
local.get $0
|
||||||
local.set $1
|
loop $loop|0
|
||||||
loop $repeat|0
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -2442,7 +2437,7 @@
|
|||||||
i32.store offset=12
|
i32.store offset=12
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.const 10
|
i32.const 10
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -2453,19 +2448,18 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
|
||||||
call $~lib/rt/pure/__release
|
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
local.get $0
|
||||||
|
call $~lib/rt/pure/__release
|
||||||
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $1
|
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
i32.const 600
|
i32.const 600
|
||||||
call $~lib/rt/pure/__retain
|
call $~lib/rt/pure/__retain
|
||||||
@ -2477,14 +2471,12 @@
|
|||||||
local.tee $2
|
local.tee $2
|
||||||
i32.const 672
|
i32.const 672
|
||||||
call $~lib/string/String.__concat
|
call $~lib/string/String.__concat
|
||||||
local.set $3
|
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $2
|
local.get $2
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $3
|
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
i32.const 4
|
i32.const 4
|
||||||
i32.const 6
|
i32.const 6
|
||||||
@ -2494,7 +2486,6 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
local.set $3
|
|
||||||
i32.const 4
|
i32.const 4
|
||||||
i32.const 7
|
i32.const 7
|
||||||
call $~lib/rt/tlsf/__alloc
|
call $~lib/rt/tlsf/__alloc
|
||||||
@ -2516,7 +2507,6 @@
|
|||||||
local.get $4
|
local.get $4
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
end
|
end
|
||||||
local.get $3
|
|
||||||
local.get $2
|
local.get $2
|
||||||
i32.store
|
i32.store
|
||||||
local.get $0
|
local.get $0
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -152,8 +152,6 @@
|
|||||||
(func $retain-release/assignGlobal (; 8 ;) (type $FUNCSIG$v)
|
(func $retain-release/assignGlobal (; 8 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
local.set $0
|
|
||||||
local.get $0
|
|
||||||
global.set $retain-release/glo
|
global.set $retain-release/glo
|
||||||
)
|
)
|
||||||
(func $retain-release/assignField (; 9 ;) (type $FUNCSIG$v)
|
(func $retain-release/assignField (; 9 ;) (type $FUNCSIG$v)
|
||||||
|
@ -257,7 +257,6 @@
|
|||||||
(func $retain-release/assignGlobal (; 16 ;) (type $FUNCSIG$v)
|
(func $retain-release/assignGlobal (; 16 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block (result i32)
|
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
local.tee $0
|
local.tee $0
|
||||||
global.get $retain-release/glo
|
global.get $retain-release/glo
|
||||||
@ -271,7 +270,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
global.set $retain-release/glo
|
global.set $retain-release/glo
|
||||||
)
|
)
|
||||||
(func $retain-release/assignField (; 17 ;) (type $FUNCSIG$v)
|
(func $retain-release/assignField (; 17 ;) (type $FUNCSIG$v)
|
||||||
@ -279,7 +277,6 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
global.get $retain-release/TARGET
|
global.get $retain-release/TARGET
|
||||||
local.tee $0
|
local.tee $0
|
||||||
block (result i32)
|
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
local.tee $1
|
local.tee $1
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -294,7 +291,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
end
|
|
||||||
i32.store
|
i32.store
|
||||||
)
|
)
|
||||||
(func $retain-release/scopeBlock (; 18 ;) (type $FUNCSIG$v)
|
(func $retain-release/scopeBlock (; 18 ;) (type $FUNCSIG$v)
|
||||||
@ -315,7 +311,6 @@
|
|||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $1
|
local.set $1
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -329,7 +324,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
@ -347,7 +341,6 @@
|
|||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $1
|
local.set $1
|
||||||
block (result i32)
|
|
||||||
local.get $1
|
local.get $1
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -361,7 +354,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $0
|
local.set $0
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
@ -377,7 +369,6 @@
|
|||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -391,13 +382,11 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
end
|
end
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $2
|
local.set $2
|
||||||
block (result i32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.tee $3
|
local.tee $3
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -411,7 +400,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $2
|
local.get $2
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
@ -441,7 +429,6 @@
|
|||||||
local.set $1
|
local.set $1
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
local.tee $2
|
local.tee $2
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -455,7 +442,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -490,37 +476,9 @@
|
|||||||
end
|
end
|
||||||
)
|
)
|
||||||
(func $retain-release/scopeWhile (; 27 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/scopeWhile (; 27 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
|
||||||
loop $continue|0
|
|
||||||
local.get $0
|
|
||||||
if
|
|
||||||
global.get $retain-release/REF
|
|
||||||
call $~lib/rt/stub/__retain
|
|
||||||
local.set $1
|
|
||||||
local.get $1
|
|
||||||
call $~lib/rt/stub/__release
|
|
||||||
br $continue|0
|
|
||||||
end
|
|
||||||
end
|
|
||||||
)
|
|
||||||
(func $retain-release/scopeDo (; 28 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
||||||
(local $1 i32)
|
|
||||||
loop $continue|0
|
|
||||||
block
|
|
||||||
global.get $retain-release/REF
|
|
||||||
call $~lib/rt/stub/__retain
|
|
||||||
local.set $1
|
|
||||||
local.get $1
|
|
||||||
call $~lib/rt/stub/__release
|
|
||||||
end
|
|
||||||
local.get $0
|
|
||||||
br_if $continue|0
|
|
||||||
end
|
|
||||||
)
|
|
||||||
(func $retain-release/scopeFor (; 29 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block $break|0
|
block $break|0
|
||||||
loop $repeat|0
|
loop $continue|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
br_if $break|0
|
br_if $break|0
|
||||||
@ -529,18 +487,44 @@
|
|||||||
local.set $1
|
local.set $1
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
br $repeat|0
|
br $continue|0
|
||||||
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
)
|
||||||
|
(func $retain-release/scopeDo (; 28 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
|
(local $1 i32)
|
||||||
|
loop $continue|0
|
||||||
|
global.get $retain-release/REF
|
||||||
|
call $~lib/rt/stub/__retain
|
||||||
|
local.set $1
|
||||||
|
local.get $0
|
||||||
|
br_if $continue|0
|
||||||
|
end
|
||||||
|
)
|
||||||
|
(func $retain-release/scopeFor (; 29 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
|
(local $1 i32)
|
||||||
|
block $break|0
|
||||||
|
loop $loop|0
|
||||||
|
local.get $0
|
||||||
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
|
global.get $retain-release/REF
|
||||||
|
call $~lib/rt/stub/__retain
|
||||||
|
local.set $1
|
||||||
|
local.get $1
|
||||||
|
call $~lib/rt/stub/__release
|
||||||
|
br $loop|0
|
||||||
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
(func $retain-release/scopeBreak (; 30 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/scopeBreak (; 30 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block $break|0
|
block $break|0
|
||||||
loop $continue|0
|
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $1
|
local.set $1
|
||||||
@ -548,14 +532,14 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
br $break|0
|
br $break|0
|
||||||
end
|
end
|
||||||
end
|
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $retain-release/scopeContinue (; 31 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/scopeContinue (; 31 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
|
block $break|0
|
||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $1
|
local.set $1
|
||||||
@ -563,44 +547,41 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
(func $retain-release/scopeThrow (; 32 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/scopeThrow (; 32 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
loop $continue|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
block
|
|
||||||
i32.const 24
|
i32.const 24
|
||||||
i32.const 56
|
i32.const 56
|
||||||
i32.const 313
|
i32.const 313
|
||||||
i32.const 4
|
i32.const 4
|
||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
(func $retain-release/scopeUnreachable (; 33 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/scopeUnreachable (; 33 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
|
block $break|0
|
||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $0
|
local.get $0
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
local.set $1
|
local.set $1
|
||||||
unreachable
|
unreachable
|
||||||
local.get $1
|
|
||||||
call $~lib/rt/stub/__release
|
|
||||||
br $continue|0
|
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
(func $retain-release/callInline (; 34 ;) (type $FUNCSIG$v)
|
(func $retain-release/callInline (; 34 ;) (type $FUNCSIG$v)
|
||||||
@ -621,10 +602,8 @@
|
|||||||
)
|
)
|
||||||
(func $retain-release/receiveRefInline (; 36 ;) (type $FUNCSIG$v)
|
(func $retain-release/receiveRefInline (; 36 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
block $retain-release/returnRefInline|inlined.0 (result i32)
|
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
end
|
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
drop
|
drop
|
||||||
@ -632,10 +611,8 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
)
|
)
|
||||||
(func $retain-release/receiveRefInlineDrop (; 37 ;) (type $FUNCSIG$v)
|
(func $retain-release/receiveRefInlineDrop (; 37 ;) (type $FUNCSIG$v)
|
||||||
block $retain-release/returnRefInline|inlined.1 (result i32)
|
|
||||||
global.get $retain-release/REF
|
global.get $retain-release/REF
|
||||||
call $~lib/rt/stub/__retain
|
call $~lib/rt/stub/__retain
|
||||||
end
|
|
||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
)
|
)
|
||||||
(func $retain-release/provideRefIndirect (; 38 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/provideRefIndirect (; 38 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
@ -647,13 +624,11 @@
|
|||||||
)
|
)
|
||||||
(func $retain-release/receiveRefIndirect (; 39 ;) (type $FUNCSIG$vi) (param $0 i32)
|
(func $retain-release/receiveRefIndirect (; 39 ;) (type $FUNCSIG$vi) (param $0 i32)
|
||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
block (result i32)
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
global.set $~lib/argc
|
global.set $~lib/argc
|
||||||
local.get $0
|
local.get $0
|
||||||
call_indirect (type $FUNCSIG$i)
|
call_indirect (type $FUNCSIG$i)
|
||||||
local.tee $1
|
local.tee $1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
drop
|
drop
|
||||||
local.get $1
|
local.get $1
|
||||||
|
@ -238,11 +238,9 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
call $rt/instanceof/BlackCat#constructor
|
call $rt/instanceof/BlackCat#constructor
|
||||||
global.set $rt/instanceof/blackcat
|
global.set $rt/instanceof/blackcat
|
||||||
block (result i32)
|
|
||||||
global.get $rt/instanceof/animal
|
global.get $rt/instanceof/animal
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -292,11 +290,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $rt/instanceof/cat
|
global.get $rt/instanceof/cat
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -345,11 +341,9 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block (result i32)
|
|
||||||
global.get $rt/instanceof/blackcat
|
global.get $rt/instanceof/blackcat
|
||||||
drop
|
drop
|
||||||
i32.const 1
|
i32.const 1
|
||||||
end
|
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
i32.const 0
|
i32.const 0
|
||||||
|
@ -618,7 +618,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -633,7 +633,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -654,14 +654,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 288
|
i32.const 288
|
||||||
@ -1166,7 +1166,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1248,7 +1249,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1594,7 +1596,7 @@
|
|||||||
local.set $3
|
local.set $3
|
||||||
global.get $~lib/rt/pure/CUR
|
global.get $~lib/rt/pure/CUR
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $3
|
local.get $3
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -1654,14 +1656,14 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $3
|
local.set $3
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $2
|
local.get $2
|
||||||
global.set $~lib/rt/pure/CUR
|
global.set $~lib/rt/pure/CUR
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -1674,12 +1676,12 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
block $break|2
|
block $break|2
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -1699,7 +1701,7 @@
|
|||||||
i32.const 4
|
i32.const 4
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -5,7 +5,7 @@
|
|||||||
(start $start)
|
(start $start)
|
||||||
(func $start:scoped (; 0 ;) (type $FUNCSIG$v)
|
(func $start:scoped (; 0 ;) (type $FUNCSIG$v)
|
||||||
(local $0 i32)
|
(local $0 i32)
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -14,12 +14,12 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -28,7 +28,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
block $break|0
|
block $break|0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -35,15 +35,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $break|1
|
block $break|1
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -55,17 +54,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block
|
|
||||||
i64.const 5
|
i64.const 5
|
||||||
local.set $2
|
local.set $2
|
||||||
f32.const 10
|
f32.const 10
|
||||||
local.set $3
|
local.set $3
|
||||||
end
|
|
||||||
i32.const 42
|
i32.const 42
|
||||||
call $scoped/fn
|
call $scoped/fn
|
||||||
)
|
)
|
||||||
|
@ -222,7 +222,8 @@
|
|||||||
else
|
else
|
||||||
i32.const 0
|
i32.const 0
|
||||||
end
|
end
|
||||||
if
|
i32.eqz
|
||||||
|
br_if $break|0
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.sub
|
i32.sub
|
||||||
@ -237,7 +238,7 @@
|
|||||||
local.set $7
|
local.set $7
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
end
|
unreachable
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
local.set $8
|
local.set $8
|
||||||
@ -272,7 +273,6 @@
|
|||||||
i32.const 0
|
i32.const 0
|
||||||
i32.eq
|
i32.eq
|
||||||
if
|
if
|
||||||
block (result i32)
|
|
||||||
i32.const 304
|
i32.const 304
|
||||||
local.tee $3
|
local.tee $3
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -286,7 +286,6 @@
|
|||||||
call $~lib/rt/stub/__release
|
call $~lib/rt/stub/__release
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
end
|
|
||||||
local.set $1
|
local.set $1
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
|
@ -674,7 +674,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -689,7 +689,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -710,14 +710,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 608
|
i32.const 608
|
||||||
@ -1182,7 +1182,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1264,7 +1265,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -625,7 +625,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -640,7 +640,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -661,14 +661,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 624
|
i32.const 624
|
||||||
@ -1183,7 +1183,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1265,7 +1266,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1873,10 +1875,8 @@
|
|||||||
i32.const -1
|
i32.const -1
|
||||||
i32.const 1073741808
|
i32.const 1073741808
|
||||||
call $~lib/arraybuffer/ArrayBuffer#slice
|
call $~lib/arraybuffer/ArrayBuffer#slice
|
||||||
local.set $0
|
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $0
|
|
||||||
local.tee $1
|
local.tee $1
|
||||||
call $~lib/arraybuffer/ArrayBuffer#get:byteLength
|
call $~lib/arraybuffer/ArrayBuffer#get:byteLength
|
||||||
i32.const 1
|
i32.const 1
|
||||||
@ -1893,10 +1893,8 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const 3
|
i32.const 3
|
||||||
call $~lib/arraybuffer/ArrayBuffer#slice
|
call $~lib/arraybuffer/ArrayBuffer#slice
|
||||||
local.set $0
|
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $0
|
|
||||||
local.tee $1
|
local.tee $1
|
||||||
call $~lib/arraybuffer/ArrayBuffer#get:byteLength
|
call $~lib/arraybuffer/ArrayBuffer#get:byteLength
|
||||||
i32.const 2
|
i32.const 2
|
||||||
@ -1913,10 +1911,8 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.const -1
|
i32.const -1
|
||||||
call $~lib/arraybuffer/ArrayBuffer#slice
|
call $~lib/arraybuffer/ArrayBuffer#slice
|
||||||
local.set $0
|
|
||||||
local.get $1
|
local.get $1
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $0
|
|
||||||
local.tee $1
|
local.tee $1
|
||||||
call $~lib/arraybuffer/ArrayBuffer#get:byteLength
|
call $~lib/arraybuffer/ArrayBuffer#get:byteLength
|
||||||
i32.const 6
|
i32.const 6
|
||||||
@ -2071,7 +2067,6 @@
|
|||||||
i32.const 2
|
i32.const 2
|
||||||
call $~lib/arraybuffer/ArrayBufferView#constructor
|
call $~lib/arraybuffer/ArrayBufferView#constructor
|
||||||
local.tee $0
|
local.tee $0
|
||||||
local.set $6
|
|
||||||
local.get $0
|
local.get $0
|
||||||
call $~lib/arraybuffer/ArrayBuffer.isView<~lib/typedarray/Uint8Array>
|
call $~lib/arraybuffer/ArrayBuffer.isView<~lib/typedarray/Uint8Array>
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -2128,7 +2123,6 @@
|
|||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $5
|
local.get $5
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $6
|
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
local.get $7
|
local.get $7
|
||||||
call $~lib/rt/pure/__release
|
call $~lib/rt/pure/__release
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -631,7 +631,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -646,7 +646,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -667,14 +667,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 560
|
i32.const 560
|
||||||
@ -1185,7 +1185,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1267,7 +1268,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -118,7 +118,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
)
|
)
|
||||||
(func $~lib/date/Date#constructor (; 5 ;) (type $FUNCSIG$iij) (param $0 i32) (param $1 i64) (result i32)
|
(func $~lib/date/Date#constructor (; 5 ;) (type $FUNCSIG$iij) (param $0 i32) (param $1 i64) (result i32)
|
||||||
block (result i32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.eqz
|
i32.eqz
|
||||||
if
|
if
|
||||||
@ -132,7 +131,6 @@
|
|||||||
i64.const 0
|
i64.const 0
|
||||||
i64.store
|
i64.store
|
||||||
local.get $0
|
local.get $0
|
||||||
end
|
|
||||||
local.get $1
|
local.get $1
|
||||||
i64.store
|
i64.store
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -155,7 +153,6 @@
|
|||||||
(local $4 i32)
|
(local $4 i32)
|
||||||
(local $5 i32)
|
(local $5 i32)
|
||||||
(local $6 i64)
|
(local $6 i64)
|
||||||
block $~lib/date/Date.UTC|inlined.0 (result i64)
|
|
||||||
i32.const 1970
|
i32.const 1970
|
||||||
local.set $2
|
local.set $2
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -180,7 +177,6 @@
|
|||||||
f64.convert_i64_s
|
f64.convert_i64_s
|
||||||
call $~lib/bindings/Date/UTC
|
call $~lib/bindings/Date/UTC
|
||||||
i64.trunc_f64_s
|
i64.trunc_f64_s
|
||||||
end
|
|
||||||
i64.const 0
|
i64.const 0
|
||||||
i64.eq
|
i64.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -192,7 +188,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $~lib/date/Date.UTC|inlined.1 (result i64)
|
|
||||||
i32.const 1970
|
i32.const 1970
|
||||||
local.set $5
|
local.set $5
|
||||||
i32.const 0
|
i32.const 0
|
||||||
@ -217,7 +212,6 @@
|
|||||||
f64.convert_i64_s
|
f64.convert_i64_s
|
||||||
call $~lib/bindings/Date/UTC
|
call $~lib/bindings/Date/UTC
|
||||||
i64.trunc_f64_s
|
i64.trunc_f64_s
|
||||||
end
|
|
||||||
i64.const 0
|
i64.const 0
|
||||||
i64.eq
|
i64.eq
|
||||||
i32.eqz
|
i32.eqz
|
||||||
@ -229,7 +223,6 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $~lib/date/Date.UTC|inlined.2 (result i64)
|
|
||||||
i32.const 2018
|
i32.const 2018
|
||||||
local.set $5
|
local.set $5
|
||||||
i32.const 10
|
i32.const 10
|
||||||
@ -254,7 +247,6 @@
|
|||||||
f64.convert_i64_s
|
f64.convert_i64_s
|
||||||
call $~lib/bindings/Date/UTC
|
call $~lib/bindings/Date/UTC
|
||||||
i64.trunc_f64_s
|
i64.trunc_f64_s
|
||||||
end
|
|
||||||
global.set $std/date/creationTime
|
global.set $std/date/creationTime
|
||||||
global.get $std/date/creationTime
|
global.get $std/date/creationTime
|
||||||
i64.const 1541847600001
|
i64.const 1541847600001
|
||||||
@ -268,10 +260,8 @@
|
|||||||
call $~lib/builtins/abort
|
call $~lib/builtins/abort
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
block $~lib/date/Date.now|inlined.0 (result i64)
|
|
||||||
call $~lib/bindings/Date/now
|
call $~lib/bindings/Date/now
|
||||||
i64.trunc_f64_s
|
i64.trunc_f64_s
|
||||||
end
|
|
||||||
global.get $std/date/creationTime
|
global.get $std/date/creationTime
|
||||||
i64.gt_s
|
i64.gt_s
|
||||||
i32.eqz
|
i32.eqz
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.shl
|
i32.shl
|
||||||
local.set $3
|
local.set $3
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.ge_u
|
i32.ge_u
|
||||||
@ -45,8 +45,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -40,7 +40,6 @@
|
|||||||
i32.ne
|
i32.ne
|
||||||
if
|
if
|
||||||
block $break|0
|
block $break|0
|
||||||
block
|
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $2
|
local.set $2
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -48,8 +47,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.shl
|
i32.shl
|
||||||
local.set $3
|
local.set $3
|
||||||
end
|
loop $loop|0
|
||||||
loop $repeat|0
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -68,8 +66,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $2
|
local.set $2
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
@ -2260,10 +2260,8 @@
|
|||||||
i64.lt_u
|
i64.lt_u
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
local.set $11
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $11
|
|
||||||
local.set $2
|
local.set $2
|
||||||
end
|
end
|
||||||
local.get $4
|
local.get $4
|
||||||
@ -6117,10 +6115,8 @@
|
|||||||
i32.lt_u
|
i32.lt_u
|
||||||
if
|
if
|
||||||
local.get $3
|
local.get $3
|
||||||
local.set $5
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.set $3
|
local.set $3
|
||||||
local.get $5
|
|
||||||
local.set $2
|
local.set $2
|
||||||
end
|
end
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -7959,7 +7955,6 @@
|
|||||||
local.get $9
|
local.get $9
|
||||||
select
|
select
|
||||||
end
|
end
|
||||||
local.set $2
|
|
||||||
global.get $~lib/math/rempio2f_y
|
global.get $~lib/math/rempio2f_y
|
||||||
local.tee $3
|
local.tee $3
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -7999,7 +7994,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
local.set $1
|
local.set $1
|
||||||
local.get $2
|
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.and
|
i32.and
|
||||||
if
|
if
|
||||||
|
@ -1324,7 +1324,6 @@
|
|||||||
br_if $case3|0
|
br_if $case3|0
|
||||||
br $case4|0
|
br $case4|0
|
||||||
end
|
end
|
||||||
block
|
|
||||||
f64.const 0.4636476090008061
|
f64.const 0.4636476090008061
|
||||||
local.get $8
|
local.get $8
|
||||||
f64.const 2.2698777452961687e-17
|
f64.const 2.2698777452961687e-17
|
||||||
@ -1334,11 +1333,7 @@
|
|||||||
f64.sub
|
f64.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
block
|
|
||||||
f64.const 0.7853981633974483
|
f64.const 0.7853981633974483
|
||||||
local.get $8
|
local.get $8
|
||||||
f64.const 3.061616997868383e-17
|
f64.const 3.061616997868383e-17
|
||||||
@ -1348,11 +1343,7 @@
|
|||||||
f64.sub
|
f64.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
block
|
|
||||||
f64.const 0.982793723247329
|
f64.const 0.982793723247329
|
||||||
local.get $8
|
local.get $8
|
||||||
f64.const 1.3903311031230998e-17
|
f64.const 1.3903311031230998e-17
|
||||||
@ -1362,11 +1353,7 @@
|
|||||||
f64.sub
|
f64.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
block
|
|
||||||
f64.const 1.5707963267948966
|
f64.const 1.5707963267948966
|
||||||
local.get $8
|
local.get $8
|
||||||
f64.const 6.123233995736766e-17
|
f64.const 6.123233995736766e-17
|
||||||
@ -1376,9 +1363,6 @@
|
|||||||
f64.sub
|
f64.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -1800,7 +1784,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
f64.const 0
|
|
||||||
)
|
)
|
||||||
(func $../../lib/libm/assembly/libm/atan2 (; 21 ;) (type $FUNCSIG$ddd) (param $0 f64) (param $1 f64) (result f64)
|
(func $../../lib/libm/assembly/libm/atan2 (; 21 ;) (type $FUNCSIG$ddd) (param $0 f64) (param $1 f64) (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -2636,7 +2619,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/expo2|inlined.0 (result f64)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.set $4
|
local.set $4
|
||||||
i32.const 1023
|
i32.const 1023
|
||||||
@ -2659,7 +2641,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
local.get $5
|
local.get $5
|
||||||
f64.mul
|
f64.mul
|
||||||
end
|
|
||||||
local.set $3
|
local.set $3
|
||||||
local.get $3
|
local.get $3
|
||||||
)
|
)
|
||||||
@ -3709,7 +3690,6 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $8
|
local.get $8
|
||||||
i32.const 1072693248
|
i32.const 1072693248
|
||||||
@ -4679,7 +4659,6 @@
|
|||||||
f64.const 2
|
f64.const 2
|
||||||
local.get $5
|
local.get $5
|
||||||
f64.mul
|
f64.mul
|
||||||
block $~lib/math/expo2|inlined.1 (result f64)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.set $6
|
local.set $6
|
||||||
i32.const 1023
|
i32.const 1023
|
||||||
@ -4702,7 +4681,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
local.get $7
|
local.get $7
|
||||||
f64.mul
|
f64.mul
|
||||||
end
|
|
||||||
f64.mul
|
f64.mul
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $4
|
local.get $4
|
||||||
@ -5799,7 +5777,6 @@
|
|||||||
br_if $case3|0
|
br_if $case3|0
|
||||||
br $case4|0
|
br $case4|0
|
||||||
end
|
end
|
||||||
block
|
|
||||||
f32.const 0.46364760398864746
|
f32.const 0.46364760398864746
|
||||||
local.get $8
|
local.get $8
|
||||||
f32.const 5.01215824399992e-09
|
f32.const 5.01215824399992e-09
|
||||||
@ -5809,11 +5786,7 @@
|
|||||||
f32.sub
|
f32.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
block
|
|
||||||
f32.const 0.7853981256484985
|
f32.const 0.7853981256484985
|
||||||
local.get $8
|
local.get $8
|
||||||
f32.const 3.774894707930798e-08
|
f32.const 3.774894707930798e-08
|
||||||
@ -5823,11 +5796,7 @@
|
|||||||
f32.sub
|
f32.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
block
|
|
||||||
f32.const 0.9827936887741089
|
f32.const 0.9827936887741089
|
||||||
local.get $8
|
local.get $8
|
||||||
f32.const 3.447321716976148e-08
|
f32.const 3.447321716976148e-08
|
||||||
@ -5837,11 +5806,7 @@
|
|||||||
f32.sub
|
f32.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
block
|
|
||||||
f32.const 1.570796251296997
|
f32.const 1.570796251296997
|
||||||
local.get $8
|
local.get $8
|
||||||
f32.const 7.549789415861596e-08
|
f32.const 7.549789415861596e-08
|
||||||
@ -5851,9 +5816,6 @@
|
|||||||
f32.sub
|
f32.sub
|
||||||
local.set $3
|
local.set $3
|
||||||
br $break|0
|
br $break|0
|
||||||
unreachable
|
|
||||||
end
|
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6234,7 +6196,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
f32.const 0
|
|
||||||
)
|
)
|
||||||
(func $../../lib/libm/assembly/libmf/atan2 (; 83 ;) (type $FUNCSIG$fff) (param $0 f32) (param $1 f32) (result f32)
|
(func $../../lib/libm/assembly/libmf/atan2 (; 83 ;) (type $FUNCSIG$fff) (param $0 f32) (param $1 f32) (result f32)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -6460,7 +6421,6 @@
|
|||||||
f32.const 1
|
f32.const 1
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/cos_kernf|inlined.0 (result f32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.promote_f32
|
f64.promote_f32
|
||||||
local.set $3
|
local.set $3
|
||||||
@ -6495,7 +6455,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -6506,7 +6465,6 @@
|
|||||||
i32.const 1075235811
|
i32.const 1075235811
|
||||||
i32.gt_u
|
i32.gt_u
|
||||||
if
|
if
|
||||||
block $~lib/math/cos_kernf|inlined.1 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -6551,7 +6509,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
f32.neg
|
f32.neg
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
@ -6640,7 +6597,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 1088565717
|
i32.const 1088565717
|
||||||
@ -6650,7 +6606,6 @@
|
|||||||
i32.const 1085271519
|
i32.const 1085271519
|
||||||
i32.gt_u
|
i32.gt_u
|
||||||
if
|
if
|
||||||
block $~lib/math/cos_kernf|inlined.2 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -6695,7 +6650,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
local.get $2
|
local.get $2
|
||||||
@ -6784,7 +6738,6 @@
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 2139095040
|
i32.const 2139095040
|
||||||
@ -6827,7 +6780,6 @@
|
|||||||
i32.trunc_f64_s
|
i32.trunc_f64_s
|
||||||
br $~lib/math/rempio2f|inlined.0
|
br $~lib/math/rempio2f|inlined.0
|
||||||
end
|
end
|
||||||
block $~lib/math/pio2_large_quot|inlined.0 (result i32)
|
|
||||||
local.get $10
|
local.get $10
|
||||||
local.set $12
|
local.set $12
|
||||||
local.get $9
|
local.get $9
|
||||||
@ -6944,7 +6896,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
global.set $~lib/math/rempio2f_y
|
global.set $~lib/math/rempio2f_y
|
||||||
local.get $23
|
local.get $23
|
||||||
end
|
|
||||||
local.set $23
|
local.set $23
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.get $23
|
local.get $23
|
||||||
@ -7632,7 +7583,6 @@
|
|||||||
f32.add
|
f32.add
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/expo2f|inlined.0 (result f32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.set $2
|
local.set $2
|
||||||
i32.const 127
|
i32.const 127
|
||||||
@ -7652,7 +7602,6 @@
|
|||||||
f32.mul
|
f32.mul
|
||||||
local.get $3
|
local.get $3
|
||||||
f32.mul
|
f32.mul
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $../../lib/libm/assembly/libmf/cosh (; 97 ;) (type $FUNCSIG$ff) (param $0 f32) (result f32)
|
(func $../../lib/libm/assembly/libmf/cosh (; 97 ;) (type $FUNCSIG$ff) (param $0 f32) (result f32)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -8440,7 +8389,6 @@
|
|||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $5
|
local.get $5
|
||||||
i32.const 1065353216
|
i32.const 1065353216
|
||||||
@ -9304,7 +9252,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/sin_kernf|inlined.5 (result f32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.promote_f32
|
f64.promote_f32
|
||||||
local.set $3
|
local.set $3
|
||||||
@ -9342,7 +9289,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -9355,7 +9301,6 @@
|
|||||||
if
|
if
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f32)
|
if (result f32)
|
||||||
block $~lib/math/cos_kernf|inlined.4 (result f32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.promote_f32
|
f64.promote_f32
|
||||||
f64.const 1.5707963267948966
|
f64.const 1.5707963267948966
|
||||||
@ -9392,7 +9337,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
f32.neg
|
f32.neg
|
||||||
else
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -9434,7 +9378,6 @@
|
|||||||
end
|
end
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/sin_kernf|inlined.6 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -9483,7 +9426,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -9533,7 +9475,6 @@
|
|||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
else
|
else
|
||||||
block $~lib/math/cos_kernf|inlined.7 (result f32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.promote_f32
|
f64.promote_f32
|
||||||
f64.const 4.71238898038469
|
f64.const 4.71238898038469
|
||||||
@ -9570,12 +9511,10 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
f32.neg
|
f32.neg
|
||||||
end
|
end
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/sin_kernf|inlined.7 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -9623,7 +9562,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
f64.add
|
f64.add
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -9667,7 +9605,6 @@
|
|||||||
i32.trunc_f64_s
|
i32.trunc_f64_s
|
||||||
br $~lib/math/rempio2f|inlined.1
|
br $~lib/math/rempio2f|inlined.1
|
||||||
end
|
end
|
||||||
block $~lib/math/pio2_large_quot|inlined.1 (result i32)
|
|
||||||
local.get $10
|
local.get $10
|
||||||
local.set $12
|
local.set $12
|
||||||
local.get $9
|
local.get $9
|
||||||
@ -9784,7 +9721,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
global.set $~lib/math/rempio2f_y
|
global.set $~lib/math/rempio2f_y
|
||||||
local.get $23
|
local.get $23
|
||||||
end
|
|
||||||
local.set $23
|
local.set $23
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.get $23
|
local.get $23
|
||||||
@ -9952,7 +9888,6 @@
|
|||||||
f32.const 2
|
f32.const 2
|
||||||
local.get $4
|
local.get $4
|
||||||
f32.mul
|
f32.mul
|
||||||
block $~lib/math/expo2f|inlined.1 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
local.set $5
|
local.set $5
|
||||||
i32.const 127
|
i32.const 127
|
||||||
@ -9972,7 +9907,6 @@
|
|||||||
f32.mul
|
f32.mul
|
||||||
local.get $6
|
local.get $6
|
||||||
f32.mul
|
f32.mul
|
||||||
end
|
|
||||||
f32.mul
|
f32.mul
|
||||||
local.set $3
|
local.set $3
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -10038,7 +9972,6 @@
|
|||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
block $~lib/math/tan_kernf|inlined.0 (result f32)
|
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.promote_f32
|
f64.promote_f32
|
||||||
local.set $4
|
local.set $4
|
||||||
@ -10100,7 +10033,6 @@
|
|||||||
local.get $6
|
local.get $6
|
||||||
end
|
end
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -10111,7 +10043,6 @@
|
|||||||
i32.const 1075235811
|
i32.const 1075235811
|
||||||
i32.le_u
|
i32.le_u
|
||||||
if
|
if
|
||||||
block $~lib/math/tan_kernf|inlined.1 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -10183,10 +10114,8 @@
|
|||||||
local.get $9
|
local.get $9
|
||||||
end
|
end
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
block $~lib/math/tan_kernf|inlined.2 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -10258,11 +10187,9 @@
|
|||||||
local.get $6
|
local.get $6
|
||||||
end
|
end
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 1088565717
|
i32.const 1088565717
|
||||||
@ -10272,7 +10199,6 @@
|
|||||||
i32.const 1085271519
|
i32.const 1085271519
|
||||||
i32.le_u
|
i32.le_u
|
||||||
if
|
if
|
||||||
block $~lib/math/tan_kernf|inlined.3 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -10344,10 +10270,8 @@
|
|||||||
local.get $9
|
local.get $9
|
||||||
end
|
end
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
block $~lib/math/tan_kernf|inlined.4 (result f32)
|
|
||||||
local.get $2
|
local.get $2
|
||||||
if (result f64)
|
if (result f64)
|
||||||
local.get $0
|
local.get $0
|
||||||
@ -10419,11 +10343,9 @@
|
|||||||
local.get $6
|
local.get $6
|
||||||
end
|
end
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
unreachable
|
|
||||||
end
|
end
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 2139095040
|
i32.const 2139095040
|
||||||
@ -10466,7 +10388,6 @@
|
|||||||
i32.trunc_f64_s
|
i32.trunc_f64_s
|
||||||
br $~lib/math/rempio2f|inlined.2
|
br $~lib/math/rempio2f|inlined.2
|
||||||
end
|
end
|
||||||
block $~lib/math/pio2_large_quot|inlined.2 (result i32)
|
|
||||||
local.get $12
|
local.get $12
|
||||||
local.set $14
|
local.set $14
|
||||||
local.get $11
|
local.get $11
|
||||||
@ -10583,7 +10504,6 @@
|
|||||||
f64.mul
|
f64.mul
|
||||||
global.set $~lib/math/rempio2f_y
|
global.set $~lib/math/rempio2f_y
|
||||||
local.get $25
|
local.get $25
|
||||||
end
|
|
||||||
local.set $25
|
local.set $25
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.get $25
|
local.get $25
|
||||||
@ -10595,7 +10515,6 @@
|
|||||||
local.set $26
|
local.set $26
|
||||||
global.get $~lib/math/rempio2f_y
|
global.get $~lib/math/rempio2f_y
|
||||||
local.set $27
|
local.set $27
|
||||||
block $~lib/math/tan_kernf|inlined.5 (result f32)
|
|
||||||
local.get $27
|
local.get $27
|
||||||
local.set $4
|
local.set $4
|
||||||
local.get $26
|
local.get $26
|
||||||
@ -10658,7 +10577,6 @@
|
|||||||
local.get $9
|
local.get $9
|
||||||
end
|
end
|
||||||
f32.demote_f64
|
f32.demote_f64
|
||||||
end
|
|
||||||
)
|
)
|
||||||
(func $../../lib/libm/assembly/libmf/tan (; 123 ;) (type $FUNCSIG$ff) (param $0 f32) (result f32)
|
(func $../../lib/libm/assembly/libmf/tan (; 123 ;) (type $FUNCSIG$ff) (param $0 f32) (result f32)
|
||||||
local.get $0
|
local.get $0
|
||||||
|
@ -635,7 +635,7 @@
|
|||||||
i32.store
|
i32.store
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
block $break|0
|
block $break|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 23
|
i32.const 23
|
||||||
@ -650,7 +650,7 @@
|
|||||||
i32.store offset=4
|
i32.store offset=4
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
block $break|1
|
block $break|1
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.const 16
|
i32.const 16
|
||||||
@ -671,14 +671,14 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $1
|
local.set $1
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
i32.const 512
|
i32.const 512
|
||||||
@ -1160,14 +1160,12 @@
|
|||||||
i32.and
|
i32.and
|
||||||
local.tee $1
|
local.tee $1
|
||||||
i32.sub
|
i32.sub
|
||||||
local.set $2
|
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
i32.add
|
i32.add
|
||||||
local.tee $0
|
local.tee $0
|
||||||
i32.const 0
|
i32.const 0
|
||||||
i32.store
|
i32.store
|
||||||
local.get $2
|
|
||||||
i32.const -4
|
i32.const -4
|
||||||
i32.and
|
i32.and
|
||||||
local.tee $1
|
local.tee $1
|
||||||
@ -1422,7 +1420,8 @@
|
|||||||
loop $continue|1
|
loop $continue|1
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $1
|
local.get $1
|
||||||
@ -1504,7 +1503,8 @@
|
|||||||
loop $continue|4
|
loop $continue|4
|
||||||
local.get $3
|
local.get $3
|
||||||
i32.const 8
|
i32.const 8
|
||||||
i32.ge_u
|
i32.lt_u
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
local.get $3
|
local.get $3
|
||||||
@ -1843,7 +1843,7 @@
|
|||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
i32.const -2
|
i32.const -2
|
||||||
@ -1851,6 +1851,8 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
)
|
)
|
||||||
@ -1907,7 +1909,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
@ -2179,7 +2182,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<i8,i32>#constructor
|
call $~lib/map/Map<i8,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -2240,7 +2243,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -2259,7 +2262,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -2340,7 +2343,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -2359,7 +2362,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -2413,7 +2416,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -2432,7 +2435,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -2488,7 +2491,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -2599,7 +2602,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
@ -2865,7 +2869,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<u8,i32>#constructor
|
call $~lib/map/Map<u8,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -2922,7 +2926,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -2941,7 +2945,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -3016,7 +3020,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -3035,7 +3039,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -3087,7 +3091,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -3106,7 +3110,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -3160,7 +3164,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -3267,7 +3271,7 @@
|
|||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
i32.const -2
|
i32.const -2
|
||||||
@ -3275,6 +3279,8 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
)
|
)
|
||||||
@ -3331,7 +3337,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
@ -3603,7 +3610,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<i16,i32>#constructor
|
call $~lib/map/Map<i16,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -3664,7 +3671,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -3683,7 +3690,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -3764,7 +3771,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -3783,7 +3790,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -3837,7 +3844,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -3856,7 +3863,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -3912,7 +3919,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -4023,7 +4030,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
@ -4289,7 +4297,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<u16,i32>#constructor
|
call $~lib/map/Map<u16,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -4346,7 +4354,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -4365,7 +4373,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -4440,7 +4448,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -4459,7 +4467,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -4511,7 +4519,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -4530,7 +4538,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -4584,7 +4592,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -4705,7 +4713,7 @@
|
|||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
i32.const -2
|
i32.const -2
|
||||||
@ -4713,6 +4721,8 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
)
|
)
|
||||||
@ -4765,7 +4775,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
@ -5025,7 +5036,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<i32,i32>#constructor
|
call $~lib/map/Map<i32,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -5078,7 +5089,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5097,7 +5108,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -5166,7 +5177,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5185,7 +5196,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -5235,7 +5246,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5254,7 +5265,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_s
|
i32.lt_s
|
||||||
@ -5306,7 +5317,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5371,7 +5382,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<u32,i32>#constructor
|
call $~lib/map/Map<u32,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -5424,7 +5435,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5443,7 +5454,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 100
|
i32.const 100
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -5512,7 +5523,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5531,7 +5542,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -5581,7 +5592,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5600,7 +5611,7 @@
|
|||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.const 50
|
i32.const 50
|
||||||
i32.lt_u
|
i32.lt_u
|
||||||
@ -5652,7 +5663,7 @@
|
|||||||
i32.const 1
|
i32.const 1
|
||||||
i32.add
|
i32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -5841,7 +5852,7 @@
|
|||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
i32.const -2
|
i32.const -2
|
||||||
@ -5849,6 +5860,8 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
)
|
)
|
||||||
@ -5901,7 +5914,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
@ -6162,7 +6176,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<i64,i32>#constructor
|
call $~lib/map/Map<i64,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 100
|
i64.const 100
|
||||||
i64.lt_s
|
i64.lt_s
|
||||||
@ -6217,7 +6231,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6236,7 +6250,7 @@
|
|||||||
end
|
end
|
||||||
i64.const 0
|
i64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 100
|
i64.const 100
|
||||||
i64.lt_s
|
i64.lt_s
|
||||||
@ -6308,7 +6322,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6327,7 +6341,7 @@
|
|||||||
end
|
end
|
||||||
i64.const 0
|
i64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 50
|
i64.const 50
|
||||||
i64.lt_s
|
i64.lt_s
|
||||||
@ -6378,7 +6392,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6397,7 +6411,7 @@
|
|||||||
end
|
end
|
||||||
i64.const 0
|
i64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 50
|
i64.const 50
|
||||||
i64.lt_s
|
i64.lt_s
|
||||||
@ -6450,7 +6464,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6515,7 +6529,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<u64,i32>#constructor
|
call $~lib/map/Map<u64,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 100
|
i64.const 100
|
||||||
i64.lt_u
|
i64.lt_u
|
||||||
@ -6570,7 +6584,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6589,7 +6603,7 @@
|
|||||||
end
|
end
|
||||||
i64.const 0
|
i64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 100
|
i64.const 100
|
||||||
i64.lt_u
|
i64.lt_u
|
||||||
@ -6661,7 +6675,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6680,7 +6694,7 @@
|
|||||||
end
|
end
|
||||||
i64.const 0
|
i64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 50
|
i64.const 50
|
||||||
i64.lt_u
|
i64.lt_u
|
||||||
@ -6731,7 +6745,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6750,7 +6764,7 @@
|
|||||||
end
|
end
|
||||||
i64.const 0
|
i64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
i64.const 50
|
i64.const 50
|
||||||
i64.lt_u
|
i64.lt_u
|
||||||
@ -6803,7 +6817,7 @@
|
|||||||
i64.const 1
|
i64.const 1
|
||||||
i64.add
|
i64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -6893,7 +6907,7 @@
|
|||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
i32.const -2
|
i32.const -2
|
||||||
@ -6901,6 +6915,8 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
)
|
)
|
||||||
@ -6954,7 +6970,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=8
|
i32.load offset=8
|
||||||
@ -7219,7 +7236,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<f32,i32>#constructor
|
call $~lib/map/Map<f32,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
f32.const 100
|
f32.const 100
|
||||||
f32.lt
|
f32.lt
|
||||||
@ -7274,7 +7291,7 @@
|
|||||||
f32.const 1
|
f32.const 1
|
||||||
f32.add
|
f32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -7293,7 +7310,7 @@
|
|||||||
end
|
end
|
||||||
f32.const 0
|
f32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
f32.const 100
|
f32.const 100
|
||||||
f32.lt
|
f32.lt
|
||||||
@ -7365,7 +7382,7 @@
|
|||||||
f32.const 1
|
f32.const 1
|
||||||
f32.add
|
f32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -7384,7 +7401,7 @@
|
|||||||
end
|
end
|
||||||
f32.const 0
|
f32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
f32.const 50
|
f32.const 50
|
||||||
f32.lt
|
f32.lt
|
||||||
@ -7435,7 +7452,7 @@
|
|||||||
f32.const 1
|
f32.const 1
|
||||||
f32.add
|
f32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -7454,7 +7471,7 @@
|
|||||||
end
|
end
|
||||||
f32.const 0
|
f32.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
f32.const 50
|
f32.const 50
|
||||||
f32.lt
|
f32.lt
|
||||||
@ -7507,7 +7524,7 @@
|
|||||||
f32.const 1
|
f32.const 1
|
||||||
f32.add
|
f32.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -7597,7 +7614,7 @@
|
|||||||
if
|
if
|
||||||
local.get $0
|
local.get $0
|
||||||
return
|
return
|
||||||
end
|
else
|
||||||
local.get $0
|
local.get $0
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
i32.const -2
|
i32.const -2
|
||||||
@ -7605,6 +7622,8 @@
|
|||||||
local.set $0
|
local.set $0
|
||||||
br $continue|0
|
br $continue|0
|
||||||
end
|
end
|
||||||
|
unreachable
|
||||||
|
end
|
||||||
end
|
end
|
||||||
i32.const 0
|
i32.const 0
|
||||||
)
|
)
|
||||||
@ -7658,7 +7677,8 @@
|
|||||||
loop $continue|0
|
loop $continue|0
|
||||||
local.get $4
|
local.get $4
|
||||||
local.get $7
|
local.get $7
|
||||||
i32.ne
|
i32.eq
|
||||||
|
i32.eqz
|
||||||
if
|
if
|
||||||
local.get $4
|
local.get $4
|
||||||
i32.load offset=12
|
i32.load offset=12
|
||||||
@ -7923,7 +7943,7 @@
|
|||||||
(local $1 i32)
|
(local $1 i32)
|
||||||
call $~lib/map/Map<f64,i32>#constructor
|
call $~lib/map/Map<f64,i32>#constructor
|
||||||
local.set $1
|
local.set $1
|
||||||
loop $repeat|0
|
loop $loop|0
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.const 100
|
f64.const 100
|
||||||
f64.lt
|
f64.lt
|
||||||
@ -7978,7 +7998,7 @@
|
|||||||
f64.const 1
|
f64.const 1
|
||||||
f64.add
|
f64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|0
|
br $loop|0
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -7997,7 +8017,7 @@
|
|||||||
end
|
end
|
||||||
f64.const 0
|
f64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|1
|
loop $loop|1
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.const 100
|
f64.const 100
|
||||||
f64.lt
|
f64.lt
|
||||||
@ -8069,7 +8089,7 @@
|
|||||||
f64.const 1
|
f64.const 1
|
||||||
f64.add
|
f64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|1
|
br $loop|1
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -8088,7 +8108,7 @@
|
|||||||
end
|
end
|
||||||
f64.const 0
|
f64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|2
|
loop $loop|2
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.const 50
|
f64.const 50
|
||||||
f64.lt
|
f64.lt
|
||||||
@ -8139,7 +8159,7 @@
|
|||||||
f64.const 1
|
f64.const 1
|
||||||
f64.add
|
f64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|2
|
br $loop|2
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
@ -8158,7 +8178,7 @@
|
|||||||
end
|
end
|
||||||
f64.const 0
|
f64.const 0
|
||||||
local.set $0
|
local.set $0
|
||||||
loop $repeat|3
|
loop $loop|3
|
||||||
local.get $0
|
local.get $0
|
||||||
f64.const 50
|
f64.const 50
|
||||||
f64.lt
|
f64.lt
|
||||||
@ -8211,7 +8231,7 @@
|
|||||||
f64.const 1
|
f64.const 1
|
||||||
f64.add
|
f64.add
|
||||||
local.set $0
|
local.set $0
|
||||||
br $repeat|3
|
br $loop|3
|
||||||
end
|
end
|
||||||
unreachable
|
unreachable
|
||||||
end
|
end
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user