[fpc-devel] How do I find out which registers are actually used in an interrupt procedure and need to get pushed
Michael Ring
mail at michael-ring.org
Thu Jun 30 18:20:48 CEST 2016
This tip worked just fine, I was too blind to see how this works .....
Thank you Jonas!
Michael
Am 30.06.16 um 15:47 schrieb Jonas Maebe:
>
> Michael Ring wrote on Thu, 30 Jun 2016:
>
>> So far I understood the fpc code that registers s0-s7 are
>> automagically flagged when used as those are the registers that must
>> be saved in the context of a standard procedure/function call.
>>
>> Same does apply for some of the Floating Point Registers.
>>
>> But when I look at the list of registers to be saved the registers
>> like $v0 and $v1 are not included, but usually used.
>
> You'll probably want to modify
> tcpuparamanager.get_volatile_registers_(int/fpu) in
> compiler/mips/cpupara.pas based on the passed calloption.
>
> Volatile registers are registers that do not need to be saved by the
> callee according to the ABI, even if they are modified by the callee.
> For interrupt routines, you'll probably want to return an empty set
> there.
>
>
> Jonas
> _______________________________________________
> fpc-devel maillist - fpc-devel at lists.freepascal.org
> http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel
More information about the fpc-devel
mailing list