NASM - The Netwide Assembler
NASM Forum => Programming with NASM => Topic started by: TemPiQ on April 13, 2019, 08:48:36 PM
-
Please forgive me if this question has been asked already.
I have sought in the forum for some time now without success.
I need a procedure that does not require automatic register saves or will not access the register spill area.
That means no need to use the EBP register
However if I code somthing like this:
proc Sample1
RDTSC
MOV DWORD[EDI],EAX
MOV EAX,EDI
RETN
endproc
nasm will compile as follows:
Sample1:
PUSH EBP
MOV EBP,ESP
RDTSC
MOV DWORD[EDI],EAX
MOV EAX,EDI
RETN
Thanks
@Frank Kotler:
Sorry I forgot the "endproc" which I have included now in the edited post
-
"proc"? What is "proc"? Not Nasm. Whatever it is, you probably want to get rid of it, since it is apparently generating code you don't want.
Best,
Frank