소스 검색

Use TRegNameTable instead of array[tregisterindex] of string[10]

TRegNameTable is defined in compiler/rgbase.pas and is an array of
strings, limited to the maximum length of the used register names.

r22792 added a long register name but did not scale the string-size
enough, resulting in the compiler built breaking for arm.

git-svn-id: trunk@22817 -
masta 12 년 전
부모
커밋
e327b4581c

+ 1 - 1
compiler/arm/cpubase.pas

@@ -379,7 +379,7 @@ unit cpubase;
 
 
 
 
     const
     const
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i rarmstd.inc}
         {$i rarmstd.inc}
       );
       );
 
 

+ 2 - 2
compiler/arm/itcpugas.pas

@@ -43,10 +43,10 @@ interface
 implementation
 implementation
 
 
     uses
     uses
-      cutils,verbose;
+      cutils,verbose,rgbase;
 
 
     const
     const
-      gas_regname_table : array[tregisterindex] of string[10] = (
+      gas_regname_table : TRegNameTable = (
         {$i rarmstd.inc}
         {$i rarmstd.inc}
       );
       );
 
 

+ 1 - 1
compiler/avr/cpubase.pas

@@ -326,7 +326,7 @@ unit cpubase;
 
 
 
 
     const
     const
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i ravrstd.inc}
         {$i ravrstd.inc}
       );
       );
 
 

+ 1 - 1
compiler/m68k/cpubase.pas

@@ -353,7 +353,7 @@ implementation
 
 
 
 
     const
     const
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i r68kstd.inc}
         {$i r68kstd.inc}
       );
       );
 
 

+ 1 - 1
compiler/mips/cpubase.pas

@@ -295,7 +295,7 @@ unit cpubase;
 
 
 
 
     const
     const
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i rmipsstd.inc}
         {$i rmipsstd.inc}
       );
       );
 
 

+ 1 - 1
compiler/powerpc/cpubase.pas

@@ -422,7 +422,7 @@ implementation
       rgbase,verbose;
       rgbase,verbose;
 
 
     const
     const
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i rppcstd.inc}
         {$i rppcstd.inc}
       );
       );
 
 

+ 1 - 1
compiler/powerpc64/cpubase.pas

@@ -424,7 +424,7 @@ uses
   rgBase, verbose, itcpugas;
   rgBase, verbose, itcpugas;
 
 
 const
 const
-  std_regname_table: array[tregisterindex] of string[10] = (
+  std_regname_table: TRegNameTable = (
 {$I rppcstd.inc}
 {$I rppcstd.inc}
     );
     );
 
 

+ 1 - 1
compiler/rgbase.pas

@@ -29,7 +29,7 @@ interface
       cpuBase,cgBase;
       cpuBase,cgBase;
 
 
     type
     type
-      TRegNameTable = array[tregisterindex] of string[10];
+      TRegNameTable = array[tregisterindex] of string[11];
       TRegisterIndexTable = array[tregisterindex] of tregisterindex;
       TRegisterIndexTable = array[tregisterindex] of tregisterindex;
 
 
     function findreg_by_number_table(r:Tregister;const regnumber_index:TRegisterIndexTable):tregisterindex;
     function findreg_by_number_table(r:Tregister;const regnumber_index:TRegisterIndexTable):tregisterindex;

+ 2 - 2
compiler/x86/cpubase.pas

@@ -268,7 +268,7 @@ implementation
 
 
     const
     const
     {$ifdef x86_64}
     {$ifdef x86_64}
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i r8664std.inc}
         {$i r8664std.inc}
       );
       );
 
 
@@ -279,7 +279,7 @@ implementation
         {$i r8664sri.inc}
         {$i r8664sri.inc}
       );
       );
     {$else x86_64}
     {$else x86_64}
-      std_regname_table : array[tregisterindex] of string[10] = (
+      std_regname_table : TRegNameTable = (
         {$i r386std.inc}
         {$i r386std.inc}
       );
       );