[lld] r190024 - [lld][ELF] Change the order of the writable note section
Shankar Easwaran
shankare at codeaurora.org
Wed Sep 4 18:50:21 PDT 2013
Author: shankare
Date: Wed Sep 4 20:50:21 2013
New Revision: 190024
URL: http://llvm.org/viewvc/llvm-project?rev=190024&view=rev
Log:
[lld][ELF] Change the order of the writable note section
Writable note sections if they exist should not appear before text
they belong in the data segment
Modified:
lld/trunk/lib/ReaderWriter/ELF/DefaultLayout.h
lld/trunk/test/elf/X86_64/note-sections-ro_plus_rw.test
Modified: lld/trunk/lib/ReaderWriter/ELF/DefaultLayout.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/DefaultLayout.h?rev=190024&r1=190023&r2=190024&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/DefaultLayout.h (original)
+++ lld/trunk/lib/ReaderWriter/ELF/DefaultLayout.h Wed Sep 4 20:50:21 2013
@@ -54,7 +54,6 @@ public:
ORDER_NOT_DEFINED = 0,
ORDER_INTERP = 10,
ORDER_RO_NOTE = 15,
- ORDER_RW_NOTE = 20,
ORDER_HASH = 30,
ORDER_DYNAMIC_SYMBOLS = 40,
ORDER_DYNAMIC_STRINGS = 50,
@@ -78,6 +77,7 @@ public:
ORDER_GOT = 180,
ORDER_GOT_PLT = 190,
ORDER_DATA = 200,
+ ORDER_RW_NOTE = 205,
ORDER_BSS = 210,
ORDER_OTHER = 220,
ORDER_SECTION_STRINGS = 230,
Modified: lld/trunk/test/elf/X86_64/note-sections-ro_plus_rw.test
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/elf/X86_64/note-sections-ro_plus_rw.test?rev=190024&r1=190023&r2=190024&view=diff
==============================================================================
--- lld/trunk/test/elf/X86_64/note-sections-ro_plus_rw.test (original)
+++ lld/trunk/test/elf/X86_64/note-sections-ro_plus_rw.test Wed Sep 4 20:50:21 2013
@@ -8,7 +8,6 @@ RUN: llvm-readobj -sections %t | FileChe
RUN: llvm-readobj -program-headers %t | FileCheck -check-prefix=NOTESEGMENT %s
NOTESECTIONS: Section {
-NOTESECTIONS: Index: 1
NOTESECTIONS: Name: .note.ro (1)
NOTESECTIONS: Type: SHT_NOTE (0x7)
NOTESECTIONS: Flags [ (0x2)
@@ -17,8 +16,7 @@ NOTESECTIONS: ]
NOTESECTIONS: AddressAlignment: 4
NOTESECTIONS: }
NOTESECTIONS: Section {
-NOTESECTIONS: Index: 2
-NOTESECTIONS: Name: .note.rw (10)
+NOTESECTIONS: Name: .note.rw (31)
NOTESECTIONS: Type: SHT_NOTE (0x7)
NOTESECTIONS: Flags [ (0x3)
NOTESECTIONS: SHF_ALLOC (0x2)
More information about the llvm-commits
mailing list