Browse Source

an attempt to fix a bit more stuff in m68k

git-svn-id: trunk@794 -
Károly Balogh 20 years ago
parent
commit
bbfea4d03f
4 changed files with 13 additions and 18 deletions
  1. 6 11
      compiler/m68k/aasmcpu.pas
  2. 1 1
      compiler/m68k/cgcpu.pas
  3. 4 4
      compiler/m68k/cpubase.pas
  4. 2 2
      compiler/m68k/cpupara.pas

+ 6 - 11
compiler/m68k/aasmcpu.pas

@@ -442,21 +442,16 @@ type
     function taicpu.spilling_get_operation_type(opnr: longint): topertype;
       begin
         case opcode of
-          A_MOVE, A_ADD:
+          A_MOVE, A_MOVEQ, A_ADD, A_ADDQ, A_SUB, A_SUBQ:
             if opnr=0 then begin
-              writeln('move/add write');
+//              writeln('move/etc write');
               result:=operand_write;
             end else begin
-              writeln('move/add read');
+//              writeln('move/etc read');
               result:=operand_read;
             end;
-          A_RTS:
-            begin
-              writeln('rts!');
-              result:=operand_readwrite;
-            end;
         else
-          writeln('other opcode: (faked value returned)',opnr);
+          writeln('other opcode: ',dword(opcode),' (faked value returned)',opnr);
 	  result:=operand_write;
         end;
 	// fake
@@ -466,7 +461,7 @@ type
 
     function spilling_create_load(const ref:treference;r:tregister): tai;
       begin
-        writeln('spilling_create_load');
+//        writeln('spilling_create_load');
         case getregtype(r) of
           R_INTREGISTER :
             result:=taicpu.op_ref_reg(A_MOVE,S_L,ref,r);
@@ -496,7 +491,7 @@ type
 
     function spilling_create_store(r:tregister; const ref:treference): tai;
       begin
-        writeln('spilling_create_store');
+//        writeln('spilling_create_store');
 	case getregtype(r) of
 	  R_INTREGISTER :
 	    result:=taicpu.op_reg_ref(A_MOVE,S_L,r,ref);

+ 1 - 1
compiler/m68k/cgcpu.pas

@@ -886,7 +886,7 @@ unit cgcpu;
       begin
          popaddress := false;
 
-	 writeln('concatcopy:',len);
+//	 writeln('concatcopy:',len);
 
          { this should never occur }
          if len > 65535 then

+ 4 - 4
compiler/m68k/cpubase.pas

@@ -108,7 +108,7 @@ unit cpubase;
       { Available Superregisters }
       {$i r68ksup.inc}
 
-      { No Subregisters }
+      { ? whatever... }
       R_SUBWHOLE = R_SUBNONE;
 
       { Available Registers }
@@ -405,11 +405,11 @@ implementation
       begin
         case s of
           OS_8,OS_S8:
-            cgsize2subreg:=R_SUBL;
+            cgsize2subreg:=R_SUBWHOLE;
           OS_16,OS_S16:
-            cgsize2subreg:=R_SUBW;
+            cgsize2subreg:=R_SUBWHOLE;
           OS_32,OS_S32:
-            cgsize2subreg:=R_SUBD;
+            cgsize2subreg:=R_SUBWHOLE;
           else
             internalerror(200301231);
         end;

+ 2 - 2
compiler/m68k/cpupara.pas

@@ -345,7 +345,7 @@ unit cpupara;
                 if (loc = LOC_REGISTER) and
                    (nextintreg <= RS_D7) then
                   begin
-		    writeln('loc register');
+		    //writeln('loc register');
                     paraloc^.loc := loc;
                     { make sure we don't lose whether or not the type is signed }
                     if (paradef.deftype <> orddef) then
@@ -384,7 +384,7 @@ unit cpupara;
               end;
           end;
          result:=stack_offset;
-	 writeln('stack offset:',stack_offset);
+//	 writeln('stack offset:',stack_offset);
       end;