A lightweight WebAssembly runtime that is fast, secure, and standards-compliant
;;! target = "x86_64"
;;! test = "winch"
;;! flags = [ "-Ccranelift-has-avx" ]
(module
(memory 1 1)
(func (result v128)
(i64x2.sub
(i64x2.splat (i64.const 10))
(i64x2.splat (i64.const 10))
)))
;; wasm[0]::function[0]:
;; pushq %rbp
;; movq %rsp, %rbp
;; movq 8(%rdi), %r11
;; movq 0x18(%r11), %r11
;; addq $0x10, %r11
;; cmpq %rsp, %r11
;; ja 0x4e
;; 1c: movq %rdi, %r14
;; subq $0x10, %rsp
;; movq %rdi, 8(%rsp)
;; movq %rsi, (%rsp)
;; vpshufd $0x44, 0x18(%rip), %xmm0
;; vpshufd $0x44, 0xf(%rip), %xmm1
;; vpsubq %xmm1, %xmm0, %xmm0
;; addq $0x10, %rsp
;; popq %rbp
;; retq
;; 4e: ud2
;; 50: orb (%rax), %al
;; 52: addb %al, (%rax)
;; 54: addb %al, (%rax)
;; 56: addb %al, (%rax)