summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
diff options
context:
space:
mode:
authorAdam Kallai <kadam@inf.u-szeged.hu>2019-11-20 10:51:03 +0200
committerMartin Storsjö <martin@martin.st>2019-11-20 10:59:42 +0200
commitdc3ee330891c230f85242b442de9afe7fdb96da2 (patch)
tree85aef7a347bb72c75e22715d63857439c33a0b0e /llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
parent1cc78fdb6f7d81d58cdafa44b0966708dc8575bf (diff)
downloadbcm5719-llvm-dc3ee330891c230f85242b442de9afe7fdb96da2.tar.gz
bcm5719-llvm-dc3ee330891c230f85242b442de9afe7fdb96da2.zip
ExecutionEngine: add preliminary support for COFF ARM64
Differential Revision: https://reviews.llvm.org/D69434
Diffstat (limited to 'llvm/lib/Target/AArch64/AArch64TargetMachine.cpp')
-rw-r--r--llvm/lib/Target/AArch64/AArch64TargetMachine.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp b/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
index 9dc1654b461..28310b0bdd9 100644
--- a/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
+++ b/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
@@ -249,7 +249,10 @@ getEffectiveAArch64CodeModel(const Triple &TT, Optional<CodeModel::Model> CM,
// The default MCJIT memory managers make no guarantees about where they can
// find an executable page; JITed code needs to be able to refer to globals
// no matter how far away they are.
- if (JIT)
+ // We should set the CodeModel::Small for Windows ARM64 in JIT mode,
+ // since with large code model LLVM generating 4 MOV instructions, and
+ // Windows doesn't support relocating these long branch (4 MOVs).
+ if (JIT && !TT.isOSWindows())
return CodeModel::Large;
return CodeModel::Small;
}
OpenPOWER on IntegriCloud