Преглед изворни кода

m68k: if we have a symbol in the location reference, that will be base, so try to insert an index register instead, reduces the amount of data->address register shuffling in the generated code

git-svn-id: trunk@33647 -
Károly Balogh пре 9 година
родитељ
комит
524659b341
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      compiler/m68k/n68kmem.pas

+ 1 - 1
compiler/m68k/n68kmem.pas

@@ -90,7 +90,7 @@ implementation
               end;
               end;
           end;
           end;
 
 
-        if (location.reference.base=NR_NO) and not (scaled) then
+        if (location.reference.base=NR_NO) and not (scaled) and not assigned(location.reference.symbol) then
           begin
           begin
            { prefer an address reg, if we will be a base, for indexes any register works }
            { prefer an address reg, if we will be a base, for indexes any register works }
             if isintregister(maybe_const_reg) then
             if isintregister(maybe_const_reg) then