(module (type $i32_i32_=>_i32 (func (param i32 i32) (result i32))) (type $none_=>_none (func)) (type $i32_i32_=>_none (func (param i32 i32))) (type $none_=>_i32 (func (result i32))) (import "env" "printf" (func $printf (param i32 i32) (result i32))) (import "env" "__handle_stack_overflow" (func $__handle_stack_overflow)) (memory $0 2) (data (i32.const 568) "%d:%d\n\00Result: %d\n\00") (table $0 1 1 funcref) (global $global$0 (mut i32) (i32.const 66128)) (global $global$1 i32 (i32.const 66128)) (global $global$2 i32 (i32.const 587)) (global $__stack_base (mut i32) (i32.const 0)) (global $__stack_limit (mut i32) (i32.const 0)) (export "memory" (memory $0)) (export "__wasm_call_ctors" (func $__wasm_call_ctors)) (export "__heap_base" (global $global$1)) (export "__data_end" (global $global$2)) (export "main" (func $main)) (export "__set_stack_limits" (func $__set_stack_limits)) (func $__wasm_call_ctors (nop) ) (func $foo (param $0 i32) (param $1 i32) (result i32) (local $2 i32) (local $3 i32) (local $4 i32) (block (if (i32.or (i32.gt_u (local.tee $3 (local.tee $2 (i32.sub (global.get $global$0) (i32.const 16) ) ) ) (global.get $__stack_base) ) (i32.lt_u (local.get $3) (global.get $__stack_limit) ) ) (call $__handle_stack_overflow) ) (global.set $global$0 (local.get $3) ) ) (i32.store offset=4 (local.get $2) (local.get $1) ) (i32.store (local.get $2) (local.get $0) ) (drop (call $printf (i32.const 568) (local.get $2) ) ) (block (if (i32.or (i32.gt_u (local.tee $4 (i32.add (local.get $2) (i32.const 16) ) ) (global.get $__stack_base) ) (i32.lt_u (local.get $4) (global.get $__stack_limit) ) ) (call $__handle_stack_overflow) ) (global.set $global$0 (local.get $4) ) ) (i32.add (local.get $1) (local.get $0) ) ) (func $__original_main (result i32) (local $0 i32) (local $1 i32) (local $2 i32) (block (if (i32.or (i32.gt_u (local.tee $1 (local.tee $0 (i32.sub (global.get $global$0) (i32.const 16) ) ) ) (global.get $__stack_base) ) (i32.lt_u (local.get $1) (global.get $__stack_limit) ) ) (call $__handle_stack_overflow) ) (global.set $global$0 (local.get $1) ) ) (i32.store (local.get $0) (call $foo (i32.const 1) (i32.const 2) ) ) (drop (call $printf (i32.const 575) (local.get $0) ) ) (block (if (i32.or (i32.gt_u (local.tee $2 (i32.add (local.get $0) (i32.const 16) ) ) (global.get $__stack_base) ) (i32.lt_u (local.get $2) (global.get $__stack_limit) ) ) (call $__handle_stack_overflow) ) (global.set $global$0 (local.get $2) ) ) (i32.const 0) ) (func $main (param $0 i32) (param $1 i32) (result i32) (call $__original_main) ) (func $__set_stack_limits (param $0 i32) (param $1 i32) (global.set $__stack_base (local.get $0) ) (global.set $__stack_limit (local.get $1) ) ) ) (; --BEGIN METADATA -- { "tableSize": 1, "initializers": [ "__wasm_call_ctors" ], "declares": [ "printf", "__handle_stack_overflow" ], "externs": [ ], "exports": [ "__wasm_call_ctors", "main", "__set_stack_limits" ], "namedGlobals": { "__heap_base" : "66128", "__data_end" : "587" }, "invokeFuncs": [ ], "mainReadsParams": 0, "features": [ ] } -- END METADATA -- ;)