mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-12-16 02:10:44 +01:00
* eliminated the dual initialization of DS in interrupt procedures in the huge
memory model git-svn-id: trunk@31519 -
This commit is contained in:
parent
4c9b339c22
commit
98ec7a2211
@ -1777,7 +1777,8 @@ unit cgcpu;
|
||||
end
|
||||
else
|
||||
begin
|
||||
if current_settings.x86memorymodel=mm_huge then
|
||||
if (current_settings.x86memorymodel=mm_huge) and
|
||||
not (po_interrupt in current_procinfo.procdef.procoptions) then
|
||||
list.concat(Taicpu.Op_reg(A_POP,S_W,NR_DS));
|
||||
generate_leave(list);
|
||||
end;
|
||||
|
||||
@ -2893,6 +2893,13 @@ unit cgx86;
|
||||
list.concat(Taicpu.Op_reg_reg(A_MOV,S_W,NR_AX,NR_DS));
|
||||
end;
|
||||
end
|
||||
else if current_settings.x86memorymodel=mm_huge then
|
||||
begin
|
||||
reference_reset(fardataseg,0);
|
||||
fardataseg.refaddr:=addr_fardataseg;
|
||||
list.concat(Taicpu.Op_ref_reg(A_MOV,S_W,fardataseg,NR_AX));
|
||||
list.concat(Taicpu.Op_reg_reg(A_MOV,S_W,NR_AX,NR_DS));
|
||||
end
|
||||
else
|
||||
begin
|
||||
reference_reset(dgroup,0);
|
||||
@ -2977,7 +2984,8 @@ unit cgx86;
|
||||
end;
|
||||
|
||||
{$ifdef i8086}
|
||||
if current_settings.x86memorymodel=mm_huge then
|
||||
if (current_settings.x86memorymodel=mm_huge) and
|
||||
not (po_interrupt in current_procinfo.procdef.procoptions) then
|
||||
begin
|
||||
list.concat(Taicpu.op_reg(A_PUSH,S_W,NR_DS));
|
||||
reference_reset(fardataseg,0);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user