* better fix for previous revision

* also applied to x86 and m68k

git-svn-id: trunk@5512 -
This commit is contained in:
Jonas Maebe 2006-11-30 20:55:32 +00:00
parent 3c26e1c40b
commit 05a07a7dd2
4 changed files with 7 additions and 5 deletions

View File

@ -135,6 +135,8 @@ implementation
internalerror(20020814);
location.register:=cg.getfpuregister(current_asmdata.CurrAsmList,opsize);
if not(left.location.loc in [LOC_REGISTER,LOC_CREGISTER,LOC_REFERENCE,LOC_CREFERENCE]) then
location_force_reg(current_asmdata.CurrAsmList,left.location,OS_INT,false);
case left.location.loc of
LOC_REGISTER, LOC_CREGISTER:
begin

View File

@ -169,7 +169,7 @@ implementation
internalerror(200110011);
if not(left.location.loc in [LOC_REGISTER,LOC_CREGISTER,LOC_REFERENCE,LOC_CREFERENCE]) then
location_force_reg(current_asmdata.CurrAsmList,left.location,OS_INT,false);
location_force_reg(current_asmdata.CurrAsmList,left.location,left.location.size,false);
case left.location.loc of
LOC_REGISTER:
begin

View File

@ -149,7 +149,7 @@ begin
end;
if not(left.location.loc in [LOC_REGISTER,LOC_CREGISTER,LOC_REFERENCE,LOC_CREFERENCE]) then
location_force_reg(current_asmdata.CurrAsmList,left.location,OS_INT,false);
location_force_reg(current_asmdata.CurrAsmList,left.location,left.location.size,false);
case left.location.loc of
// the conversion algorithm does not modify the input register, so it can
// be used for both LOC_REGISTER and LOC_CREGISTER

View File

@ -205,6 +205,9 @@ implementation
hreg : tregister;
op : tasmop;
begin
if (left.location.loc in [LOC_SUBSETREG,LOC_CSUBSETREG,LOC_SUBSETREF,LOC_CSUBSETREF]) then
location_force_reg(current_asmdata.CurrAsmList,left.location,left.location.size,true);
{$ifdef x86_64}
if use_sse(resultdef) then
begin
@ -226,9 +229,6 @@ implementation
location_reset(location,LOC_MMREGISTER,def_cgsize(resultdef));
location.register:=cg.getmmregister(current_asmdata.CurrAsmList,def_cgsize(resultdef));
if (left.location.loc in [LOC_SUBSETREG,LOC_CSUBSETREG,LOC_SUBSETREF,LOC_CSUBSETREF]) then
location_force_reg(current_asmdata.CurrAsmList,left.location,left.location.size,true);
case torddef(left.resultdef).ordtype of
u64bit:
begin