| (module |
| (type $FUNCSIG$i (func (result i32))) |
| (type $FUNCSIG$vj (func (param i64))) |
| (type $FUNCSIG$ii (func (param i32) (result i32))) |
| (export "ret" (func $ret)) |
| (export "waka" (func $if-0-unreachable-to-none)) |
| (export "many-selects" (func $many-selects)) |
| (export "end-if-else" (func $end-if-else)) |
| (export "end-if-else-call" (func $end-if-else-call)) |
| (func $ret (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32) |
| (drop |
| (call $ret) |
| ) |
| (if |
| (call $ret) |
| (return |
| (i32.const 1) |
| ) |
| ) |
| (i32.const 999) |
| ) |
| (func $if-0-unreachable-to-none (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$vj) (param $0 i64) |
| (unreachable) |
| ) |
| (func $many-selects (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32) |
| (select |
| (i32.const -1073741824) |
| (select |
| (i32.const 1073741823) |
| (local.get $0) |
| (i32.gt_s |
| (local.get $0) |
| (i32.const 1073741823) |
| ) |
| ) |
| (i32.lt_s |
| (local.get $0) |
| (i32.const -1073741824) |
| ) |
| ) |
| ) |
| (func $end-if-else (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32) |
| (select |
| (i32.const 1) |
| (local.get $0) |
| (local.get $0) |
| ) |
| ) |
| (func $end-if-else-call (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32) |
| (if (result i32) |
| (local.get $0) |
| (call $ret) |
| (local.get $0) |
| ) |
| ) |
| ) |