mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-11 15:47:51 +02:00
* Fix for go32v2 specific failure in test/cg/tcalval5 with -Aas option
git-svn-id: trunk@21443 -
This commit is contained in:
parent
069cd9f250
commit
b9f8934d7e
@ -148,6 +148,7 @@ unit cgcpu;
|
|||||||
procedure pushdata(paraloc:pcgparalocation;ofs:tcgint);
|
procedure pushdata(paraloc:pcgparalocation;ofs:tcgint);
|
||||||
var
|
var
|
||||||
pushsize : tcgsize;
|
pushsize : tcgsize;
|
||||||
|
opsize : topsize;
|
||||||
tmpreg : tregister;
|
tmpreg : tregister;
|
||||||
href : treference;
|
href : treference;
|
||||||
begin
|
begin
|
||||||
@ -170,16 +171,21 @@ unit cgcpu;
|
|||||||
pushsize:=paraloc^.size
|
pushsize:=paraloc^.size
|
||||||
else
|
else
|
||||||
pushsize:=int_cgsize(cgpara.alignment);
|
pushsize:=int_cgsize(cgpara.alignment);
|
||||||
|
opsize:=TCgsize2opsize[pushsize];
|
||||||
|
{ for go32v2 we obtain OS_F32,
|
||||||
|
but pushs is not valid, we need pushl }
|
||||||
|
if opsize=S_FS then
|
||||||
|
opsize:=S_L;
|
||||||
if tcgsize2size[paraloc^.size]<cgpara.alignment then
|
if tcgsize2size[paraloc^.size]<cgpara.alignment then
|
||||||
begin
|
begin
|
||||||
tmpreg:=getintregister(list,pushsize);
|
tmpreg:=getintregister(list,pushsize);
|
||||||
a_load_ref_reg(list,paraloc^.size,pushsize,href,tmpreg);
|
a_load_ref_reg(list,paraloc^.size,pushsize,href,tmpreg);
|
||||||
list.concat(taicpu.op_reg(A_PUSH,TCgsize2opsize[pushsize],tmpreg));
|
list.concat(taicpu.op_reg(A_PUSH,opsize,tmpreg));
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
make_simple_ref(list,href);
|
make_simple_ref(list,href);
|
||||||
list.concat(taicpu.op_ref(A_PUSH,TCgsize2opsize[pushsize],href));
|
list.concat(taicpu.op_ref(A_PUSH,opsize,href));
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user