* implemented r30870 for all platforms: pass dyn. array parameters like pointer parameters so typically in a register

git-svn-id: trunk@30878 -
This commit is contained in:
florian 2015-05-17 12:29:28 +00:00
parent 9b987fde93
commit b4fc11fe06
5 changed files with 18 additions and 5 deletions

View File

@ -163,7 +163,10 @@ unit cpupara;
filedef:
getparaloc:=LOC_REGISTER;
arraydef:
getparaloc:=LOC_REFERENCE;
if is_dynamic_array(p) then
getparaloc:=LOC_REGISTER
else
getparaloc:=LOC_REFERENCE;
setdef:
if is_smallset(p) then
getparaloc:=LOC_REGISTER

View File

@ -99,7 +99,10 @@ unit cpupara;
filedef:
getparaloc:=LOC_REGISTER;
arraydef:
getparaloc:=LOC_REFERENCE;
if is_dynamic_array(p) then
getparaloc:=LOC_REGISTER
else
getparaloc:=LOC_REFERENCE;
setdef:
if is_smallset(p) then
getparaloc:=LOC_REGISTER

View File

@ -629,7 +629,8 @@ unit cpupara;
if (parareg<=high(parasupregs)) and
(paralen<=sizeof(aint)) and
(not(hp.vardef.typ in [floatdef,recorddef,arraydef]) or
pushaddr) and
pushaddr or
is_dynamic_array(hp.vardef)) and
(not(vo_is_parentfp in hp.varoptions) or
not(po_delphi_nested_cc in p.procoptions)) then
begin

View File

@ -165,7 +165,10 @@ unit cpupara;
filedef:
result:=LOC_REGISTER;
arraydef:
result:=LOC_REFERENCE;
if is_dynamic_array(p) then
getparaloc:=LOC_REGISTER
else
result:=LOC_REFERENCE;
setdef:
if is_smallset(p) then
result:=LOC_REGISTER

View File

@ -146,7 +146,10 @@ begin
filedef:
result := LOC_REGISTER;
arraydef:
result := LOC_REFERENCE;
if is_dynamic_array(p) then
getparaloc:=LOC_REGISTER
else
result := LOC_REFERENCE;
setdef:
if is_smallset(p) then
result := LOC_REGISTER