mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-07-04 20:29:53 +00:00
ARM JIT should observe -relocation-model command line option.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58433 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
0c39719bfc
commit
65f244261c
@ -85,7 +85,9 @@ ARMTargetMachine::ARMTargetMachine(const Module &M, const std::string &FS,
|
|||||||
InstrInfo(Subtarget),
|
InstrInfo(Subtarget),
|
||||||
FrameInfo(Subtarget),
|
FrameInfo(Subtarget),
|
||||||
JITInfo(*this),
|
JITInfo(*this),
|
||||||
TLInfo(*this) {}
|
TLInfo(*this) {
|
||||||
|
DefRelocModel = getRelocationModel();
|
||||||
|
}
|
||||||
|
|
||||||
unsigned ARMTargetMachine::getJITMatchQuality() {
|
unsigned ARMTargetMachine::getJITMatchQuality() {
|
||||||
#if defined(__arm__)
|
#if defined(__arm__)
|
||||||
@ -157,6 +159,7 @@ bool ARMTargetMachine::addAssemblyEmitter(PassManagerBase &PM, bool Fast,
|
|||||||
bool ARMTargetMachine::addCodeEmitter(PassManagerBase &PM, bool Fast,
|
bool ARMTargetMachine::addCodeEmitter(PassManagerBase &PM, bool Fast,
|
||||||
bool DumpAsm, MachineCodeEmitter &MCE) {
|
bool DumpAsm, MachineCodeEmitter &MCE) {
|
||||||
// FIXME: Move this to TargetJITInfo!
|
// FIXME: Move this to TargetJITInfo!
|
||||||
|
if (DefRelocModel == Reloc::Default)
|
||||||
setRelocationModel(Reloc::Static);
|
setRelocationModel(Reloc::Static);
|
||||||
|
|
||||||
// Machine code emitter pass for ARM.
|
// Machine code emitter pass for ARM.
|
||||||
|
@ -34,6 +34,7 @@ class ARMTargetMachine : public LLVMTargetMachine {
|
|||||||
ARMFrameInfo FrameInfo;
|
ARMFrameInfo FrameInfo;
|
||||||
ARMJITInfo JITInfo;
|
ARMJITInfo JITInfo;
|
||||||
ARMTargetLowering TLInfo;
|
ARMTargetLowering TLInfo;
|
||||||
|
Reloc::Model DefRelocModel; // Reloc model before it's overridden.
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
// To avoid having target depend on the asmprinter stuff libraries, asmprinter
|
// To avoid having target depend on the asmprinter stuff libraries, asmprinter
|
||||||
|
Loading…
Reference in New Issue
Block a user