diff options
author | Matthias Braun <matze@braunis.de> | 2015-02-14 01:16:54 +0000 |
---|---|---|
committer | Matthias Braun <matze@braunis.de> | 2015-02-14 01:16:54 +0000 |
commit | 821ec14add365e93a7e1b26d58f15d928eae4d09 (patch) | |
tree | 158ae7f610fc5ac47ee3e686471fce5774248aa7 /lib/Target/TargetLoweringObjectFile.cpp | |
parent | 7520a90c75f339e03e3f37a20a9506dd7eb0061d (diff) |
Revert "On ELF, put PIC jump tables in a non executable section."
This reverts commit r228939.
The commit broke something in the output of exception handling tables on
darwin x86-64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229203 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/TargetLoweringObjectFile.cpp')
-rw-r--r-- | lib/Target/TargetLoweringObjectFile.cpp | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/lib/Target/TargetLoweringObjectFile.cpp b/lib/Target/TargetLoweringObjectFile.cpp index faa6fbe6075..c098035a5aa 100644 --- a/lib/Target/TargetLoweringObjectFile.cpp +++ b/lib/Target/TargetLoweringObjectFile.cpp @@ -275,24 +275,6 @@ const MCSection *TargetLoweringObjectFile::getSectionForJumpTable( return getSectionForConstant(SectionKind::getReadOnly(), /*C=*/nullptr); } -bool TargetLoweringObjectFile::shouldPutJumpTableInFunctionSection( - bool UsesLabelDifference, const Function &F) const { - // In PIC mode, we need to emit the jump table to the same section as the - // function body itself, otherwise the label differences won't make sense. - // FIXME: Need a better predicate for this: what about custom entries? - if (UsesLabelDifference) - return true; - - // We should also do if the section name is NULL or function is declared - // in discardable section - // FIXME: this isn't the right predicate, should be based on the MCSection - // for the function. - if (F.isWeakForLinker()) - return true; - - return false; -} - /// getSectionForConstant - Given a mergable constant with the /// specified size and relocation information, return a section that it /// should be placed in. |