Remove the use and member variable of the TargetMachine from

MachineLICM as we can get the same data off of the MachineFunction.

llvm-svn: 219663
This commit is contained in:
Eric Christopher 2014-10-14 06:26:57 +00:00
parent 20c98938bb
commit b65c7b919c
1 changed files with 4 additions and 6 deletions

View File

@ -62,7 +62,6 @@ STATISTIC(NumPostRAHoisted,
namespace {
class MachineLICM : public MachineFunctionPass {
const TargetMachine *TM;
const TargetInstrInfo *TII;
const TargetLoweringBase *TLI;
const TargetRegisterInfo *TRI;
@ -322,13 +321,12 @@ bool MachineLICM::runOnMachineFunction(MachineFunction &MF) {
return false;
Changed = FirstInLoop = false;
TM = &MF.getTarget();
TII = TM->getSubtargetImpl()->getInstrInfo();
TLI = TM->getSubtargetImpl()->getTargetLowering();
TRI = TM->getSubtargetImpl()->getRegisterInfo();
TII = MF.getSubtarget().getInstrInfo();
TLI = MF.getSubtarget().getTargetLowering();
TRI = MF.getSubtarget().getRegisterInfo();
MFI = MF.getFrameInfo();
MRI = &MF.getRegInfo();
InstrItins = TM->getSubtargetImpl()->getInstrItineraryData();
InstrItins = MF.getSubtarget().getInstrItineraryData();
PreRegAlloc = MRI->isSSA();