Skip to content

Instantly share code, notes, and snippets.

@alexcrichton
Created July 2, 2018 16:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alexcrichton/e5cafad8455795aff2c40652fe4d4dc3 to your computer and use it in GitHub Desktop.
Save alexcrichton/e5cafad8455795aff2c40652fe4d4dc3 to your computer and use it in GitHub Desktop.
(module
(type $0 (func))
(type $1 (func (result i32)))
(import "env" "__linear_memory" (memory $0 0))
(import "env" "__indirect_function_table" (table 0 anyfunc))
(import "env" "return_one" (func $fimport$2 (result i32)))
(import "env" "panic" (func $fimport$3))
(func $0 (; 2 ;) (type $0)
(local $var$0 i32)
(local $var$1 i32)
(local $var$2 i32)
(local $var$3 i32)
(local $var$4 i32)
(local $var$5 i32)
(local $var$6 i32)
(set_local $var$0
(call $fimport$2)
)
(set_local $var$1
(i32.const 1)
)
(set_local $var$2
(get_local $var$0)
)
(set_local $var$3
(get_local $var$1)
)
(set_local $var$4
(i32.eq
(get_local $var$2)
(get_local $var$3)
)
)
(set_local $var$5
(i32.const -1)
)
(set_local $var$6
(i32.xor
(get_local $var$4)
(get_local $var$5)
)
)
(block $label$1
(br_if $label$1
(get_local $var$4)
)
(call $fimport$3)
(unreachable)
)
(block $label$2
(br_if $label$2
(get_local $var$6)
)
(call $fimport$3)
(unreachable)
)
(return)
)
;; custom section "linking", size 22
;; custom section "reloc.CODE", size 11
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment