Browse Source

* capitalize omf segment class names, as that's how other 16-bit compilers write them

git-svn-id: trunk@31371 -
nickysn 10 năm trước cách đây
mục cha
commit
5dc42404cf
3 tập tin đã thay đổi với 20 bổ sung20 xóa
  1. 6 6
      compiler/ogomf.pas
  2. 10 10
      compiler/x86/agx86nsm.pas
  3. 4 4
      rtl/msdos/prt0comn.asm

+ 6 - 6
compiler/ogomf.pas

@@ -385,28 +385,28 @@ implementation
         FUse:=suUse16;
         if oso_executable in Aoptions then
           begin
-            FClassName:='code';
+            FClassName:='CODE';
             dgroup:=(current_settings.x86memorymodel=mm_tiny);
           end
         else if Aname='stack' then
           begin
-            FClassName:='stack';
+            FClassName:='STACK';
             FCombination:=scStack;
             dgroup:=current_settings.x86memorymodel in (x86_near_data_models-[mm_tiny]);
           end
         else if Aname='heap' then
           begin
-            FClassName:='heap';
+            FClassName:='HEAP';
             dgroup:=current_settings.x86memorymodel in x86_near_data_models;
           end
         else if Aname='bss' then
           begin
-            FClassName:='bss';
+            FClassName:='BSS';
             dgroup:=true;
           end
         else if Aname='data' then
           begin
-            FClassName:='data';
+            FClassName:='DATA';
             dgroup:=true;
           end
         else if (Aname='debug_frame') or
@@ -420,7 +420,7 @@ implementation
           end
         else
           begin
-            FClassName:='data';
+            FClassName:='DATA';
             dgroup:=true;
           end;
         if dgroup then

+ 10 - 10
compiler/x86/agx86nsm.pas

@@ -268,7 +268,7 @@ interface
         if current_settings.x86memorymodel in x86_far_code_models then
           begin
             if cs_huge_code in current_settings.moduleswitches then
-              result:=aname + '_TEXT use16 class=code'
+              result:=aname + '_TEXT use16 class=CODE'
             else
               result:=current_module.modulename^ + '_TEXT';
           end
@@ -533,11 +533,11 @@ interface
         else if (target_info.system=system_i8086_msdos) and
                 (atype=sec_stack) and
                 (current_settings.x86memorymodel in x86_far_data_models) then
-          AsmWrite('stack stack class=stack align=16')
+          AsmWrite('stack stack class=STACK align=16')
         else if (target_info.system=system_i8086_msdos) and
                 (atype=sec_heap) and
                 (current_settings.x86memorymodel in x86_far_data_models) then
-          AsmWrite('heap class=heap align=16')
+          AsmWrite('heap class=HEAP align=16')
 {$endif i8086}
         else
           AsmWrite(secnames[atype]);
@@ -1078,19 +1078,19 @@ interface
       end;
 
       if not (cs_huge_code in current_settings.moduleswitches) then
-        AsmWriteLn('SECTION ' + CodeSectionName(current_module.modulename^) + ' use16 class=code');
+        AsmWriteLn('SECTION ' + CodeSectionName(current_module.modulename^) + ' use16 class=CODE');
       { NASM complains if you put a missing section in the GROUP directive, so }
       { we add empty declarations to make sure they exist, even if empty }
-      AsmWriteLn('SECTION .rodata class=data align=2');
-      AsmWriteLn('SECTION .data class=data align=2');
-      AsmWriteLn('SECTION .fpc class=data');
+      AsmWriteLn('SECTION .rodata class=DATA align=2');
+      AsmWriteLn('SECTION .data class=DATA align=2');
+      AsmWriteLn('SECTION .fpc class=DATA');
       { WLINK requires class=bss in order to leave the BSS section out of the executable }
-      AsmWriteLn('SECTION .bss class=bss align=2');
+      AsmWriteLn('SECTION .bss class=BSS align=2');
       if (current_settings.x86memorymodel<>mm_tiny) and
          (current_settings.x86memorymodel in x86_near_data_models) then
-        AsmWriteLn('SECTION stack stack class=stack align=16');
+        AsmWriteLn('SECTION stack stack class=STACK align=16');
       if current_settings.x86memorymodel in x86_near_data_models then
-        AsmWriteLn('SECTION heap class=heap align=16');
+        AsmWriteLn('SECTION heap class=HEAP align=16');
       { group these sections in the same segment }
       if current_settings.x86memorymodel=mm_tiny then
         AsmWriteLn('GROUP DGROUP text rodata data fpc bss heap')

+ 4 - 4
rtl/msdos/prt0comn.asm

@@ -36,7 +36,7 @@
 
         cpu 8086
 
-        segment text use16 class=code
+        segment text use16 class=CODE
 
         extern PASCALMAIN
         extern __fpc_PrefixSeg
@@ -489,7 +489,7 @@ FPC_CHECK_NULLAREA:
     %endif
 %endif
 
-        segment data class=data align=2
+        segment data class=DATA align=2
 %ifdef __NEAR_DATA__
 mem_realloc_err_msg:
         db 'Memory allocation error', 13, 10, '$'
@@ -500,7 +500,7 @@ not_enough_mem_msg:
         ; module, containing the heap segment doesn't get smartlinked away
         dw ___heap
 
-        segment bss class=bss align=2
+        segment bss class=BSS align=2
 
 %ifndef __TINY__
         segment _NULL align=16 class=BEGDATA
@@ -513,7 +513,7 @@ __nullarea:
         dw 0
 
     %ifdef __NEAR_DATA__
-        segment stack stack class=stack
+        segment stack stack class=STACK
     %else
         segment data
         ; add reference to the beginning of stack, so the object module,