mirror of
https://github.com/netwide-assembler/nasm.git
synced 2024-11-27 08:10:07 +08:00
8781cb0d00
Correct the implementation of %arg and %local. It's questionable how much they make sense for 64-bit mode; even in 32-bit mode one normally make references off the stack pointer instead of the base pointer (frame pointer), but that requires keeping track of the stack pointer offset.
19 lines
267 B
NASM
19 lines
267 B
NASM
bits 32
|
|
|
|
%push bluttan
|
|
|
|
%define %$localsize 0
|
|
|
|
%stacksize flat
|
|
%local l1:qword, l2:dword, l3:dword, l4:qword
|
|
%arg a1:qword, a2:dword, a3:dword, a4:qword
|
|
|
|
mov eax,[a1]
|
|
mov ebx,[a2]
|
|
mov ecx,[a3]
|
|
mov edx,[a4]
|
|
mov [l1],eax
|
|
mov [l2],ebx
|
|
mov [l3],ecx
|
|
mov [l4],edx
|