mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-22 04:29:29 +02:00
palmos: for C and syscall functions, expect return values in A0. mark D2 and A2 as volatile during function calls
git-svn-id: trunk@37896 -
This commit is contained in:
parent
58d98d8cd7
commit
9f974369a1
@ -80,6 +80,8 @@ unit cpupara;
|
||||
begin
|
||||
{ d0 and d1 are considered volatile }
|
||||
Result:=VOLATILE_INTREGISTERS;
|
||||
if target_info.system in [system_m68k_palmos] then
|
||||
include(result,RS_D2);
|
||||
end;
|
||||
|
||||
|
||||
@ -87,6 +89,8 @@ unit cpupara;
|
||||
begin
|
||||
{ a0 and a1 are considered volatile }
|
||||
Result:=VOLATILE_ADDRESSREGISTERS;
|
||||
if target_info.system in [system_m68k_palmos] then
|
||||
include(result,RS_A2);
|
||||
end;
|
||||
|
||||
function tcpuparamanager.get_volatile_registers_fpu(calloption:tproccalloption):tcpuregisterset;
|
||||
@ -240,8 +244,8 @@ unit cpupara;
|
||||
We also have to figure out a better switch for this, because this is
|
||||
now compiler and platform specific... (KB) }
|
||||
|
||||
if (tprocdef(p).proccalloption in [pocall_cdecl,pocall_cppdecl]) and
|
||||
(target_info.system in [system_m68k_linux]) and
|
||||
if (tprocdef(p).proccalloption in [pocall_syscall,pocall_cdecl,pocall_cppdecl]) and
|
||||
(target_info.system in [system_m68k_palmos,system_m68k_linux]) and
|
||||
assigned(result.def) and
|
||||
(result.def.typ in [stringdef,pointerdef,classrefdef,objectdef,
|
||||
procvardef,procdef,arraydef,formaldef]) then
|
||||
|
Loading…
Reference in New Issue
Block a user