mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-22 08:50:43 +02:00
* FindRegAllocBackward will now return nil if it hits a dealloc for the register first
This commit is contained in:
parent
1fafcbc125
commit
d7d4b446c1
@ -1387,10 +1387,11 @@ Unit AoptObj;
|
|||||||
If Assigned(StartPai) And
|
If Assigned(StartPai) And
|
||||||
(StartPai.typ = ait_regAlloc) Then
|
(StartPai.typ = ait_regAlloc) Then
|
||||||
Begin
|
Begin
|
||||||
if (tai_regalloc(StartPai).ratype=ra_alloc) and
|
if SuperRegistersEqual(tai_regalloc(StartPai).Reg,Reg) then
|
||||||
SuperRegistersEqual(tai_regalloc(StartPai).Reg,Reg) then
|
|
||||||
begin
|
begin
|
||||||
Result:=tai_regalloc(StartPai);
|
{ If we find a dealloc first, say, return nil }
|
||||||
|
if (tai_regalloc(StartPai).ratype<>ra_dealloc) then
|
||||||
|
Result:=tai_regalloc(StartPai);
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
StartPai := Tai(StartPai.Previous);
|
StartPai := Tai(StartPai.Previous);
|
||||||
|
Loading…
Reference in New Issue
Block a user