aboutsummaryrefslogtreecommitdiff
path: root/tests/foo_64_win.asm
blob: e628aa2d43aad9da8d0012302061f8c065ca4423 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
bits 64

extern puts
global foo

section .data

message:
  db 'foo() called', 0

section .text

foo:
  nop
  push rbp
  mov rbp, rsp
  sub rsp, 32
  mov rcx, qword message
  call puts
  add rsp, 32
  pop rbp
  ret