mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-16 08:59:26 +02:00
* don't overwrite cai_align with tai_align_abstract
* check that tai_align is used and not tai_align_abstract git-svn-id: trunk@8563 -
This commit is contained in:
parent
3c096a9549
commit
582fa79494
@ -2303,6 +2303,10 @@ implementation
|
||||
begin
|
||||
inherited Create;
|
||||
typ:=ait_align;
|
||||
{$ifdef EXTDEBUG}
|
||||
if upper(classname)='TAI_ALIGN_ABSTRACT' then
|
||||
internalerror(200709191);
|
||||
{$endif EXTDEBUG}
|
||||
if b in [1,2,4,8,16,32] then
|
||||
aligntype := b
|
||||
else
|
||||
@ -2371,5 +2375,8 @@ implementation
|
||||
|
||||
begin
|
||||
cai_cpu:=tai_cpu_abstract;
|
||||
cai_align:=tai_align_abstract;
|
||||
{ aasmcpu is earlier in the unit order and can
|
||||
already set the cai_align }
|
||||
if not assigned(cai_align) then
|
||||
cai_align:=tai_align_abstract;
|
||||
end.
|
||||
|
@ -422,7 +422,7 @@ implementation
|
||||
pleftreg := left.location.register;
|
||||
|
||||
if (opsize >= OS_S8) or { = if signed }
|
||||
((left.resultdef.typ=orddef) and
|
||||
((left.resultdef.typ=orddef) and
|
||||
((torddef(left.resultdef).low < int64(tsetdef(right.resultdef).setbase)) or
|
||||
(torddef(left.resultdef).high > int64(tsetdef(right.resultdef).setmax)))) or
|
||||
((left.resultdef.typ=enumdef) and
|
||||
@ -822,7 +822,7 @@ implementation
|
||||
{ generate the instruction blocks }
|
||||
for i:=0 to blocks.count-1 do
|
||||
begin
|
||||
current_asmdata.CurrAsmList.concat(Tai_align_abstract.create(current_settings.alignment.jumpalign));
|
||||
current_asmdata.CurrAsmList.concat(cai_align.create(current_settings.alignment.jumpalign));
|
||||
cg.a_label(current_asmdata.CurrAsmList,pcaseblock(blocks[i])^.blocklabel);
|
||||
secondpass(pcaseblock(blocks[i])^.statement);
|
||||
{ don't come back to case line }
|
||||
@ -832,7 +832,7 @@ implementation
|
||||
{$endif OLDREGVARS}
|
||||
cg.a_jmp_always(current_asmdata.CurrAsmList,endlabel);
|
||||
end;
|
||||
current_asmdata.CurrAsmList.concat(Tai_align_abstract.create(current_settings.alignment.jumpalign));
|
||||
current_asmdata.CurrAsmList.concat(cai_align.create(current_settings.alignment.jumpalign));
|
||||
{ ...and the else block }
|
||||
cg.a_label(current_asmdata.CurrAsmList,elselabel);
|
||||
if assigned(elseblock) then
|
||||
@ -842,7 +842,7 @@ implementation
|
||||
load_all_regvars(current_asmdata.CurrAsmList);
|
||||
{$endif OLDREGVARS}
|
||||
end;
|
||||
current_asmdata.CurrAsmList.concat(Tai_align_abstract.create(current_settings.alignment.jumpalign));
|
||||
current_asmdata.CurrAsmList.concat(cai_align.create(current_settings.alignment.jumpalign));
|
||||
cg.a_label(current_asmdata.CurrAsmList,endlabel);
|
||||
|
||||
{ Reset labels }
|
||||
|
Loading…
Reference in New Issue
Block a user