소스 검색

make rgobj.uses_registers also return true, when the rg never allocated an imreg, but there were direct cpu register allocations. this at least fixes some address regvar trashing on 68k in relation to syscalls' explicit paralocs

git-svn-id: trunk@34777 -
Károly Balogh 8 년 전
부모
커밋
e0e90fffc4
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      compiler/rgobj.pas

+ 3 - 1
compiler/rgobj.pas

@@ -228,6 +228,7 @@ unit rgobj;
         extended_backwards,
         backwards_was_first : tbitset;
         has_usedmarks: boolean;
+        has_directalloc: boolean;
 
         { Disposes of the reginfo array.}
         procedure dispose_reginfo;
@@ -523,7 +524,7 @@ unit rgobj;
 
     function trgobj.uses_registers:boolean;
       begin
-        result:=(maxreg>first_imaginary) or has_usedmarks;
+        result:=(maxreg>first_imaginary) or has_usedmarks or has_directalloc;
       end;
 
 
@@ -543,6 +544,7 @@ unit rgobj;
         if supreg>=first_imaginary then
           internalerror(2003121503);
         include(used_in_proc,supreg);
+        has_directalloc:=true;
         list.concat(Tai_regalloc.alloc(r,nil));
       end;