2018-02-19 13:35:28 +02:00
|
|
|
(module
|
|
|
|
(type $ii (func (param i32) (result i32)))
|
2018-03-12 14:06:39 +01:00
|
|
|
(type $iiiiv (func (param i32 i32 i32 i32)))
|
2018-02-19 13:35:28 +02:00
|
|
|
(type $v (func))
|
2018-09-13 23:10:49 +02:00
|
|
|
(type $FUNCSIG$i (func (result i32)))
|
|
|
|
(type $FUNCSIG$j (func (result i64)))
|
2018-05-21 18:48:29 +02:00
|
|
|
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
|
2018-02-19 13:35:28 +02:00
|
|
|
(memory $0 1)
|
2018-05-14 16:55:55 +02:00
|
|
|
(data (i32.const 8) "\11\00\00\00~\00l\00i\00b\00/\00p\00o\00l\00y\00f\00i\00l\00l\00s\00.\00t\00s")
|
|
|
|
(data (i32.const 48) "\10\00\00\00s\00t\00d\00/\00p\00o\00l\00y\00f\00i\00l\00l\00s\00.\00t\00s")
|
2018-02-19 13:35:28 +02:00
|
|
|
(export "memory" (memory $0))
|
|
|
|
(start $start)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $~lib/polyfills/bswap16<u16> (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
|
2018-02-19 13:35:28 +02:00
|
|
|
(local $1 i32)
|
|
|
|
(if
|
|
|
|
(i32.eqz
|
2018-06-09 14:05:33 +02:00
|
|
|
(tee_local $1
|
|
|
|
(i32.const 1)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
2018-06-09 14:05:33 +02:00
|
|
|
(set_local $1
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.eqz
|
|
|
|
(get_local $1)
|
|
|
|
)
|
2018-02-19 13:35:28 +02:00
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 8)
|
2018-05-06 05:46:35 +02:00
|
|
|
(i32.const 27)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 2)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
2018-06-09 14:05:33 +02:00
|
|
|
(tee_local $1
|
|
|
|
(i32.const 1)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
(return
|
|
|
|
(i32.or
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.or
|
|
|
|
(i32.and
|
|
|
|
(i32.shl
|
|
|
|
(get_local $0)
|
|
|
|
(i32.const 8)
|
|
|
|
)
|
|
|
|
(i32.const 65280)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-02-25 23:21:32 +01:00
|
|
|
(i32.shr_u
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.and
|
|
|
|
(get_local $0)
|
|
|
|
(i32.const 65535)
|
|
|
|
)
|
2018-02-25 23:21:32 +01:00
|
|
|
(i32.const 8)
|
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
)
|
|
|
|
(i32.and
|
|
|
|
(get_local $0)
|
|
|
|
(i32.const -65536)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(get_local $0)
|
|
|
|
)
|
2018-09-13 23:10:49 +02:00
|
|
|
(func $~lib/polyfills/bswap<u16> (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
|
2018-04-02 19:05:26 +02:00
|
|
|
(call $~lib/polyfills/bswap16<u16>
|
2018-09-13 23:10:49 +02:00
|
|
|
(i32.const 43707)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
2018-08-02 18:23:02 +02:00
|
|
|
(func $~lib/polyfills/bswap16<i16> (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
|
2018-02-19 13:35:28 +02:00
|
|
|
(local $1 i32)
|
|
|
|
(if
|
|
|
|
(i32.eqz
|
2018-06-09 14:05:33 +02:00
|
|
|
(tee_local $1
|
|
|
|
(i32.const 1)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
2018-06-09 14:05:33 +02:00
|
|
|
(set_local $1
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.eqz
|
|
|
|
(get_local $1)
|
|
|
|
)
|
2018-02-19 13:35:28 +02:00
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 8)
|
2018-05-06 05:46:35 +02:00
|
|
|
(i32.const 27)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 2)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
2018-06-09 14:05:33 +02:00
|
|
|
(tee_local $1
|
|
|
|
(i32.const 1)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
(return
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.or
|
|
|
|
(i32.or
|
|
|
|
(i32.and
|
|
|
|
(i32.shl
|
|
|
|
(get_local $0)
|
|
|
|
(i32.const 8)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 65280)
|
|
|
|
)
|
|
|
|
(i32.and
|
|
|
|
(i32.shr_s
|
|
|
|
(i32.shl
|
2018-02-25 23:21:32 +01:00
|
|
|
(get_local $0)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 16)
|
2018-02-25 23:21:32 +01:00
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 24)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 255)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.and
|
|
|
|
(get_local $0)
|
|
|
|
(i32.const -65536)
|
|
|
|
)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(get_local $0)
|
|
|
|
)
|
2018-09-13 23:10:49 +02:00
|
|
|
(func $~lib/polyfills/bswap<i16> (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
|
2018-04-02 19:05:26 +02:00
|
|
|
(call $~lib/polyfills/bswap16<i16>
|
2018-09-13 23:10:49 +02:00
|
|
|
(i32.const 43707)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
)
|
2018-09-13 23:10:49 +02:00
|
|
|
(func $~lib/polyfills/bswap<u32> (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
|
|
|
|
(i32.const -573785174)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-09-13 23:10:49 +02:00
|
|
|
(func $~lib/polyfills/bswap<u64> (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$j) (result i64)
|
|
|
|
(i64.const -2464388556401798912)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-09-13 23:10:49 +02:00
|
|
|
(func $~lib/polyfills/bswap16<u32> (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
|
|
|
|
(i32.const -7816278)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-09-13 23:10:49 +02:00
|
|
|
(func $start (; 8 ;) (; has Stack IR ;) (type $v)
|
2018-02-19 13:35:28 +02:00
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.and
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u16>)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 65535)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
(i32.const 48042)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 4)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.and
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<i16>)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 65535)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 48042)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 5)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u32>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const -573785174)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 8)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u32>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const -573785174)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 9)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i64.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u64>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i64.const -2464388556401798912)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 12)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i64.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u64>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i64.const -2464388556401798912)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 13)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u32>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const -573785174)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 16)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap<u32>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const -573785174)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 17)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.and
|
|
|
|
(call $~lib/polyfills/bswap16<u16>
|
|
|
|
(i32.const 43707)
|
|
|
|
)
|
|
|
|
(i32.const 65535)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
(i32.const 48042)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 20)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.and
|
|
|
|
(call $~lib/polyfills/bswap16<i16>
|
|
|
|
(i32.const 43707)
|
|
|
|
)
|
|
|
|
(i32.const 65535)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
2018-05-06 00:00:54 +02:00
|
|
|
(i32.const 48042)
|
2018-02-19 13:35:28 +02:00
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 21)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap16<u32>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const -7816278)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 24)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
(if
|
|
|
|
(i32.ne
|
2018-09-13 23:10:49 +02:00
|
|
|
(call $~lib/polyfills/bswap16<u32>)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const -7816278)
|
|
|
|
)
|
|
|
|
(block
|
2018-05-21 18:48:29 +02:00
|
|
|
(call $~lib/env/abort
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 0)
|
2018-05-14 16:55:55 +02:00
|
|
|
(i32.const 48)
|
2018-02-19 13:35:28 +02:00
|
|
|
(i32.const 25)
|
|
|
|
(i32.const 0)
|
|
|
|
)
|
|
|
|
(unreachable)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
)
|
|
|
|
)
|