Move PPCInstrInfo off of the target machine and onto the subtarget.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@210839 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Christopher
2014-06-12 22:05:46 +00:00
parent 647ab7f728
commit e3466d3777
4 changed files with 11 additions and 7 deletions

View File

@@ -29,7 +29,6 @@ namespace llvm {
///
class PPCTargetMachine : public LLVMTargetMachine {
PPCSubtarget Subtarget;
PPCInstrInfo InstrInfo;
PPCJITInfo JITInfo;
PPCTargetLowering TLInfo;
PPCSelectionDAGInfo TSInfo;
@@ -40,7 +39,9 @@ public:
Reloc::Model RM, CodeModel::Model CM,
CodeGenOpt::Level OL, bool is64Bit);
const PPCInstrInfo *getInstrInfo() const override { return &InstrInfo; }
const PPCInstrInfo *getInstrInfo() const override {
return getSubtargetImpl()->getInstrInfo();
}
const PPCFrameLowering *getFrameLowering() const override {
return getSubtargetImpl()->getFrameLowering();
}
@@ -51,8 +52,8 @@ public:
const PPCSelectionDAGInfo* getSelectionDAGInfo() const override {
return &TSInfo;
}
const PPCRegisterInfo *getRegisterInfo() const override {
return &InstrInfo.getRegisterInfo();
const PPCRegisterInfo *getRegisterInfo() const override {
return &getInstrInfo()->getRegisterInfo();
}
const DataLayout *getDataLayout() const override {