mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-13 10:59:18 +02:00
* use correct sizes when getting additional registers for 64 bit values
git-svn-id: branches/avr@17044 -
This commit is contained in:
parent
d060e199f4
commit
88b0db90a6
@ -500,7 +500,7 @@ implementation
|
|||||||
cg.a_load_reg_reg(list,l.size,OS_32,l.register64.reglo,hregister);
|
cg.a_load_reg_reg(list,l.size,OS_32,l.register64.reglo,hregister);
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
hregister:=cg.getintregister(list,OS_INT);
|
hregister:=cg.getintregister(list,OS_32);
|
||||||
{ load value in low register }
|
{ load value in low register }
|
||||||
case l.loc of
|
case l.loc of
|
||||||
{$ifdef cpuflags}
|
{$ifdef cpuflags}
|
||||||
@ -521,7 +521,7 @@ implementation
|
|||||||
cg.a_load_loc_reg(list,OS_INT,l,hregister);
|
cg.a_load_loc_reg(list,OS_INT,l,hregister);
|
||||||
end;
|
end;
|
||||||
{ reset hi part, take care of the signed bit of the current value }
|
{ reset hi part, take care of the signed bit of the current value }
|
||||||
hregisterhi:=cg.getintregister(list,OS_INT);
|
hregisterhi:=cg.getintregister(list,OS_32);
|
||||||
if (l.size in [OS_S8,OS_S16,OS_S32]) then
|
if (l.size in [OS_S8,OS_S16,OS_S32]) then
|
||||||
begin
|
begin
|
||||||
if l.loc=LOC_CONSTANT then
|
if l.loc=LOC_CONSTANT then
|
||||||
@ -554,8 +554,8 @@ implementation
|
|||||||
end
|
end
|
||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
hregister:=cg.getintregister(list,OS_INT);
|
hregister:=cg.getintregister(list,OS_32);
|
||||||
hregisterhi:=cg.getintregister(list,OS_INT);
|
hregisterhi:=cg.getintregister(list,OS_32);
|
||||||
const_location := false;
|
const_location := false;
|
||||||
end;
|
end;
|
||||||
hreg64.reglo:=hregister;
|
hreg64.reglo:=hregister;
|
||||||
@ -625,8 +625,8 @@ implementation
|
|||||||
l.reference.alignment:=newalignment(l.reference.alignment,TCGSize2Size[l.size]-TCGSize2Size[dst_size]);
|
l.reference.alignment:=newalignment(l.reference.alignment,TCGSize2Size[l.size]-TCGSize2Size[dst_size]);
|
||||||
end;
|
end;
|
||||||
{$ifdef x86}
|
{$ifdef x86}
|
||||||
if not (l.loc in [LOC_SUBSETREG,LOC_CSUBSETREG]) then
|
if not (l.loc in [LOC_SUBSETREG,LOC_CSUBSETREG]) then
|
||||||
l.size:=dst_size;
|
l.size:=dst_size;
|
||||||
{$endif x86}
|
{$endif x86}
|
||||||
end;
|
end;
|
||||||
cg.a_load_loc_reg(list,dst_size,l,hregister);
|
cg.a_load_loc_reg(list,dst_size,l,hregister);
|
||||||
|
Loading…
Reference in New Issue
Block a user