summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/ELFObjectWriter.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2017-02-09 14:59:20 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2017-02-09 14:59:20 +0000
commitdc1c3011fd2dfb75f6a1f4f20fa73344956a54a4 (patch)
tree468a5687f782aa72ed347cc62bc2ed5f6cc9b437 /llvm/lib/MC/ELFObjectWriter.cpp
parent6953b324750de9978e7c9d1d50c269a12fb38cc1 (diff)
downloadbcm5719-llvm-dc1c3011fd2dfb75f6a1f4f20fa73344956a54a4.tar.gz
bcm5719-llvm-dc1c3011fd2dfb75f6a1f4f20fa73344956a54a4.zip
Make it possible to set SHF_LINK_ORDER explicitly.
This will make it possible to add support for gcing user metadata (asan for example). llvm-svn: 294589
Diffstat (limited to 'llvm/lib/MC/ELFObjectWriter.cpp')
-rw-r--r--llvm/lib/MC/ELFObjectWriter.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/MC/ELFObjectWriter.cpp b/llvm/lib/MC/ELFObjectWriter.cpp
index e9f4f1cce33..3d1a16c904c 100644
--- a/llvm/lib/MC/ELFObjectWriter.cpp
+++ b/llvm/lib/MC/ELFObjectWriter.cpp
@@ -1157,8 +1157,7 @@ void ELFObjectWriter::writeSection(const SectionIndexMapTy &SectionIndexMap,
break;
}
- if (TargetObjectWriter->getEMachine() == ELF::EM_ARM &&
- Section.getType() == ELF::SHT_ARM_EXIDX)
+ if (Section.getFlags() & ELF::SHF_LINK_ORDER)
sh_link = SectionIndexMap.lookup(Section.getAssociatedSection());
WriteSecHdrEntry(StrTabBuilder.getOffset(Section.getSectionName()),
OpenPOWER on IntegriCloud