summaryrefslogtreecommitdiffstats
path: root/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp
diff options
context:
space:
mode:
authorNick Kledzik <kledzik@apple.com>2014-11-06 01:09:13 +0000
committerNick Kledzik <kledzik@apple.com>2014-11-06 01:09:13 +0000
commit5c4693d8d20ad5fb354f247907376cd9d07d514f (patch)
tree388a864aec3c9cd8bde47953bcb785961b81c347 /lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp
parent30804c42207801541c84346fcc8ec6e5333def34 (diff)
downloadbcm5719-llvm-5c4693d8d20ad5fb354f247907376cd9d07d514f.tar.gz
bcm5719-llvm-5c4693d8d20ad5fb354f247907376cd9d07d514f.zip
[mach-o] Add support for interposing tuples section
Darwin uses two-level-namespace lookup for symbols which means the static linker records where each symbol must be found at runtime. Thus defining a symbol in a dylib loaded earlier will not effect where symbols needed by later dylibs will be found. Instead overriding is done through a section of type S_INTERPOSING which contains tuples of <interposer, interposee>. llvm-svn: 221421
Diffstat (limited to 'lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp')
-rw-r--r--lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp b/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp
index 54899b00a0f..ec66d480833 100644
--- a/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp
+++ b/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp
@@ -77,6 +77,8 @@ const MachORelocatableSectionToAtomType sectsToAtomType[] = {
ENTRY("__DATA", "___bss", S_ZEROFILL, typeZeroFill),
ENTRY("", "", S_NON_LAZY_SYMBOL_POINTERS,
typeGOT),
+ ENTRY("__DATA", "__interposing", S_INTERPOSING, typeInterposingTuples),
+ ENTRY("", "", S_INTERPOSING, typeInterposingTuples),
ENTRY("__LD", "__compact_unwind", S_REGULAR,
typeCompactUnwindInfo),
ENTRY("", "", S_REGULAR, typeUnknown)
OpenPOWER on IntegriCloud