fastcall question
when ues fastcall do i have to move first param into Eax , and second param into Edx and so on or it automatically done by Ziorn
for example i am implement a simple strcpy function like this
function fastcall strcpy(Dword src,dst)
{
Eax = src;
Edx = dst;
push Edx;
BL = BYTE [Eax];
while ( BL != 0)
{
BYTE [Edx] = BL;
Eax++; Edx++;
BL = BYTE [Eax];
}
[Edx] = 0;
pop Eax;
}
or like this
function fastcall strcpy(Dword src,dst)
{
// eax already holds src and edx holds dst
push Edx;
BL = BYTE [Eax];
while ( BL != 0)
{
BYTE [Edx] = BL;
Eax++; Edx++;
BL = BYTE [Eax];
}
[Edx] = 0;
pop Eax;
}
http://www.freewebs.com/ogremagic/index.htm