mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 16:59:12 +02:00
* fix MovapXComisX2ComisX2 optimization
This commit is contained in:
parent
9e631db928
commit
68bc5da3a2
@ -2097,11 +2097,10 @@ unit aoptx86;
|
|||||||
)
|
)
|
||||||
) and not(OpsEqual(taicpu(hp1).oper[1]^,taicpu(hp1).oper[0]^)) then
|
) and not(OpsEqual(taicpu(hp1).oper[1]^,taicpu(hp1).oper[0]^)) then
|
||||||
{ change
|
{ change
|
||||||
movapX reg,reg2
|
movapX reg,reg1
|
||||||
addsX/subsX/... reg3, reg2
|
vcomisX reg1,reg1
|
||||||
movapX reg2,reg
|
|
||||||
to
|
to
|
||||||
addsX/subsX/... reg3,reg
|
vcomisX reg,reg
|
||||||
}
|
}
|
||||||
begin
|
begin
|
||||||
TransferUsedRegs(TmpUsedRegs);
|
TransferUsedRegs(TmpUsedRegs);
|
||||||
@ -2112,9 +2111,9 @@ unit aoptx86;
|
|||||||
debug_op2str(taicpu(p).opcode)+' '+
|
debug_op2str(taicpu(p).opcode)+' '+
|
||||||
debug_op2str(taicpu(hp1).opcode)+') done',p);
|
debug_op2str(taicpu(hp1).opcode)+') done',p);
|
||||||
if OpsEqual(taicpu(p).oper[1]^,taicpu(hp1).oper[0]^) then
|
if OpsEqual(taicpu(p).oper[1]^,taicpu(hp1).oper[0]^) then
|
||||||
taicpu(hp1).loadoper(0, taicpu(p).oper[1]^);
|
taicpu(hp1).loadoper(0, taicpu(p).oper[0]^);
|
||||||
if OpsEqual(taicpu(p).oper[1]^,taicpu(hp1).oper[1]^) then
|
if OpsEqual(taicpu(p).oper[1]^,taicpu(hp1).oper[1]^) then
|
||||||
taicpu(hp1).loadoper(1, taicpu(p).oper[1]^);
|
taicpu(hp1).loadoper(1, taicpu(p).oper[0]^);
|
||||||
RemoveCurrentP(p, nil);
|
RemoveCurrentP(p, nil);
|
||||||
result:=true;
|
result:=true;
|
||||||
exit;
|
exit;
|
||||||
|
Loading…
Reference in New Issue
Block a user