Skip to content

A lightweight WebAssembly runtime that is fast, secure, and standards-compliant

978 B
Raw Blame
;;! target = "x86_64"
;;! test = "winch"
(module
  (memory 1)
  (func (export "i64_load8_s") (param $i i64) (result i64)
   (i64.store8 (i32.const 8) (local.get $i))
   (i64.load8_s (i32.const 8))
  )
)
;; wasm[0]::function[0]:
;;       pushq   %rbp
;;       movq    %rsp, %rbp
;;       movq    8(%rdi), %r11
;;       movq    0x18(%r11), %r11
;;       addq    $0x20, %r11
;;       cmpq    %rsp, %r11
;;       ja      0x65
;;   1c: movq    %rdi, %r14
;;       subq    $0x20, %rsp
;;       movq    %rdi, 0x18(%rsp)
;;       movq    %rsi, 0x10(%rsp)
;;       movq    %rdx, 8(%rsp)
;;       movq    8(%rsp), %rax
;;       movl    $8, %ecx
;;       movq    0x38(%r14), %rdx
;;       movl    %ecx, %ecx
;;       addq    %rcx, %rdx
;;       movb    %al, (%rdx)
;;       movl    $8, %eax
;;       movq    0x38(%r14), %rcx
;;       movl    %eax, %eax
;;       addq    %rax, %rcx
;;       movsbq  (%rcx), %rax
;;       addq    $0x20, %rsp
;;       popq    %rbp
;;       retq
;;   65: ud2