Browse Source

cpu_i8086 and system_i8086_msdos added to the systems.inc enums

git-svn-id: branches/i8086@23710 -
nickysn 12 years ago
parent
commit
44ffc298d5
3 changed files with 16 additions and 2 deletions
  1. 5 0
      compiler/globals.pas
  2. 7 0
      compiler/pp.pas
  3. 4 2
      compiler/systems.inc

+ 5 - 0
compiler/globals.pas

@@ -460,6 +460,11 @@ interface
         optimizecputype : cpu_armv8;
         optimizecputype : cpu_armv8;
         fputype : fpu_vfp;
         fputype : fpu_vfp;
   {$endif aarch64}
   {$endif aarch64}
+  {$ifdef i8086}
+        cputype : cpu_8086;
+        optimizecputype : cpu_8086;
+        fputype : fpu_x87;
+  {$endif i8086}
 {$endif not GENERIC_CPU}
 {$endif not GENERIC_CPU}
         asmmode : asmmode_standard;
         asmmode : asmmode_standard;
 {$ifndef jvm}
 {$ifndef jvm}

+ 7 - 0
compiler/pp.pas

@@ -25,6 +25,7 @@ program pp;
   possible compiler switches:
   possible compiler switches:
   -----------------------------------------------------------------
   -----------------------------------------------------------------
   CMEM                use cmem unit for better memory debugging
   CMEM                use cmem unit for better memory debugging
+  I8086               generate a compiler for the Intel 8086+
   I386                generate a compiler for the Intel i386+
   I386                generate a compiler for the Intel i386+
   x86_64              generate a compiler for the AMD x86-64 architecture
   x86_64              generate a compiler for the AMD x86-64 architecture
   M68K                generate a compiler for the M68000
   M68K                generate a compiler for the M68000
@@ -62,6 +63,12 @@ program pp;
 {$endif}
 {$endif}
 
 
 { exactly one target CPU must be defined }
 { exactly one target CPU must be defined }
+{$ifdef I8086}
+  {$ifdef CPUDEFINED}
+    {$fatal ONLY one of the switches for the CPU type must be defined}
+  {$endif CPUDEFINED}
+  {$define CPUDEFINED}
+{$endif I8086}
 {$ifdef I386}
 {$ifdef I386}
   {$ifdef CPUDEFINED}
   {$ifdef CPUDEFINED}
     {$fatal ONLY one of the switches for the CPU type must be defined}
     {$fatal ONLY one of the switches for the CPU type must be defined}

+ 4 - 2
compiler/systems.inc

@@ -48,7 +48,8 @@
              cpu_powerpc64,                { 11 }
              cpu_powerpc64,                { 11 }
              cpu_avr,                      { 12 }
              cpu_avr,                      { 12 }
              cpu_mipsel,                   { 13 }
              cpu_mipsel,                   { 13 }
-             cpu_jvm                       { 14 }
+             cpu_jvm,                      { 14 }
+             cpu_i8086                     { 15 }
        );
        );
 
 
        tasmmode= (asmmode_none
        tasmmode= (asmmode_none
@@ -155,7 +156,8 @@
              system_jvm_java32,         { 75 }
              system_jvm_java32,         { 75 }
              system_jvm_android32,      { 76 }
              system_jvm_android32,      { 76 }
              system_arm_android,        { 77 }
              system_arm_android,        { 77 }
-             system_i386_android        { 78 }
+             system_i386_android,       { 78 }
+             system_i8086_msdos         { 79 }
        );
        );
 
 
      type
      type