Browse Source

* fix assignintreg on avr

git-svn-id: trunk@28744 -
florian 11 years ago
parent
commit
6b7557924e
1 changed files with 4 additions and 4 deletions
  1. 4 4
      compiler/avr/cpupara.pas

+ 4 - 4
compiler/avr/cpupara.pas

@@ -201,13 +201,13 @@ unit cpupara;
         begin
         begin
           { In case of po_delphi_nested_cc, the parent frame pointer
           { In case of po_delphi_nested_cc, the parent frame pointer
             is always passed on the stack. }
             is always passed on the stack. }
-           if (nextintreg>RS_R8) and
+           if (nextintreg>RS_R7) and
               (not(vo_is_parentfp in hp.varoptions) or
               (not(vo_is_parentfp in hp.varoptions) or
                not(po_delphi_nested_cc in p.procoptions)) then
                not(po_delphi_nested_cc in p.procoptions)) then
              begin
              begin
                paraloc^.loc:=LOC_REGISTER;
                paraloc^.loc:=LOC_REGISTER;
                paraloc^.register:=newreg(R_INTREGISTER,nextintreg,R_SUBWHOLE);
                paraloc^.register:=newreg(R_INTREGISTER,nextintreg,R_SUBWHOLE);
-               inc(nextintreg);
+               dec(nextintreg);
              end
              end
            else
            else
              begin
              begin
@@ -251,8 +251,8 @@ unit cpupara;
               begin
               begin
                 paradef:=getpointerdef(paradef);
                 paradef:=getpointerdef(paradef);
                 loc:=LOC_REGISTER;
                 loc:=LOC_REGISTER;
-                paracgsize := OS_ADDR;
-                paralen := tcgsize2size[OS_ADDR];
+                paracgsize:=OS_ADDR;
+                paralen:=tcgsize2size[OS_ADDR];
               end
               end
             else
             else
               begin
               begin