- Notifications
You must be signed in to change notification settings - Fork 670
/
Copy pathclass-extends.debug.wat
110 lines (110 loc) · 2.57 KB
/
class-extends.debug.wat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
(module
(type$0 (func (parami32) (resulti32)))
(type$1 (func (parami32i32)))
(type$2 (func (parami32)))
(type$3 (func (parami32i32i32i32)))
(type$4 (func))
(import"env""abort" (func$~lib/builtins/abort (parami32i32i32i32)))
(global$~lib/memory/__data_endi32 (i32.const8))
(global$~lib/memory/__stack_pointer (muti32) (i32.const32776))
(global$~lib/memory/__heap_basei32 (i32.const32776))
(memory$00)
(table$011funcref)
(elem$0 (i32.const1))
(export"memory" (memory$0))
(export"test" (func$export:class-extends/test))
(func$class-extends/A#get:a (param$thisi32) (resulti32)
local.get$this
i32.load
)
(func$class-extends/B#get:b (param$thisi32) (resulti32)
local.get$this
i32.load16_soffset=4
)
(func$class-extends/A#set:a (param$thisi32) (param$ai32)
local.get$this
local.get$a
i32.store
)
(func$class-extends/B#set:b (param$thisi32) (param$bi32)
local.get$this
local.get$b
i32.store16offset=4
)
(func$~stack_check
global.get$~lib/memory/__stack_pointer
global.get$~lib/memory/__data_end
i32.lt_s
if
i32.const32800
i32.const32848
i32.const1
i32.const1
call$~lib/builtins/abort
unreachable
end
)
(func$class-extends/test (param$bi32)
(local$1i32)
global.get$~lib/memory/__stack_pointer
i32.const4
i32.sub
global.set$~lib/memory/__stack_pointer
call$~stack_check
global.get$~lib/memory/__stack_pointer
i32.const0
i32.store
local.get$b
local.set$1
global.get$~lib/memory/__stack_pointer
local.get$1
i32.store
local.get$1
call$class-extends/A#get:a
drop
local.get$b
local.set$1
global.get$~lib/memory/__stack_pointer
local.get$1
i32.store
local.get$1
call$class-extends/B#get:b
drop
local.get$b
local.set$1
global.get$~lib/memory/__stack_pointer
local.get$1
i32.store
local.get$1
i32.const2
call$class-extends/A#set:a
local.get$b
local.set$1
global.get$~lib/memory/__stack_pointer
local.get$1
i32.store
local.get$1
i32.const3
call$class-extends/B#set:b
global.get$~lib/memory/__stack_pointer
i32.const4
i32.add
global.set$~lib/memory/__stack_pointer
)
(func$export:class-extends/test (param$0i32)
global.get$~lib/memory/__stack_pointer
i32.const4
i32.sub
global.set$~lib/memory/__stack_pointer
call$~stack_check
global.get$~lib/memory/__stack_pointer
local.get$0
i32.store
local.get$0
call$class-extends/test
global.get$~lib/memory/__stack_pointer
i32.const4
i32.add
global.set$~lib/memory/__stack_pointer
)
)