[fpc-pascal] CPU registers and function calls, unclear explanation in the docs

Jonas Maebe jonas.maebe at elis.ugent.be
Sat Dec 17 02:04:51 CET 2011


On 17 Dec 2011, at 01:59, Jonas Maebe wrote:

> On 17 Dec 2011, at 01:46, Bernd wrote:
> 
>> Is there maybe any other document somewhere that describes what
>> *exactly* is expected by the compiler to happen with the registers
>> during a function call or maybe somebody can show me where in the FPC
>> sources I have to look to see for myself what exactly is going on?
> 
> On i386 with the "register" calling convention,
> * eax, ecx and edx are volatile (= caller can overwrite them without saving them)
> * ebx, esi, edi, ebp and esp and non-volatile (= caller must save/restore them if it overwrites them)

Sorry, caller -> callee


Jonas


More information about the fpc-pascal mailing list