mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-03 09:29:42 +01:00
* fixed calling sequence for subroutines using the aix abi
This commit is contained in:
parent
5bd25ccc15
commit
999b859bc8
@ -43,7 +43,7 @@ unit cpupara;
|
||||
implementation
|
||||
|
||||
uses
|
||||
verbose,
|
||||
verbose,systems,
|
||||
cpuinfo,cginfo,cgbase,
|
||||
defutil;
|
||||
|
||||
@ -162,6 +162,8 @@ unit cpupara;
|
||||
hp.paraloc.loc:=LOC_REGISTER;
|
||||
hp.paraloc.register:=nextintreg;
|
||||
inc(nextintreg.number,NR_R1-NR_R0);
|
||||
if target_info.abi=abi_powerpc_aix then
|
||||
inc(stack_offset,4);
|
||||
end
|
||||
else
|
||||
begin
|
||||
@ -178,7 +180,14 @@ unit cpupara;
|
||||
nextintreg.number:=NR_R3;
|
||||
nextfloatreg.enum:=R_F1;
|
||||
nextmmreg.enum:=R_M1;
|
||||
stack_offset:=0;
|
||||
case target_info.abi of
|
||||
abi_powerpc_aix:
|
||||
stack_offset:=24;
|
||||
abi_powerpc_sysv:
|
||||
stack_offset:=8;
|
||||
else
|
||||
internalerror(2003051901);
|
||||
end;
|
||||
|
||||
{ frame pointer for nested procedures? }
|
||||
{ inc(nextintreg); }
|
||||
@ -206,10 +215,14 @@ unit cpupara;
|
||||
hp.paraloc.loc:=LOC_REGISTER;
|
||||
hp.paraloc.registerlow:=nextintreg;
|
||||
inc(nextintreg.number,NR_R1-NR_R0);
|
||||
if target_info.abi=abi_powerpc_aix then
|
||||
inc(stack_offset,4);
|
||||
if is_64bit then
|
||||
begin
|
||||
hp.paraloc.registerhigh:=nextintreg;
|
||||
inc(nextintreg.number,NR_R1-NR_R0);
|
||||
if target_info.abi=abi_powerpc_aix then
|
||||
inc(stack_offset,4);
|
||||
end;
|
||||
end
|
||||
else
|
||||
@ -233,6 +246,8 @@ unit cpupara;
|
||||
hp.paraloc.loc:=LOC_FPUREGISTER;
|
||||
hp.paraloc.register:=nextfloatreg;
|
||||
inc(nextfloatreg.enum);
|
||||
if target_info.abi=abi_powerpc_aix then
|
||||
inc(stack_offset,8);
|
||||
end
|
||||
else
|
||||
begin
|
||||
@ -317,7 +332,10 @@ begin
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.29 2003-05-12 20:14:47 florian
|
||||
Revision 1.30 2003-05-19 12:15:28 florian
|
||||
* fixed calling sequence for subroutines using the aix abi
|
||||
|
||||
Revision 1.29 2003/05/12 20:14:47 florian
|
||||
* fixed parameter passing by value of large sets, strings and method pointers
|
||||
|
||||
Revision 1.28 2003/05/11 23:19:32 florian
|
||||
|
||||
@ -218,7 +218,8 @@ unit i_linux;
|
||||
stacksize : 32*1024*1024;
|
||||
DllScanSupported:false;
|
||||
use_function_relative_addresses : true;
|
||||
abi : abi_powerpc_sysv;
|
||||
{ abi_powerpc_sysv doesn't work yet }
|
||||
abi : abi_powerpc_aix;
|
||||
);
|
||||
|
||||
system_alpha_linux_info : tsysteminfo =
|
||||
@ -447,7 +448,10 @@ initialization
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.6 2003-05-18 15:15:59 florian
|
||||
Revision 1.7 2003-05-19 12:15:28 florian
|
||||
* fixed calling sequence for subroutines using the aix abi
|
||||
|
||||
Revision 1.6 2003/05/18 15:15:59 florian
|
||||
+ added abi field to tsysteminfo
|
||||
|
||||
Revision 1.5 2003/04/30 15:45:35 florian
|
||||
|
||||
Loading…
Reference in New Issue
Block a user