mirror of
https://github.com/fluencelabs/assemblyscript
synced 2025-04-25 23:12:19 +00:00
2238 lines
40 KiB
Plaintext
2238 lines
40 KiB
Plaintext
(module
|
|
(type $FUNCSIG$ii (func (param i32) (result i32)))
|
|
(type $FUNCSIG$viiii (func (param i32 i32 i32 i32)))
|
|
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
|
|
(type $FUNCSIG$v (func))
|
|
(type $FUNCSIG$vii (func (param i32 i32)))
|
|
(type $FUNCSIG$viii (func (param i32 i32 i32)))
|
|
(type $FUNCSIG$vi (func (param i32)))
|
|
(type $FUNCSIG$i (func (result i32)))
|
|
(import "env" "abort" (func $~lib/builtins/abort (param i32 i32 i32 i32)))
|
|
(import "rtrace" "onalloc" (func $~lib/rt/rtrace/onalloc (param i32)))
|
|
(import "rtrace" "onincrement" (func $~lib/rt/rtrace/onincrement (param i32)))
|
|
(import "rtrace" "ondecrement" (func $~lib/rt/rtrace/ondecrement (param i32)))
|
|
(import "rtrace" "onfree" (func $~lib/rt/rtrace/onfree (param i32)))
|
|
(memory $0 1)
|
|
(data (i32.const 8) "\03\00\00\00\01\00\00\00\00\00\00\00\03\00\00\00\00\01\02")
|
|
(data (i32.const 32) "\10\00\00\00\01\00\00\00\03\00\00\00\10\00\00\00\18\00\00\00\18\00\00\00\03\00\00\00\03")
|
|
(data (i32.const 64) "(\00\00\00\01\00\00\00\01\00\00\00(\00\00\00s\00t\00d\00/\00a\00r\00r\00a\00y\00-\00l\00i\00t\00e\00r\00a\00l\00.\00t\00s")
|
|
(data (i32.const 120) "$\00\00\00\01\00\00\00\01\00\00\00$\00\00\00I\00n\00d\00e\00x\00 \00o\00u\00t\00 \00o\00f\00 \00r\00a\00n\00g\00e")
|
|
(data (i32.const 176) "\1a\00\00\00\01\00\00\00\01\00\00\00\1a\00\00\00~\00l\00i\00b\00/\00a\00r\00r\00a\00y\00.\00t\00s")
|
|
(data (i32.const 224) "\0c\00\00\00\01\00\00\00\00\00\00\00\0c\00\00\00\00\00\00\00\01\00\00\00\02")
|
|
(data (i32.const 256) "\10\00\00\00\01\00\00\00\04\00\00\00\10\00\00\00\f0\00\00\00\f0\00\00\00\0c\00\00\00\03")
|
|
(data (i32.const 292) "\01")
|
|
(data (i32.const 304) "\10\00\00\00\01\00\00\00\04\00\00\00\10\00\00\000\01\00\000\01")
|
|
(data (i32.const 336) "\1e\00\00\00\01\00\00\00\01\00\00\00\1e\00\00\00~\00l\00i\00b\00/\00r\00t\00/\00t\00l\00s\00f\00.\00t\00s")
|
|
(data (i32.const 384) "(\00\00\00\01\00\00\00\01\00\00\00(\00\00\00a\00l\00l\00o\00c\00a\00t\00i\00o\00n\00 \00t\00o\00o\00 \00l\00a\00r\00g\00e")
|
|
(data (i32.const 440) "\1e\00\00\00\01\00\00\00\01\00\00\00\1e\00\00\00~\00l\00i\00b\00/\00r\00t\00/\00p\00u\00r\00e\00.\00t\00s")
|
|
(data (i32.const 488) "\14\00\00\00\01\00\00\00\01\00\00\00\14\00\00\00~\00l\00i\00b\00/\00r\00t\00.\00t\00s")
|
|
(data (i32.const 528) "\t\00\00\00\10\00\00\00\00\00\00\00\10\00\00\00\00\00\00\00\10\00\00\00\00\00\00\003\04\00\00\02\00\00\00\93\04\00\00\02\00\00\00\10\00\00\00\00\00\00\00\93 \00\00\02\00\00\00\10\00\00\00\00\00\00\00\93 \00\00\02")
|
|
(global $std/array-literal/emptyArrayI32 i32 (i32.const 320))
|
|
(global $std/array-literal/i (mut i32) (i32.const 0))
|
|
(global $~lib/rt/tlsf/ROOT (mut i32) (i32.const 0))
|
|
(global $std/array-literal/dynamicArrayI8 (mut i32) (i32.const 0))
|
|
(global $std/array-literal/dynamicArrayI32 (mut i32) (i32.const 0))
|
|
(global $std/array-literal/dynamicArrayRef (mut i32) (i32.const 0))
|
|
(global $std/array-literal/dynamicArrayRefWithCtor (mut i32) (i32.const 0))
|
|
(global $~lib/rt/pure/CUR (mut i32) (i32.const 0))
|
|
(global $~lib/rt/pure/END (mut i32) (i32.const 0))
|
|
(global $~lib/rt/pure/ROOTS (mut i32) (i32.const 0))
|
|
(export "memory" (memory $0))
|
|
(start $start)
|
|
(func $~lib/array/Array<i8>#__get (; 5 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
|
local.get $1
|
|
local.get $0
|
|
i32.load offset=8
|
|
i32.ge_u
|
|
if
|
|
i32.const 136
|
|
i32.const 192
|
|
i32.const 109
|
|
i32.const 61
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.get $1
|
|
i32.add
|
|
i32.load8_s
|
|
)
|
|
(func $~lib/array/Array<i32>#__get (; 6 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
|
local.get $1
|
|
local.get $0
|
|
i32.load offset=8
|
|
i32.const 2
|
|
i32.shr_u
|
|
i32.ge_u
|
|
if
|
|
i32.const 136
|
|
i32.const 192
|
|
i32.const 109
|
|
i32.const 61
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.get $1
|
|
i32.const 2
|
|
i32.shl
|
|
i32.add
|
|
i32.load
|
|
)
|
|
(func $~lib/rt/tlsf/removeBlock (; 7 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
(local $2 i32)
|
|
(local $3 i32)
|
|
(local $4 i32)
|
|
(local $5 i32)
|
|
local.get $1
|
|
i32.load
|
|
local.tee $3
|
|
i32.const 1
|
|
i32.and
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 276
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $3
|
|
i32.const -4
|
|
i32.and
|
|
local.tee $2
|
|
i32.const 16
|
|
i32.ge_u
|
|
if (result i32)
|
|
local.get $2
|
|
i32.const 1073741808
|
|
i32.lt_u
|
|
else
|
|
i32.const 0
|
|
end
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 278
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $2
|
|
i32.const 256
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $2
|
|
i32.const 4
|
|
i32.shr_u
|
|
local.set $2
|
|
i32.const 0
|
|
else
|
|
local.get $2
|
|
i32.const 31
|
|
local.get $2
|
|
i32.clz
|
|
i32.sub
|
|
local.tee $3
|
|
i32.const 4
|
|
i32.sub
|
|
i32.shr_u
|
|
i32.const 16
|
|
i32.xor
|
|
local.set $2
|
|
local.get $3
|
|
i32.const 7
|
|
i32.sub
|
|
end
|
|
local.tee $3
|
|
i32.const 23
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $2
|
|
i32.const 16
|
|
i32.lt_u
|
|
else
|
|
i32.const 0
|
|
end
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 291
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $1
|
|
i32.load offset=20
|
|
local.set $4
|
|
local.get $1
|
|
i32.load offset=16
|
|
local.tee $5
|
|
if
|
|
local.get $5
|
|
local.get $4
|
|
i32.store offset=20
|
|
end
|
|
local.get $4
|
|
if
|
|
local.get $4
|
|
local.get $5
|
|
i32.store offset=16
|
|
end
|
|
local.get $3
|
|
i32.const 4
|
|
i32.shl
|
|
local.get $2
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=96
|
|
local.get $1
|
|
i32.eq
|
|
if
|
|
local.get $3
|
|
i32.const 4
|
|
i32.shl
|
|
local.get $2
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
local.get $4
|
|
i32.store offset=96
|
|
local.get $4
|
|
i32.eqz
|
|
if
|
|
local.get $3
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
local.get $3
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=4
|
|
i32.const 1
|
|
local.get $2
|
|
i32.shl
|
|
i32.const -1
|
|
i32.xor
|
|
i32.and
|
|
local.tee $1
|
|
i32.store offset=4
|
|
local.get $1
|
|
i32.eqz
|
|
if
|
|
local.get $0
|
|
local.get $0
|
|
i32.load
|
|
i32.const 1
|
|
local.get $3
|
|
i32.shl
|
|
i32.const -1
|
|
i32.xor
|
|
i32.and
|
|
i32.store
|
|
end
|
|
end
|
|
end
|
|
)
|
|
(func $~lib/rt/tlsf/insertBlock (; 8 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
(local $2 i32)
|
|
(local $3 i32)
|
|
(local $4 i32)
|
|
(local $5 i32)
|
|
(local $6 i32)
|
|
(local $7 i32)
|
|
local.get $1
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 204
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $1
|
|
i32.load
|
|
local.tee $3
|
|
i32.const 1
|
|
i32.and
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 206
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $1
|
|
i32.const 16
|
|
i32.add
|
|
local.get $1
|
|
i32.load
|
|
i32.const -4
|
|
i32.and
|
|
i32.add
|
|
local.tee $4
|
|
i32.load
|
|
local.tee $5
|
|
i32.const 1
|
|
i32.and
|
|
if
|
|
local.get $3
|
|
i32.const -4
|
|
i32.and
|
|
i32.const 16
|
|
i32.add
|
|
local.get $5
|
|
i32.const -4
|
|
i32.and
|
|
i32.add
|
|
local.tee $2
|
|
i32.const 1073741808
|
|
i32.lt_u
|
|
if
|
|
local.get $0
|
|
local.get $4
|
|
call $~lib/rt/tlsf/removeBlock
|
|
local.get $1
|
|
local.get $3
|
|
i32.const 3
|
|
i32.and
|
|
local.get $2
|
|
i32.or
|
|
local.tee $3
|
|
i32.store
|
|
local.get $1
|
|
i32.const 16
|
|
i32.add
|
|
local.get $1
|
|
i32.load
|
|
i32.const -4
|
|
i32.and
|
|
i32.add
|
|
local.tee $4
|
|
i32.load
|
|
local.set $5
|
|
end
|
|
end
|
|
local.get $3
|
|
i32.const 2
|
|
i32.and
|
|
if
|
|
local.get $1
|
|
i32.const 4
|
|
i32.sub
|
|
i32.load
|
|
local.tee $2
|
|
i32.load
|
|
local.tee $6
|
|
i32.const 1
|
|
i32.and
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 227
|
|
i32.const 15
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $6
|
|
i32.const -4
|
|
i32.and
|
|
i32.const 16
|
|
i32.add
|
|
local.get $3
|
|
i32.const -4
|
|
i32.and
|
|
i32.add
|
|
local.tee $7
|
|
i32.const 1073741808
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $0
|
|
local.get $2
|
|
call $~lib/rt/tlsf/removeBlock
|
|
local.get $2
|
|
local.get $6
|
|
i32.const 3
|
|
i32.and
|
|
local.get $7
|
|
i32.or
|
|
local.tee $3
|
|
i32.store
|
|
local.get $2
|
|
else
|
|
local.get $1
|
|
end
|
|
local.set $1
|
|
end
|
|
local.get $4
|
|
local.get $5
|
|
i32.const 2
|
|
i32.or
|
|
i32.store
|
|
local.get $3
|
|
i32.const -4
|
|
i32.and
|
|
local.tee $2
|
|
i32.const 16
|
|
i32.ge_u
|
|
if (result i32)
|
|
local.get $2
|
|
i32.const 1073741808
|
|
i32.lt_u
|
|
else
|
|
i32.const 0
|
|
end
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 242
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $4
|
|
local.get $1
|
|
i32.const 16
|
|
i32.add
|
|
local.get $2
|
|
i32.add
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 243
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $4
|
|
i32.const 4
|
|
i32.sub
|
|
local.get $1
|
|
i32.store
|
|
local.get $2
|
|
i32.const 256
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $2
|
|
i32.const 4
|
|
i32.shr_u
|
|
local.set $4
|
|
i32.const 0
|
|
else
|
|
local.get $2
|
|
i32.const 31
|
|
local.get $2
|
|
i32.clz
|
|
i32.sub
|
|
local.tee $2
|
|
i32.const 4
|
|
i32.sub
|
|
i32.shr_u
|
|
i32.const 16
|
|
i32.xor
|
|
local.set $4
|
|
local.get $2
|
|
i32.const 7
|
|
i32.sub
|
|
end
|
|
local.tee $3
|
|
i32.const 23
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $4
|
|
i32.const 16
|
|
i32.lt_u
|
|
else
|
|
i32.const 0
|
|
end
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 259
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $3
|
|
i32.const 4
|
|
i32.shl
|
|
local.get $4
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=96
|
|
local.set $2
|
|
local.get $1
|
|
i32.const 0
|
|
i32.store offset=16
|
|
local.get $1
|
|
local.get $2
|
|
i32.store offset=20
|
|
local.get $2
|
|
if
|
|
local.get $2
|
|
local.get $1
|
|
i32.store offset=16
|
|
end
|
|
local.get $3
|
|
i32.const 4
|
|
i32.shl
|
|
local.get $4
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
local.get $1
|
|
i32.store offset=96
|
|
local.get $0
|
|
local.get $0
|
|
i32.load
|
|
i32.const 1
|
|
local.get $3
|
|
i32.shl
|
|
i32.or
|
|
i32.store
|
|
local.get $3
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
local.get $3
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=4
|
|
i32.const 1
|
|
local.get $4
|
|
i32.shl
|
|
i32.or
|
|
i32.store offset=4
|
|
)
|
|
(func $~lib/rt/tlsf/addMemory (; 9 ;) (type $FUNCSIG$viii) (param $0 i32) (param $1 i32) (param $2 i32)
|
|
(local $3 i32)
|
|
(local $4 i32)
|
|
local.get $2
|
|
i32.const 15
|
|
i32.and
|
|
i32.eqz
|
|
i32.const 0
|
|
local.get $1
|
|
i32.const 15
|
|
i32.and
|
|
i32.eqz
|
|
i32.const 0
|
|
local.get $1
|
|
local.get $2
|
|
i32.le_u
|
|
select
|
|
select
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 385
|
|
i32.const 4
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.load offset=1568
|
|
local.tee $3
|
|
if
|
|
local.get $1
|
|
local.get $3
|
|
i32.const 16
|
|
i32.add
|
|
i32.lt_u
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 395
|
|
i32.const 15
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $1
|
|
i32.const 16
|
|
i32.sub
|
|
local.get $3
|
|
i32.eq
|
|
if
|
|
local.get $3
|
|
i32.load
|
|
local.set $4
|
|
local.get $1
|
|
i32.const 16
|
|
i32.sub
|
|
local.set $1
|
|
end
|
|
else
|
|
local.get $1
|
|
local.get $0
|
|
i32.const 1572
|
|
i32.add
|
|
i32.lt_u
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 407
|
|
i32.const 4
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
end
|
|
local.get $2
|
|
local.get $1
|
|
i32.sub
|
|
local.tee $2
|
|
i32.const 48
|
|
i32.lt_u
|
|
if
|
|
return
|
|
end
|
|
local.get $1
|
|
local.get $4
|
|
i32.const 2
|
|
i32.and
|
|
local.get $2
|
|
i32.const 32
|
|
i32.sub
|
|
i32.const 1
|
|
i32.or
|
|
i32.or
|
|
i32.store
|
|
local.get $1
|
|
i32.const 0
|
|
i32.store offset=16
|
|
local.get $1
|
|
i32.const 0
|
|
i32.store offset=20
|
|
local.get $1
|
|
local.get $2
|
|
i32.add
|
|
i32.const 16
|
|
i32.sub
|
|
local.tee $2
|
|
i32.const 2
|
|
i32.store
|
|
local.get $0
|
|
local.get $2
|
|
i32.store offset=1568
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/rt/tlsf/insertBlock
|
|
)
|
|
(func $~lib/rt/tlsf/initializeRoot (; 10 ;) (type $FUNCSIG$v)
|
|
(local $0 i32)
|
|
(local $1 i32)
|
|
i32.const 1
|
|
memory.size
|
|
local.tee $0
|
|
i32.gt_s
|
|
if (result i32)
|
|
i32.const 1
|
|
local.get $0
|
|
i32.sub
|
|
memory.grow
|
|
i32.const 0
|
|
i32.lt_s
|
|
else
|
|
i32.const 0
|
|
end
|
|
if
|
|
unreachable
|
|
end
|
|
i32.const 608
|
|
i32.const 0
|
|
i32.store
|
|
i32.const 2176
|
|
i32.const 0
|
|
i32.store
|
|
i32.const 0
|
|
local.set $0
|
|
loop $repeat|0
|
|
block $break|0
|
|
local.get $0
|
|
i32.const 23
|
|
i32.ge_u
|
|
br_if $break|0
|
|
local.get $0
|
|
i32.const 2
|
|
i32.shl
|
|
i32.const 608
|
|
i32.add
|
|
i32.const 0
|
|
i32.store offset=4
|
|
i32.const 0
|
|
local.set $1
|
|
loop $repeat|1
|
|
block $break|1
|
|
local.get $1
|
|
i32.const 16
|
|
i32.ge_u
|
|
br_if $break|1
|
|
local.get $0
|
|
i32.const 4
|
|
i32.shl
|
|
local.get $1
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
i32.const 608
|
|
i32.add
|
|
i32.const 0
|
|
i32.store offset=96
|
|
local.get $1
|
|
i32.const 1
|
|
i32.add
|
|
local.set $1
|
|
br $repeat|1
|
|
end
|
|
end
|
|
local.get $0
|
|
i32.const 1
|
|
i32.add
|
|
local.set $0
|
|
br $repeat|0
|
|
end
|
|
end
|
|
i32.const 608
|
|
i32.const 2192
|
|
memory.size
|
|
i32.const 16
|
|
i32.shl
|
|
call $~lib/rt/tlsf/addMemory
|
|
i32.const 608
|
|
global.set $~lib/rt/tlsf/ROOT
|
|
)
|
|
(func $~lib/rt/tlsf/prepareSize (; 11 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
|
local.get $0
|
|
i32.const 1073741808
|
|
i32.ge_u
|
|
if
|
|
i32.const 400
|
|
i32.const 352
|
|
i32.const 447
|
|
i32.const 29
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.const 15
|
|
i32.add
|
|
i32.const -16
|
|
i32.and
|
|
local.tee $0
|
|
i32.const 16
|
|
local.get $0
|
|
i32.const 16
|
|
i32.gt_u
|
|
select
|
|
)
|
|
(func $~lib/rt/tlsf/searchBlock (; 12 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
|
(local $2 i32)
|
|
local.get $1
|
|
i32.const 256
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $1
|
|
i32.const 4
|
|
i32.shr_u
|
|
local.set $1
|
|
i32.const 0
|
|
else
|
|
local.get $1
|
|
i32.const 536870904
|
|
i32.lt_u
|
|
if
|
|
i32.const 1
|
|
i32.const 27
|
|
local.get $1
|
|
i32.clz
|
|
i32.sub
|
|
i32.shl
|
|
local.get $1
|
|
i32.add
|
|
i32.const 1
|
|
i32.sub
|
|
local.set $1
|
|
end
|
|
local.get $1
|
|
i32.const 31
|
|
local.get $1
|
|
i32.clz
|
|
i32.sub
|
|
local.tee $2
|
|
i32.const 4
|
|
i32.sub
|
|
i32.shr_u
|
|
i32.const 16
|
|
i32.xor
|
|
local.set $1
|
|
local.get $2
|
|
i32.const 7
|
|
i32.sub
|
|
end
|
|
local.tee $2
|
|
i32.const 23
|
|
i32.lt_u
|
|
if (result i32)
|
|
local.get $1
|
|
i32.const 16
|
|
i32.lt_u
|
|
else
|
|
i32.const 0
|
|
end
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 337
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $2
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=4
|
|
i32.const -1
|
|
local.get $1
|
|
i32.shl
|
|
i32.and
|
|
local.tee $1
|
|
if (result i32)
|
|
local.get $1
|
|
i32.ctz
|
|
local.get $2
|
|
i32.const 4
|
|
i32.shl
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=96
|
|
else
|
|
local.get $0
|
|
i32.load
|
|
i32.const -1
|
|
local.get $2
|
|
i32.const 1
|
|
i32.add
|
|
i32.shl
|
|
i32.and
|
|
local.tee $1
|
|
if (result i32)
|
|
local.get $1
|
|
i32.ctz
|
|
local.tee $1
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=4
|
|
local.tee $2
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 350
|
|
i32.const 17
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $2
|
|
i32.ctz
|
|
local.get $1
|
|
i32.const 4
|
|
i32.shl
|
|
i32.add
|
|
i32.const 2
|
|
i32.shl
|
|
local.get $0
|
|
i32.add
|
|
i32.load offset=96
|
|
else
|
|
i32.const 0
|
|
end
|
|
end
|
|
)
|
|
(func $~lib/rt/tlsf/growMemory (; 13 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
(local $2 i32)
|
|
memory.size
|
|
local.tee $2
|
|
local.get $1
|
|
i32.const 65535
|
|
i32.add
|
|
i32.const -65536
|
|
i32.and
|
|
i32.const 16
|
|
i32.shr_u
|
|
local.tee $1
|
|
local.get $2
|
|
local.get $1
|
|
i32.gt_s
|
|
select
|
|
memory.grow
|
|
i32.const 0
|
|
i32.lt_s
|
|
if
|
|
local.get $1
|
|
memory.grow
|
|
i32.const 0
|
|
i32.lt_s
|
|
if
|
|
unreachable
|
|
end
|
|
end
|
|
local.get $0
|
|
local.get $2
|
|
i32.const 16
|
|
i32.shl
|
|
memory.size
|
|
i32.const 16
|
|
i32.shl
|
|
call $~lib/rt/tlsf/addMemory
|
|
)
|
|
(func $~lib/rt/tlsf/prepareBlock (; 14 ;) (type $FUNCSIG$viii) (param $0 i32) (param $1 i32) (param $2 i32)
|
|
(local $3 i32)
|
|
(local $4 i32)
|
|
local.get $1
|
|
i32.load
|
|
local.set $3
|
|
local.get $2
|
|
i32.const 15
|
|
i32.and
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 364
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $3
|
|
i32.const -4
|
|
i32.and
|
|
local.get $2
|
|
i32.sub
|
|
local.tee $4
|
|
i32.const 32
|
|
i32.ge_u
|
|
if
|
|
local.get $1
|
|
local.get $3
|
|
i32.const 2
|
|
i32.and
|
|
local.get $2
|
|
i32.or
|
|
i32.store
|
|
local.get $1
|
|
i32.const 16
|
|
i32.add
|
|
local.get $2
|
|
i32.add
|
|
local.tee $1
|
|
local.get $4
|
|
i32.const 16
|
|
i32.sub
|
|
i32.const 1
|
|
i32.or
|
|
i32.store
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/rt/tlsf/insertBlock
|
|
else
|
|
local.get $1
|
|
local.get $3
|
|
i32.const -2
|
|
i32.and
|
|
i32.store
|
|
local.get $1
|
|
i32.const 16
|
|
i32.add
|
|
local.get $1
|
|
i32.load
|
|
i32.const -4
|
|
i32.and
|
|
i32.add
|
|
local.get $1
|
|
i32.const 16
|
|
i32.add
|
|
local.get $1
|
|
i32.load
|
|
i32.const -4
|
|
i32.and
|
|
i32.add
|
|
i32.load
|
|
i32.const -3
|
|
i32.and
|
|
i32.store
|
|
end
|
|
)
|
|
(func $~lib/rt/tlsf/allocateBlock (; 15 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
|
(local $2 i32)
|
|
(local $3 i32)
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/rt/tlsf/prepareSize
|
|
local.tee $3
|
|
call $~lib/rt/tlsf/searchBlock
|
|
local.tee $2
|
|
i32.eqz
|
|
if
|
|
local.get $0
|
|
local.get $3
|
|
call $~lib/rt/tlsf/growMemory
|
|
local.get $0
|
|
local.get $3
|
|
call $~lib/rt/tlsf/searchBlock
|
|
local.tee $2
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 477
|
|
i32.const 15
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
end
|
|
local.get $2
|
|
i32.load
|
|
i32.const -4
|
|
i32.and
|
|
local.get $3
|
|
i32.lt_u
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 479
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $2
|
|
i32.const 0
|
|
i32.store offset=4
|
|
local.get $2
|
|
local.get $1
|
|
i32.store offset=12
|
|
local.get $0
|
|
local.get $2
|
|
call $~lib/rt/tlsf/removeBlock
|
|
local.get $0
|
|
local.get $2
|
|
local.get $3
|
|
call $~lib/rt/tlsf/prepareBlock
|
|
local.get $2
|
|
call $~lib/rt/rtrace/onalloc
|
|
local.get $2
|
|
)
|
|
(func $~lib/rt/tlsf/__alloc (; 16 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
|
(local $2 i32)
|
|
global.get $~lib/rt/tlsf/ROOT
|
|
local.tee $2
|
|
if (result i32)
|
|
local.get $2
|
|
else
|
|
call $~lib/rt/tlsf/initializeRoot
|
|
global.get $~lib/rt/tlsf/ROOT
|
|
end
|
|
local.get $0
|
|
call $~lib/rt/tlsf/allocateBlock
|
|
local.tee $0
|
|
local.get $1
|
|
i32.store offset=8
|
|
local.get $0
|
|
i32.const 16
|
|
i32.add
|
|
)
|
|
(func $~lib/rt/pure/increment (; 17 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
(local $1 i32)
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $1
|
|
i32.const -268435456
|
|
i32.and
|
|
local.get $1
|
|
i32.const 1
|
|
i32.add
|
|
i32.const -268435456
|
|
i32.and
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 104
|
|
i32.const 2
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
local.get $1
|
|
i32.const 1
|
|
i32.add
|
|
i32.store offset=4
|
|
local.get $0
|
|
call $~lib/rt/rtrace/onincrement
|
|
local.get $0
|
|
i32.load
|
|
i32.const 1
|
|
i32.and
|
|
if
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 107
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
)
|
|
(func $~lib/rt/pure/__retain (; 18 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
|
local.get $0
|
|
i32.const 604
|
|
i32.gt_u
|
|
if
|
|
local.get $0
|
|
i32.const 16
|
|
i32.sub
|
|
call $~lib/rt/pure/increment
|
|
end
|
|
local.get $0
|
|
)
|
|
(func $~lib/memory/memory.copy (; 19 ;) (type $FUNCSIG$viii) (param $0 i32) (param $1 i32) (param $2 i32)
|
|
(local $3 i32)
|
|
(local $4 i32)
|
|
block $~lib/util/memory/memmove|inlined.0
|
|
local.get $2
|
|
local.set $3
|
|
local.get $0
|
|
local.get $1
|
|
i32.eq
|
|
br_if $~lib/util/memory/memmove|inlined.0
|
|
local.get $0
|
|
local.get $1
|
|
i32.lt_u
|
|
if
|
|
local.get $1
|
|
i32.const 7
|
|
i32.and
|
|
local.get $0
|
|
i32.const 7
|
|
i32.and
|
|
i32.eq
|
|
if
|
|
loop $continue|0
|
|
local.get $0
|
|
i32.const 7
|
|
i32.and
|
|
if
|
|
local.get $3
|
|
i32.eqz
|
|
br_if $~lib/util/memory/memmove|inlined.0
|
|
local.get $3
|
|
i32.const 1
|
|
i32.sub
|
|
local.set $3
|
|
local.get $0
|
|
local.tee $2
|
|
i32.const 1
|
|
i32.add
|
|
local.set $0
|
|
local.get $1
|
|
local.tee $4
|
|
i32.const 1
|
|
i32.add
|
|
local.set $1
|
|
local.get $2
|
|
local.get $4
|
|
i32.load8_u
|
|
i32.store8
|
|
br $continue|0
|
|
end
|
|
end
|
|
loop $continue|1
|
|
local.get $3
|
|
i32.const 8
|
|
i32.ge_u
|
|
if
|
|
local.get $0
|
|
local.get $1
|
|
i64.load
|
|
i64.store
|
|
local.get $3
|
|
i32.const 8
|
|
i32.sub
|
|
local.set $3
|
|
local.get $0
|
|
i32.const 8
|
|
i32.add
|
|
local.set $0
|
|
local.get $1
|
|
i32.const 8
|
|
i32.add
|
|
local.set $1
|
|
br $continue|1
|
|
end
|
|
end
|
|
end
|
|
loop $continue|2
|
|
local.get $3
|
|
if
|
|
local.get $0
|
|
local.tee $2
|
|
i32.const 1
|
|
i32.add
|
|
local.set $0
|
|
local.get $1
|
|
local.tee $4
|
|
i32.const 1
|
|
i32.add
|
|
local.set $1
|
|
local.get $2
|
|
local.get $4
|
|
i32.load8_u
|
|
i32.store8
|
|
local.get $3
|
|
i32.const 1
|
|
i32.sub
|
|
local.set $3
|
|
br $continue|2
|
|
end
|
|
end
|
|
else
|
|
local.get $1
|
|
i32.const 7
|
|
i32.and
|
|
local.get $0
|
|
i32.const 7
|
|
i32.and
|
|
i32.eq
|
|
if
|
|
loop $continue|3
|
|
local.get $0
|
|
local.get $3
|
|
i32.add
|
|
i32.const 7
|
|
i32.and
|
|
if
|
|
local.get $3
|
|
i32.eqz
|
|
br_if $~lib/util/memory/memmove|inlined.0
|
|
local.get $0
|
|
local.get $3
|
|
i32.const 1
|
|
i32.sub
|
|
local.tee $3
|
|
i32.add
|
|
local.get $1
|
|
local.get $3
|
|
i32.add
|
|
i32.load8_u
|
|
i32.store8
|
|
br $continue|3
|
|
end
|
|
end
|
|
loop $continue|4
|
|
local.get $3
|
|
i32.const 8
|
|
i32.ge_u
|
|
if
|
|
local.get $0
|
|
local.get $3
|
|
i32.const 8
|
|
i32.sub
|
|
local.tee $3
|
|
i32.add
|
|
local.get $1
|
|
local.get $3
|
|
i32.add
|
|
i64.load
|
|
i64.store
|
|
br $continue|4
|
|
end
|
|
end
|
|
end
|
|
loop $continue|5
|
|
local.get $3
|
|
if
|
|
local.get $0
|
|
local.get $3
|
|
i32.const 1
|
|
i32.sub
|
|
local.tee $3
|
|
i32.add
|
|
local.get $1
|
|
local.get $3
|
|
i32.add
|
|
i32.load8_u
|
|
i32.store8
|
|
br $continue|5
|
|
end
|
|
end
|
|
end
|
|
end
|
|
)
|
|
(func $~lib/rt/__allocArray (; 20 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
|
|
(local $2 i32)
|
|
i32.const 16
|
|
local.get $1
|
|
call $~lib/rt/tlsf/__alloc
|
|
local.tee $1
|
|
i32.const 3
|
|
local.get $0
|
|
i32.shl
|
|
local.tee $0
|
|
i32.const 0
|
|
call $~lib/rt/tlsf/__alloc
|
|
local.tee $2
|
|
call $~lib/rt/pure/__retain
|
|
i32.store
|
|
local.get $1
|
|
local.get $2
|
|
i32.store offset=4
|
|
local.get $1
|
|
local.get $0
|
|
i32.store offset=8
|
|
local.get $1
|
|
i32.const 3
|
|
i32.store offset=12
|
|
local.get $1
|
|
)
|
|
(func $std/array-literal/Ref#constructor (; 21 ;) (type $FUNCSIG$i) (result i32)
|
|
i32.const 0
|
|
i32.const 5
|
|
call $~lib/rt/tlsf/__alloc
|
|
call $~lib/rt/pure/__retain
|
|
)
|
|
(func $std/array-literal/RefWithCtor#constructor (; 22 ;) (type $FUNCSIG$i) (result i32)
|
|
i32.const 0
|
|
i32.const 7
|
|
call $~lib/rt/tlsf/__alloc
|
|
call $~lib/rt/pure/__retain
|
|
)
|
|
(func $~lib/rt/tlsf/freeBlock (; 23 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
(local $2 i32)
|
|
local.get $1
|
|
i32.load
|
|
local.tee $2
|
|
i32.const 1
|
|
i32.and
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 531
|
|
i32.const 2
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $1
|
|
local.get $2
|
|
i32.const 1
|
|
i32.or
|
|
i32.store
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/rt/tlsf/insertBlock
|
|
local.get $1
|
|
call $~lib/rt/rtrace/onfree
|
|
)
|
|
(func $~lib/rt/__typeinfo (; 24 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
|
|
local.get $0
|
|
i32.const 528
|
|
i32.load
|
|
i32.gt_u
|
|
if
|
|
i32.const 136
|
|
i32.const 504
|
|
i32.const 22
|
|
i32.const 27
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.const 3
|
|
i32.shl
|
|
i32.const 532
|
|
i32.add
|
|
i32.load
|
|
)
|
|
(func $~lib/rt/tlsf/__free (; 25 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
global.get $~lib/rt/tlsf/ROOT
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 561
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.const 15
|
|
i32.and
|
|
i32.eqz
|
|
i32.const 0
|
|
local.get $0
|
|
select
|
|
i32.eqz
|
|
if
|
|
i32.const 0
|
|
i32.const 352
|
|
i32.const 562
|
|
i32.const 2
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $~lib/rt/tlsf/ROOT
|
|
local.get $0
|
|
i32.const 16
|
|
i32.sub
|
|
call $~lib/rt/tlsf/freeBlock
|
|
)
|
|
(func $~lib/rt/pure/growRoots (; 26 ;) (type $FUNCSIG$v)
|
|
(local $0 i32)
|
|
(local $1 i32)
|
|
(local $2 i32)
|
|
(local $3 i32)
|
|
global.get $~lib/rt/pure/CUR
|
|
global.get $~lib/rt/pure/ROOTS
|
|
local.tee $1
|
|
i32.sub
|
|
local.tee $2
|
|
i32.const 1
|
|
i32.shl
|
|
local.tee $0
|
|
i32.const 256
|
|
local.get $0
|
|
i32.const 256
|
|
i32.gt_u
|
|
select
|
|
local.tee $3
|
|
i32.const 0
|
|
call $~lib/rt/tlsf/__alloc
|
|
local.tee $0
|
|
i32.const 16
|
|
i32.sub
|
|
call $~lib/rt/rtrace/onfree
|
|
local.get $0
|
|
local.get $1
|
|
local.get $2
|
|
call $~lib/memory/memory.copy
|
|
local.get $1
|
|
if
|
|
local.get $1
|
|
i32.const 16
|
|
i32.sub
|
|
call $~lib/rt/rtrace/onalloc
|
|
local.get $1
|
|
call $~lib/rt/tlsf/__free
|
|
end
|
|
local.get $0
|
|
global.set $~lib/rt/pure/ROOTS
|
|
local.get $0
|
|
local.get $2
|
|
i32.add
|
|
global.set $~lib/rt/pure/CUR
|
|
local.get $0
|
|
local.get $3
|
|
i32.add
|
|
global.set $~lib/rt/pure/END
|
|
)
|
|
(func $~lib/rt/pure/appendRoot (; 27 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
(local $1 i32)
|
|
global.get $~lib/rt/pure/CUR
|
|
local.tee $1
|
|
global.get $~lib/rt/pure/END
|
|
i32.ge_u
|
|
if
|
|
call $~lib/rt/pure/growRoots
|
|
global.get $~lib/rt/pure/CUR
|
|
local.set $1
|
|
end
|
|
local.get $1
|
|
local.get $0
|
|
i32.store
|
|
local.get $1
|
|
i32.const 4
|
|
i32.add
|
|
global.set $~lib/rt/pure/CUR
|
|
)
|
|
(func $~lib/rt/pure/decrement (; 28 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
(local $1 i32)
|
|
(local $2 i32)
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $2
|
|
i32.const 268435455
|
|
i32.and
|
|
local.set $1
|
|
local.get $0
|
|
call $~lib/rt/rtrace/ondecrement
|
|
local.get $0
|
|
i32.load
|
|
i32.const 1
|
|
i32.and
|
|
if
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 115
|
|
i32.const 13
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $1
|
|
i32.const 1
|
|
i32.eq
|
|
if
|
|
local.get $0
|
|
i32.const 16
|
|
i32.add
|
|
i32.const 1
|
|
call $~lib/rt/__visit_members
|
|
local.get $2
|
|
i32.const -2147483648
|
|
i32.and
|
|
if
|
|
local.get $0
|
|
i32.const -2147483648
|
|
i32.store offset=4
|
|
else
|
|
global.get $~lib/rt/tlsf/ROOT
|
|
local.get $0
|
|
call $~lib/rt/tlsf/freeBlock
|
|
end
|
|
else
|
|
local.get $1
|
|
i32.const 0
|
|
i32.le_u
|
|
if
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 124
|
|
i32.const 15
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.load offset=8
|
|
call $~lib/rt/__typeinfo
|
|
i32.const 16
|
|
i32.and
|
|
if
|
|
local.get $0
|
|
local.get $1
|
|
i32.const 1
|
|
i32.sub
|
|
local.get $2
|
|
i32.const -268435456
|
|
i32.and
|
|
i32.or
|
|
i32.store offset=4
|
|
else
|
|
local.get $0
|
|
local.get $1
|
|
i32.const 1
|
|
i32.sub
|
|
i32.const -1342177280
|
|
i32.or
|
|
i32.store offset=4
|
|
local.get $2
|
|
i32.const -2147483648
|
|
i32.and
|
|
i32.eqz
|
|
if
|
|
local.get $0
|
|
call $~lib/rt/pure/appendRoot
|
|
end
|
|
end
|
|
end
|
|
)
|
|
(func $~lib/rt/pure/__release (; 29 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
local.get $0
|
|
i32.const 604
|
|
i32.gt_u
|
|
if
|
|
local.get $0
|
|
i32.const 16
|
|
i32.sub
|
|
call $~lib/rt/pure/decrement
|
|
end
|
|
)
|
|
(func $start:std/array-literal (; 30 ;) (type $FUNCSIG$v)
|
|
(local $0 i32)
|
|
(local $1 i32)
|
|
(local $2 i32)
|
|
(local $3 i32)
|
|
(local $4 i32)
|
|
(local $5 i32)
|
|
(local $6 i32)
|
|
i32.const 60
|
|
i32.load
|
|
i32.const 3
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 2
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 48
|
|
i32.const 0
|
|
call $~lib/array/Array<i8>#__get
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 3
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 48
|
|
i32.const 1
|
|
call $~lib/array/Array<i8>#__get
|
|
i32.const 1
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 4
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 48
|
|
i32.const 2
|
|
call $~lib/array/Array<i8>#__get
|
|
i32.const 2
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 5
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 284
|
|
i32.load
|
|
i32.const 3
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 8
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 272
|
|
i32.const 0
|
|
call $~lib/array/Array<i32>#__get
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 9
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 272
|
|
i32.const 1
|
|
call $~lib/array/Array<i32>#__get
|
|
i32.const 1
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 10
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 272
|
|
i32.const 2
|
|
call $~lib/array/Array<i32>#__get
|
|
i32.const 2
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 11
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/emptyArrayI32
|
|
i32.load offset=12
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 14
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 0
|
|
i32.const 3
|
|
call $~lib/rt/__allocArray
|
|
local.tee $1
|
|
i32.load offset=4
|
|
local.tee $0
|
|
global.get $std/array-literal/i
|
|
i32.store8
|
|
global.get $std/array-literal/i
|
|
i32.const 1
|
|
i32.add
|
|
global.set $std/array-literal/i
|
|
local.get $0
|
|
global.get $std/array-literal/i
|
|
i32.store8 offset=1
|
|
global.get $std/array-literal/i
|
|
i32.const 1
|
|
i32.add
|
|
global.set $std/array-literal/i
|
|
local.get $0
|
|
global.get $std/array-literal/i
|
|
i32.store8 offset=2
|
|
local.get $1
|
|
call $~lib/rt/pure/__retain
|
|
global.set $std/array-literal/dynamicArrayI8
|
|
global.get $std/array-literal/dynamicArrayI8
|
|
i32.load offset=12
|
|
i32.const 3
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 19
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/dynamicArrayI8
|
|
i32.const 0
|
|
call $~lib/array/Array<i8>#__get
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 20
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/dynamicArrayI8
|
|
i32.const 1
|
|
call $~lib/array/Array<i8>#__get
|
|
i32.const 1
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 21
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/dynamicArrayI8
|
|
i32.const 2
|
|
call $~lib/array/Array<i8>#__get
|
|
i32.const 2
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 22
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 0
|
|
global.set $std/array-literal/i
|
|
i32.const 2
|
|
i32.const 4
|
|
call $~lib/rt/__allocArray
|
|
local.tee $1
|
|
i32.load offset=4
|
|
local.tee $0
|
|
global.get $std/array-literal/i
|
|
i32.store
|
|
global.get $std/array-literal/i
|
|
i32.const 1
|
|
i32.add
|
|
global.set $std/array-literal/i
|
|
local.get $0
|
|
global.get $std/array-literal/i
|
|
i32.store offset=4
|
|
global.get $std/array-literal/i
|
|
i32.const 1
|
|
i32.add
|
|
global.set $std/array-literal/i
|
|
local.get $0
|
|
global.get $std/array-literal/i
|
|
i32.store offset=8
|
|
local.get $1
|
|
call $~lib/rt/pure/__retain
|
|
global.set $std/array-literal/dynamicArrayI32
|
|
global.get $std/array-literal/dynamicArrayI32
|
|
i32.load offset=12
|
|
i32.const 3
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 27
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/dynamicArrayI32
|
|
i32.const 0
|
|
call $~lib/array/Array<i32>#__get
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 28
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/dynamicArrayI32
|
|
i32.const 1
|
|
call $~lib/array/Array<i32>#__get
|
|
i32.const 1
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 29
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/dynamicArrayI32
|
|
i32.const 2
|
|
call $~lib/array/Array<i32>#__get
|
|
i32.const 2
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 30
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 2
|
|
i32.const 6
|
|
call $~lib/rt/__allocArray
|
|
local.tee $1
|
|
i32.load offset=4
|
|
local.tee $0
|
|
call $std/array-literal/Ref#constructor
|
|
local.tee $2
|
|
call $~lib/rt/pure/__retain
|
|
i32.store
|
|
local.get $0
|
|
call $std/array-literal/Ref#constructor
|
|
local.tee $3
|
|
call $~lib/rt/pure/__retain
|
|
i32.store offset=4
|
|
local.get $0
|
|
call $std/array-literal/Ref#constructor
|
|
local.tee $4
|
|
call $~lib/rt/pure/__retain
|
|
i32.store offset=8
|
|
local.get $1
|
|
call $~lib/rt/pure/__retain
|
|
global.set $std/array-literal/dynamicArrayRef
|
|
global.get $std/array-literal/dynamicArrayRef
|
|
i32.load offset=12
|
|
i32.const 3
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 34
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
i32.const 2
|
|
i32.const 8
|
|
call $~lib/rt/__allocArray
|
|
local.tee $1
|
|
i32.load offset=4
|
|
local.tee $0
|
|
call $std/array-literal/RefWithCtor#constructor
|
|
local.tee $5
|
|
call $~lib/rt/pure/__retain
|
|
i32.store
|
|
local.get $0
|
|
call $std/array-literal/RefWithCtor#constructor
|
|
local.tee $6
|
|
call $~lib/rt/pure/__retain
|
|
i32.store offset=4
|
|
local.get $0
|
|
call $std/array-literal/RefWithCtor#constructor
|
|
local.tee $0
|
|
call $~lib/rt/pure/__retain
|
|
i32.store offset=8
|
|
local.get $1
|
|
call $~lib/rt/pure/__retain
|
|
global.set $std/array-literal/dynamicArrayRefWithCtor
|
|
global.get $std/array-literal/dynamicArrayRefWithCtor
|
|
i32.load offset=12
|
|
i32.const 3
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 80
|
|
i32.const 38
|
|
i32.const 0
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
global.get $std/array-literal/emptyArrayI32
|
|
call $~lib/rt/pure/__release
|
|
global.get $std/array-literal/dynamicArrayI8
|
|
call $~lib/rt/pure/__release
|
|
global.get $std/array-literal/dynamicArrayI32
|
|
call $~lib/rt/pure/__release
|
|
global.get $std/array-literal/dynamicArrayRef
|
|
call $~lib/rt/pure/__release
|
|
global.get $std/array-literal/dynamicArrayRefWithCtor
|
|
call $~lib/rt/pure/__release
|
|
local.get $2
|
|
call $~lib/rt/pure/__release
|
|
local.get $3
|
|
call $~lib/rt/pure/__release
|
|
local.get $4
|
|
call $~lib/rt/pure/__release
|
|
local.get $5
|
|
call $~lib/rt/pure/__release
|
|
local.get $6
|
|
call $~lib/rt/pure/__release
|
|
local.get $0
|
|
call $~lib/rt/pure/__release
|
|
)
|
|
(func $start (; 31 ;) (type $FUNCSIG$v)
|
|
call $start:std/array-literal
|
|
)
|
|
(func $~lib/rt/pure/markGray (; 32 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
(local $1 i32)
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $1
|
|
i32.const 1879048192
|
|
i32.and
|
|
i32.const 268435456
|
|
i32.ne
|
|
if
|
|
local.get $0
|
|
local.get $1
|
|
i32.const -1879048193
|
|
i32.and
|
|
i32.const 268435456
|
|
i32.or
|
|
i32.store offset=4
|
|
local.get $0
|
|
i32.const 16
|
|
i32.add
|
|
i32.const 2
|
|
call $~lib/rt/__visit_members
|
|
end
|
|
)
|
|
(func $~lib/rt/pure/scanBlack (; 33 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
local.get $0
|
|
local.get $0
|
|
i32.load offset=4
|
|
i32.const -1879048193
|
|
i32.and
|
|
i32.store offset=4
|
|
local.get $0
|
|
i32.const 16
|
|
i32.add
|
|
i32.const 4
|
|
call $~lib/rt/__visit_members
|
|
)
|
|
(func $~lib/rt/pure/scan (; 34 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
(local $1 i32)
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $1
|
|
i32.const 1879048192
|
|
i32.and
|
|
i32.const 268435456
|
|
i32.eq
|
|
if
|
|
local.get $1
|
|
i32.const 268435455
|
|
i32.and
|
|
i32.const 0
|
|
i32.gt_u
|
|
if
|
|
local.get $0
|
|
call $~lib/rt/pure/scanBlack
|
|
else
|
|
local.get $0
|
|
local.get $1
|
|
i32.const -1879048193
|
|
i32.and
|
|
i32.const 536870912
|
|
i32.or
|
|
i32.store offset=4
|
|
local.get $0
|
|
i32.const 16
|
|
i32.add
|
|
i32.const 3
|
|
call $~lib/rt/__visit_members
|
|
end
|
|
end
|
|
)
|
|
(func $~lib/rt/pure/collectWhite (; 35 ;) (type $FUNCSIG$vi) (param $0 i32)
|
|
(local $1 i32)
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $1
|
|
i32.const 1879048192
|
|
i32.and
|
|
i32.const 536870912
|
|
i32.eq
|
|
if (result i32)
|
|
local.get $1
|
|
i32.const -2147483648
|
|
i32.and
|
|
i32.eqz
|
|
else
|
|
i32.const 0
|
|
end
|
|
if
|
|
local.get $0
|
|
local.get $1
|
|
i32.const -1879048193
|
|
i32.and
|
|
i32.store offset=4
|
|
local.get $0
|
|
i32.const 16
|
|
i32.add
|
|
i32.const 5
|
|
call $~lib/rt/__visit_members
|
|
global.get $~lib/rt/tlsf/ROOT
|
|
local.get $0
|
|
call $~lib/rt/tlsf/freeBlock
|
|
end
|
|
)
|
|
(func $~lib/rt/pure/__visit (; 36 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
local.get $0
|
|
i32.const 604
|
|
i32.lt_u
|
|
if
|
|
return
|
|
end
|
|
local.get $0
|
|
i32.const 16
|
|
i32.sub
|
|
local.set $0
|
|
block $break|0
|
|
block $case5|0
|
|
block $case4|0
|
|
block $case3|0
|
|
block $case2|0
|
|
block $case1|0
|
|
local.get $1
|
|
i32.const 1
|
|
i32.ne
|
|
if
|
|
local.get $1
|
|
i32.const 2
|
|
i32.eq
|
|
br_if $case1|0
|
|
block $tablify|0
|
|
local.get $1
|
|
i32.const 3
|
|
i32.sub
|
|
br_table $case2|0 $case3|0 $case4|0 $tablify|0
|
|
end
|
|
br $case5|0
|
|
end
|
|
local.get $0
|
|
call $~lib/rt/pure/decrement
|
|
br $break|0
|
|
end
|
|
local.get $0
|
|
i32.load offset=4
|
|
i32.const 268435455
|
|
i32.and
|
|
i32.const 0
|
|
i32.le_u
|
|
if
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 75
|
|
i32.const 17
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
local.get $0
|
|
i32.load offset=4
|
|
i32.const 1
|
|
i32.sub
|
|
i32.store offset=4
|
|
local.get $0
|
|
call $~lib/rt/pure/markGray
|
|
br $break|0
|
|
end
|
|
local.get $0
|
|
call $~lib/rt/pure/scan
|
|
br $break|0
|
|
end
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $1
|
|
i32.const -268435456
|
|
i32.and
|
|
local.get $1
|
|
i32.const 1
|
|
i32.add
|
|
i32.const -268435456
|
|
i32.and
|
|
i32.ne
|
|
if
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 86
|
|
i32.const 6
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
local.get $1
|
|
i32.const 1
|
|
i32.add
|
|
i32.store offset=4
|
|
local.get $1
|
|
i32.const 1879048192
|
|
i32.and
|
|
if
|
|
local.get $0
|
|
call $~lib/rt/pure/scanBlack
|
|
end
|
|
br $break|0
|
|
end
|
|
local.get $0
|
|
call $~lib/rt/pure/collectWhite
|
|
br $break|0
|
|
end
|
|
i32.const 0
|
|
i32.const 456
|
|
i32.const 97
|
|
i32.const 24
|
|
call $~lib/builtins/abort
|
|
unreachable
|
|
end
|
|
)
|
|
(func $~lib/array/Array<std/array-literal/Ref>#__visit_impl (; 37 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
(local $2 i32)
|
|
(local $3 i32)
|
|
local.get $0
|
|
i32.load offset=4
|
|
local.tee $2
|
|
local.get $0
|
|
i32.load offset=12
|
|
i32.const 2
|
|
i32.shl
|
|
i32.add
|
|
local.set $0
|
|
loop $continue|0
|
|
local.get $2
|
|
local.get $0
|
|
i32.lt_u
|
|
if
|
|
local.get $2
|
|
i32.load
|
|
local.tee $3
|
|
if
|
|
local.get $3
|
|
local.get $1
|
|
call $~lib/rt/pure/__visit
|
|
end
|
|
local.get $2
|
|
i32.const 4
|
|
i32.add
|
|
local.set $2
|
|
br $continue|0
|
|
end
|
|
end
|
|
)
|
|
(func $~lib/rt/__visit_members (; 38 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
|
|
block $block$4$break
|
|
block $switch$1$default
|
|
block $switch$1$case$10
|
|
block $switch$1$case$8
|
|
block $switch$1$case$2
|
|
local.get $0
|
|
i32.const 8
|
|
i32.sub
|
|
i32.load
|
|
br_table $switch$1$case$2 $switch$1$case$2 $block$4$break $block$4$break $block$4$break $switch$1$case$2 $switch$1$case$8 $switch$1$case$2 $switch$1$case$10 $switch$1$default
|
|
end
|
|
return
|
|
end
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/array/Array<std/array-literal/Ref>#__visit_impl
|
|
br $block$4$break
|
|
end
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/array/Array<std/array-literal/Ref>#__visit_impl
|
|
br $block$4$break
|
|
end
|
|
unreachable
|
|
end
|
|
local.get $0
|
|
i32.load
|
|
local.tee $0
|
|
if
|
|
local.get $0
|
|
local.get $1
|
|
call $~lib/rt/pure/__visit
|
|
end
|
|
)
|
|
(func $null (; 39 ;) (type $FUNCSIG$v)
|
|
nop
|
|
)
|
|
)
|