aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/MC/MCObjectFileInfo.cpp
diff options
context:
space:
mode:
authorValentin Churavy <v.churavy@gmail.com>2020-11-06 14:26:04 -0500
committerJameson Nash <vtjnash@gmail.com>2020-11-06 14:41:30 -0500
commit18805ea951be02fcab6e7b11c3c7d929bcf1441a (patch)
tree3e1e43b3d0d3eac5b77f2fa5df467df77016dcf0 /llvm/lib/MC/MCObjectFileInfo.cpp
parent573ade4bef005a36dc02f2df0b3fcb57ef7b6a72 (diff)
downloadllvm-18805ea951be02fcab6e7b11c3c7d929bcf1441a.zip
llvm-18805ea951be02fcab6e7b11c3c7d929bcf1441a.tar.gz
llvm-18805ea951be02fcab6e7b11c3c7d929bcf1441a.tar.bz2
Fix unwind info relocation with large code model on AArch64
Makes sure that the unwind info uses 64bits pcrel relocation if a large code model is specified and handle the corresponding relocation in the ExecutionEngine. This can happen with certain kernel configuration (the same as the one in https://reviews.llvm.org/D27609, found at least on the ArchLinux stock kernel and the one used on https://www.packet.net/) using the builtin JIT memory manager. Co-authored-by: Yichao Yu <yyc1992@gmail.com> Differential Revision: https://reviews.llvm.org/D27629
Diffstat (limited to 'llvm/lib/MC/MCObjectFileInfo.cpp')
-rw-r--r--llvm/lib/MC/MCObjectFileInfo.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCObjectFileInfo.cpp b/llvm/lib/MC/MCObjectFileInfo.cpp
index 1349494..9505420 100644
--- a/llvm/lib/MC/MCObjectFileInfo.cpp
+++ b/llvm/lib/MC/MCObjectFileInfo.cpp
@@ -317,6 +317,8 @@ void MCObjectFileInfo::initELFMCObjectFileInfo(const Triple &T, bool Large) {
break;
case Triple::ppc64:
case Triple::ppc64le:
+ case Triple::aarch64:
+ case Triple::aarch64_be:
case Triple::x86_64:
FDECFIEncoding = dwarf::DW_EH_PE_pcrel |
(Large ? dwarf::DW_EH_PE_sdata8 : dwarf::DW_EH_PE_sdata4);