[llvm] r293480 - Fix the values of two xcore ELF flags.

Rafael Espindola via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 30 06:07:44 PST 2017


Author: rafael
Date: Mon Jan 30 08:07:43 2017
New Revision: 293480

URL: http://llvm.org/viewvc/llvm-project?rev=293480&view=rev
Log:
Fix the values of two xcore ELF flags.

The values in llvm grew from a pre-MC day when they would not show up
in .o files and are outside of the SHF_MASKPROC.

Fortunately the MC output is not currently used as xcore has its own
assemble and that assembler uses valid values. This updates llvm to
use the same values as the xmos assembler.

Modified:
    llvm/trunk/include/llvm/Support/ELF.h

Modified: llvm/trunk/include/llvm/Support/ELF.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/ELF.h?rev=293480&r1=293479&r2=293480&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/ELF.h (original)
+++ llvm/trunk/include/llvm/Support/ELF.h Mon Jan 30 08:07:43 2017
@@ -751,21 +751,21 @@ enum : unsigned {
 
   // Start of target-specific flags.
 
-  /// XCORE_SHF_CP_SECTION - All sections with the "c" flag are grouped
-  /// together by the linker to form the constant pool and the cp register is
-  /// set to the start of the constant pool by the boot code.
-  XCORE_SHF_CP_SECTION = 0x800U,
-
-  /// XCORE_SHF_DP_SECTION - All sections with the "d" flag are grouped
-  /// together by the linker to form the data section and the dp register is
-  /// set to the start of the section by the boot code.
-  XCORE_SHF_DP_SECTION = 0x1000U,
-
   SHF_MASKOS = 0x0ff00000,
 
   // Bits indicating processor-specific flags.
   SHF_MASKPROC = 0xf0000000,
 
+  /// All sections with the "d" flag are grouped together by the linker to form
+  /// the data section and the dp register is set to the start of the section by
+  /// the boot code.
+  XCORE_SHF_DP_SECTION = 0x10000000,
+
+  /// All sections with the "c" flag are grouped together by the linker to form
+  /// the constant pool and the cp register is set to the start of the constant
+  /// pool by the boot code.
+  XCORE_SHF_CP_SECTION = 0x20000000,
+
   // If an object file section does not have this flag set, then it may not hold
   // more than 2GB and can be freely referred to in objects using smaller code
   // models. Otherwise, only objects using larger code models can refer to them.




More information about the llvm-commits mailing list