This commit is contained in:
dcode
2019-03-09 02:37:05 +01:00
parent 0c537c3363
commit 661e239fcb
4 changed files with 258 additions and 282 deletions

View File

@ -16,10 +16,12 @@
(data (i32.const 88) "\08\00\00\00b\00a\00r\00r\00i\00e\00r\001")
(data (i32.const 112) "\08\00\00\00b\00a\00r\00r\00i\00e\00r\002")
(data (i32.const 136) "\08\00\00\00b\00a\00r\00r\00i\00e\00r\003")
(data (i32.const 160) "\18\00\00\00~\00l\00i\00b\00/\00i\00n\00t\00e\00r\00n\00a\00l\00/\00r\00u\00n\00t\00i\00m\00e\00.\00t\00s")
(data (i32.const 160) "\15\00\00\00~\00l\00i\00b\00/\00r\00u\00n\00t\00i\00m\00e\00/\00i\00n\00d\00e\00x\00.\00t\00s")
(table $0 1 funcref)
(elem (i32.const 0) $null)
(global $~lib/allocator/tlsf/ROOT (mut i32) (i32.const 0))
(global $std/runtime/register_ref (mut i32) (i32.const 0))
(global $std/runtime/register_parentRef (mut i32) (i32.const 0))
(global $std/runtime/barrier1 (mut i32) (i32.const 0))
(global $std/runtime/barrier2 (mut i32) (i32.const 0))
(global $std/runtime/barrier3 (mut i32) (i32.const 0))
@ -29,7 +31,7 @@
(global $std/runtime/header2 (mut i32) (i32.const 0))
(global $std/runtime/ref3 (mut i32) (i32.const 0))
(global $std/runtime/ref4 (mut i32) (i32.const 0))
(global $std/runtime/called (mut i32) (i32.const 0))
(global $std/runtime/header4 (mut i32) (i32.const 0))
(export "memory" (memory $0))
(export "table" (table $0))
(start $start)
@ -1019,14 +1021,14 @@
if
unreachable
end
i32.const 216
i32.const 208
local.set $3
i32.const 216
i32.const 208
global.set $~lib/allocator/tlsf/ROOT
i32.const 2912
i32.const 0
i32.store
i32.const 216
i32.const 208
i32.const 0
i32.store
i32.const 0
@ -1036,7 +1038,7 @@
i32.const 22
i32.lt_u
if
i32.const 216
i32.const 208
local.get $1
i32.const 0
call $~lib/allocator/tlsf/Root#setSLMap
@ -1047,7 +1049,7 @@
i32.const 32
i32.lt_u
if
i32.const 216
i32.const 208
local.get $1
local.get $2
i32.const 0
@ -1066,8 +1068,8 @@
br $repeat|0
end
end
i32.const 216
i32.const 3136
i32.const 208
i32.const 3128
current_memory
i32.const 16
i32.shl
@ -1387,7 +1389,7 @@
end
end
)
(func $~lib/internal/runtime/ALLOC (; 18 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(func $~lib/runtime/index/ALLOC (; 18 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(local $1 i32)
i32.const 1
i32.const 32
@ -2551,7 +2553,7 @@
end
end
)
(func $~lib/internal/runtime/REALLOC (; 22 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(func $~lib/runtime/index/REALLOC (; 22 ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(local $3 i32)
(local $4 i32)
@ -2559,7 +2561,7 @@
local.get $0
i32.const 16
i32.sub
local.tee $5
local.tee $3
i32.load offset=4
local.tee $2
local.get $1
@ -2581,39 +2583,45 @@
i32.clz
i32.sub
i32.shl
local.tee $3
local.tee $4
i32.lt_u
if
local.get $3
local.get $4
call $~lib/allocator/tlsf/__memory_allocate
local.tee $4
local.tee $5
i32.const -1520547049
i32.store
local.get $4
local.get $5
i32.const 0
i32.store offset=8
local.get $4
local.get $5
i32.const 0
i32.store offset=12
local.get $4
local.get $5
i32.const 16
i32.add
local.tee $3
local.tee $4
local.get $0
local.get $2
call $~lib/internal/memory/memmove
local.get $2
local.get $3
local.get $4
i32.add
local.get $1
local.get $2
i32.sub
call $~lib/internal/memory/memset
local.get $5
call $~lib/allocator/tlsf/__memory_free
local.get $4
local.set $5
local.get $3
i32.load
i32.const -1520547049
i32.eq
if
local.get $3
call $~lib/allocator/tlsf/__memory_free
end
local.get $5
local.set $3
local.get $4
local.set $0
else
local.get $0
@ -2625,19 +2633,19 @@
call $~lib/internal/memory/memset
end
end
local.get $5
local.get $3
local.get $1
i32.store offset=4
local.get $0
)
(func $~lib/internal/runtime/FREE (; 23 ;) (type $FUNCSIG$vi) (param $0 i32)
(func $~lib/runtime/index/ensureUnregistered (; 23 ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
local.get $0
i32.const 228
i32.const 224
i32.lt_u
if
i32.const 0
i32.const 160
i32.const 88
i32.const 89
i32.const 2
call $~lib/env/abort
unreachable
@ -2652,90 +2660,14 @@
if
i32.const 0
i32.const 160
i32.const 90
i32.const 91
i32.const 2
call $~lib/env/abort
unreachable
end
local.get $0
call $~lib/allocator/tlsf/__memory_free
)
(func $std/runtime/__REGISTER_IMPL (; 24 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
local.get $0
global.get $std/runtime/ref4
i32.ne
if
i32.const 0
i32.const 56
i32.const 53
i32.const 2
call $~lib/env/abort
unreachable
end
local.get $1
global.get $std/runtime/ref3
i32.ne
if
i32.const 0
i32.const 56
i32.const 54
i32.const 2
call $~lib/env/abort
unreachable
end
local.get $0
i32.const 16
i32.sub
i32.load
i32.const 43
i32.ne
if
i32.const 0
i32.const 56
i32.const 56
i32.const 2
call $~lib/env/abort
unreachable
end
i32.const 1
global.set $std/runtime/called
)
(func $~lib/internal/runtime/REGISTER<A> (; 25 ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $2 i32)
local.get $0
i32.const 228
i32.lt_u
if
i32.const 0
i32.const 160
i32.const 96
i32.const 2
call $~lib/env/abort
unreachable
end
local.get $0
i32.const 16
i32.sub
local.tee $2
i32.load
i32.const -1520547049
i32.ne
if
i32.const 0
i32.const 160
i32.const 98
i32.const 2
call $~lib/env/abort
unreachable
end
local.get $2
i32.const 43
i32.store
local.get $0
local.get $1
call $std/runtime/__REGISTER_IMPL
)
(func $start:std/runtime (; 26 ;) (type $FUNCSIG$v)
(func $start:std/runtime (; 24 ;) (type $FUNCSIG$v)
(local $0 i32)
(local $1 i32)
(local $2 i32)
@ -2775,7 +2707,7 @@
else
i32.const 0
i32.const 56
i32.const 23
i32.const 32
i32.const 2
call $~lib/env/abort
unreachable
@ -2873,7 +2805,7 @@
f64.const 0
call $~lib/env/trace
i32.const 1
call $~lib/internal/runtime/ALLOC
call $~lib/runtime/index/ALLOC
global.set $std/runtime/ref1
global.get $std/runtime/ref1
i32.const 16
@ -2886,7 +2818,7 @@
if
i32.const 0
i32.const 56
i32.const 38
i32.const 47
i32.const 0
call $~lib/env/abort
unreachable
@ -2898,7 +2830,7 @@
if
i32.const 0
i32.const 56
i32.const 39
i32.const 48
i32.const 0
call $~lib/env/abort
unreachable
@ -2907,12 +2839,12 @@
local.tee $0
local.get $0
global.get $std/runtime/barrier1
call $~lib/internal/runtime/REALLOC
call $~lib/runtime/index/REALLOC
i32.ne
if
i32.const 0
i32.const 56
i32.const 40
i32.const 49
i32.const 0
call $~lib/env/abort
unreachable
@ -2924,14 +2856,14 @@
if
i32.const 0
i32.const 56
i32.const 41
i32.const 50
i32.const 0
call $~lib/env/abort
unreachable
end
global.get $std/runtime/ref1
global.get $std/runtime/barrier2
call $~lib/internal/runtime/REALLOC
call $~lib/runtime/index/REALLOC
global.set $std/runtime/ref2
global.get $std/runtime/ref1
global.get $std/runtime/ref2
@ -2939,7 +2871,7 @@
if
i32.const 0
i32.const 56
i32.const 43
i32.const 52
i32.const 0
call $~lib/env/abort
unreachable
@ -2955,15 +2887,16 @@
if
i32.const 0
i32.const 56
i32.const 45
i32.const 54
i32.const 0
call $~lib/env/abort
unreachable
end
global.get $std/runtime/ref2
call $~lib/internal/runtime/FREE
call $~lib/runtime/index/ensureUnregistered
call $~lib/allocator/tlsf/__memory_free
global.get $std/runtime/barrier2
call $~lib/internal/runtime/ALLOC
call $~lib/runtime/index/ALLOC
global.set $std/runtime/ref3
global.get $std/runtime/ref1
global.get $std/runtime/ref3
@ -2971,32 +2904,80 @@
if
i32.const 0
i32.const 56
i32.const 48
i32.const 57
i32.const 0
call $~lib/env/abort
unreachable
end
global.get $std/runtime/barrier1
call $~lib/internal/runtime/ALLOC
call $~lib/runtime/index/ALLOC
global.set $std/runtime/ref4
global.get $std/runtime/ref4
global.get $std/runtime/ref3
call $~lib/internal/runtime/REGISTER<A>
global.get $std/runtime/called
i32.eqz
local.set $1
global.get $std/runtime/ref4
local.tee $0
call $~lib/runtime/index/ensureUnregistered
i32.const 43
i32.store
local.get $0
global.set $std/runtime/register_ref
local.get $1
global.set $std/runtime/register_parentRef
global.get $std/runtime/register_ref
global.get $std/runtime/ref4
i32.ne
if
i32.const 0
i32.const 56
i32.const 60
i32.const 61
i32.const 0
call $~lib/env/abort
unreachable
end
global.get $std/runtime/register_parentRef
global.get $std/runtime/ref3
i32.ne
if
i32.const 0
i32.const 56
i32.const 62
i32.const 0
call $~lib/env/abort
unreachable
end
global.get $std/runtime/register_ref
i32.const 16
i32.sub
global.set $std/runtime/header4
global.get $std/runtime/header4
i32.load
i32.const 43
i32.ne
if
i32.const 0
i32.const 56
i32.const 64
i32.const 0
call $~lib/env/abort
unreachable
end
global.get $std/runtime/barrier1
global.get $std/runtime/header4
i32.load offset=4
i32.ne
if
i32.const 0
i32.const 56
i32.const 65
i32.const 0
call $~lib/env/abort
unreachable
end
)
(func $start (; 27 ;) (type $FUNCSIG$v)
(func $start (; 25 ;) (type $FUNCSIG$v)
call $start:std/runtime
)
(func $null (; 28 ;) (type $FUNCSIG$v)
(func $null (; 26 ;) (type $FUNCSIG$v)
nop
)
)