mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-06 11:18:36 +02:00
* don't remove MOV reg1,reg1 it is needed for the RA
This commit is contained in:
parent
d99a5f58f3
commit
d5140a5792
@ -571,14 +571,11 @@ implementation
|
|||||||
OS_32,
|
OS_32,
|
||||||
OS_S32 :
|
OS_S32 :
|
||||||
begin
|
begin
|
||||||
if reg1<>reg2 then
|
instr:=taicpu.op_reg_reg(A_MOV,reg1,reg2);
|
||||||
begin
|
list.Concat(instr);
|
||||||
instr:=taicpu.op_reg_reg(A_MOV,reg1,reg2);
|
{ Notify the register allocator that we have written a move instruction so
|
||||||
list.Concat(instr);
|
it can try to eliminate it. }
|
||||||
{ Notify the register allocator that we have written a move instruction so
|
add_move_instruction(instr);
|
||||||
it can try to eliminate it. }
|
|
||||||
add_move_instruction(instr);
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
OS_S8 :
|
OS_S8 :
|
||||||
begin
|
begin
|
||||||
@ -597,14 +594,11 @@ implementation
|
|||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
{ same size, only a register mov required }
|
{ same size, only a register mov required }
|
||||||
if reg1<>reg2 then
|
instr:=taicpu.op_reg_reg(A_MOV,reg1,reg2);
|
||||||
begin
|
list.Concat(instr);
|
||||||
instr:=taicpu.op_reg_reg(A_MOV,reg1,reg2);
|
{ Notify the register allocator that we have written a move instruction so
|
||||||
list.Concat(instr);
|
it can try to eliminate it. }
|
||||||
{ Notify the register allocator that we have written a move instruction so
|
add_move_instruction(instr);
|
||||||
it can try to eliminate it. }
|
|
||||||
add_move_instruction(instr);
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -1233,7 +1227,10 @@ begin
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.87 2004-09-21 17:25:13 peter
|
Revision 1.88 2004-09-21 20:33:00 peter
|
||||||
|
* don't remove MOV reg1,reg1 it is needed for the RA
|
||||||
|
|
||||||
|
Revision 1.87 2004/09/21 17:25:13 peter
|
||||||
* paraloc branch merged
|
* paraloc branch merged
|
||||||
|
|
||||||
Revision 1.86.4.5 2004/09/20 20:43:15 peter
|
Revision 1.86.4.5 2004/09/20 20:43:15 peter
|
||||||
|
Loading…
Reference in New Issue
Block a user