the subtarget. Also remove unnecessary argument to the constructor
at the same time, we already have access via the subtarget.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210844
91177308-0d34-0410-b5e6-
96231b3b80d8
JCE.emitWordBE(0xf821ffb1); // stdu r1,-80(r1)
JCE.emitWordBE(0x7d6802a6); // mflr r11
JCE.emitWordBE(0xf9610060); // std r11, 96(r1)
- } else if (TM.getSubtargetImpl()->isDarwinABI()){
+ } else if (Subtarget.isDarwinABI()){
JCE.emitWordBE(0x9421ffe0); // stwu r1,-32(r1)
JCE.emitWordBE(0x7d6802a6); // mflr r11
JCE.emitWordBE(0x91610028); // stw r11, 40(r1)
#ifndef POWERPC_JITINFO_H
#define POWERPC_JITINFO_H
+#include "PPCSubtarget.h"
#include "llvm/CodeGen/JITCodeEmitter.h"
#include "llvm/Target/TargetJITInfo.h"
namespace llvm {
- class PPCTargetMachine;
class PPCJITInfo : public TargetJITInfo {
protected:
- PPCTargetMachine &TM;
+ PPCSubtarget &Subtarget;
bool is64Bit;
public:
- PPCJITInfo(PPCTargetMachine &tm, bool tmIs64Bit) : TM(tm) {
+ PPCJITInfo(PPCSubtarget &STI)
+ : Subtarget(STI), is64Bit(STI.isPPC64()) {
useGOT = 0;
- is64Bit = tmIs64Bit;
}
StubLayout getStubLayout() override;
Reloc::Model RM, CodeModel::Model CM,
CodeGenOpt::Level OL, bool is64Bit)
: LLVMTargetMachine(T, TT, CPU, FS, Options, RM, CM, OL),
- Subtarget(TT, CPU, FS, is64Bit, OL), JITInfo(*this, is64Bit),
+ Subtarget(TT, CPU, FS, is64Bit, OL), JITInfo(Subtarget),
TLInfo(*this), TSInfo(*this) {
initAsmInfo();
}