You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ProceduremyProc();
FunctionmyFunc:byte;
Begin{ some code here }End;
Begin{ some code here }End;
Begin
myProc;
End.
Its result after compilation is more or less as follows:
{...}
.local MYPROC
jmp l_xxx
.local MYFUNC
{ assembled code of function myFunc() }
rts
.endl
l_xxx
{ assembled code of procedure myProc() }
rts
.endl
{...}
{ somewhere in code }
jmp MYPROC
{...}
Now, when the program makes a jump to the procedure myProc it jumps to the address where jmp l_xxx is, and not, to the address where the label l_xxx points to.
I can understand that this JMP l_xxx may be due to some compiler rules - forgive me, I don't know anything about compilers :) However, in time-critical situations, this jump is precious cycles.
My question.
Would it be possible to optimise this phenomenon? :)
I'll honestly say that even during debugging, it can mess with my head a bit ;) and I won't mention the precious cycles ;)
The text was updated successfully, but these errors were encountered:
We have such a piece of code:
Its result after compilation is more or less as follows:
Now, when the program makes a jump to the procedure
myProc
it jumps to the address wherejmp l_xxx
is, and not, to the address where the labell_xxx
points to.I can understand that this
JMP l_xxx
may be due to some compiler rules - forgive me, I don't know anything about compilers :) However, in time-critical situations, this jump is precious cycles.My question.
Would it be possible to optimise this phenomenon? :)
I'll honestly say that even during debugging, it can mess with my head a bit ;) and I won't mention the precious cycles ;)
The text was updated successfully, but these errors were encountered: