2018-05-06 00:00:54 +02:00
|
|
|
(module
|
|
|
|
(type $i (func (result i32)))
|
|
|
|
(type $iiiiv (func (param i32 i32 i32 i32)))
|
|
|
|
(type $v (func))
|
2018-10-11 08:49:08 +02:00
|
|
|
(memory $0 1)
|
|
|
|
(data (i32.const 8) "\06\00\00\00a\00b\00i\00.\00t\00s")
|
|
|
|
(table 1 anyfunc)
|
|
|
|
(elem (i32.const 0) $null)
|
2018-05-21 18:48:29 +02:00
|
|
|
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
|
2018-05-06 00:00:54 +02:00
|
|
|
(global $abi/condition (mut i32) (i32.const 0))
|
|
|
|
(global $abi/y (mut i32) (i32.const 0))
|
2018-07-18 23:49:32 +02:00
|
|
|
(export "memory" (memory $0))
|
2018-10-11 08:49:08 +02:00
|
|
|
(export "table" (table $0))
|
2018-05-06 00:00:54 +02:00
|
|
|
(export "exported" (func $abi/exported))
|
|
|
|
(export "exportedExported" (func $abi/exportedExported))
|
|
|
|
(export "exportedInternal" (func $abi/exportedInternal))
|
|
|
|
(start $start)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $abi/exported (; 1 ;) (; has Stack IR ;) (type $i) (result i32)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const -128)
|
|
|
|
)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $abi/exportedExported (; 2 ;) (; has Stack IR ;) (type $i) (result i32)
|
2018-05-06 00:00:54 +02:00
|
|
|
(call $abi/exported)
|
|
|
|
)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $abi/internal (; 3 ;) (; has Stack IR ;) (type $i) (result i32)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 128)
|
|
|
|
)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $abi/exportedInternal (; 4 ;) (; has Stack IR ;) (type $i) (result i32)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.shr_s
|
|
|
|
(i32.shl
|
|
|
|
(call $abi/internal)
|
|
|
|
(i32.const 24)
|
|
|
|
)
|
|
|
|
(i32.const 24)
|
|
|
|
)
|
|
|
|
)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $start (; 5 ;) (; has Stack IR ;) (type $v)
|
2018-05-06 00:00:54 +02:00
|
|
|
(drop
|
|
|
|
(call $abi/internal)
|
|
|
|
)
|
|
|
|
(set_global $abi/condition
|
|
|
|
(i32.const 1)
|
|
|
|
)
|
|
|
|
(set_global $abi/y
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(get_global $abi/y)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 8)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 65)
|
|
|
|
(i32.const 2)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
)
|
2018-09-17 01:48:35 +02:00
|
|
|
(func $null (; 6 ;) (; has Stack IR ;) (type $v)
|
|
|
|
(nop)
|
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
)
|