From: Eric Christopher Date: Fri, 30 Jan 2015 01:50:09 +0000 (+0000) Subject: Migrate a bare getSubtarget call to query the MachineFunction X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3084aff4988ccabc7e8f604edcb5cf1acfa13e56;p=platform%2Fupstream%2Fllvm.git Migrate a bare getSubtarget call to query the MachineFunction for the target dependent one. llvm-svn: 227542 --- diff --git a/llvm/lib/Target/NVPTX/NVPTXPrologEpilogPass.cpp b/llvm/lib/Target/NVPTX/NVPTXPrologEpilogPass.cpp index a1e1b9e..c1c67e3 100644 --- a/llvm/lib/Target/NVPTX/NVPTXPrologEpilogPass.cpp +++ b/llvm/lib/Target/NVPTX/NVPTXPrologEpilogPass.cpp @@ -48,9 +48,9 @@ MachineFunctionPass *llvm::createNVPTXPrologEpilogPass() { char NVPTXPrologEpilogPass::ID = 0; bool NVPTXPrologEpilogPass::runOnMachineFunction(MachineFunction &MF) { - const TargetMachine &TM = MF.getTarget(); - const TargetFrameLowering &TFI = *TM.getSubtargetImpl()->getFrameLowering(); - const TargetRegisterInfo &TRI = *TM.getSubtargetImpl()->getRegisterInfo(); + const TargetSubtargetInfo &STI = MF.getSubtarget(); + const TargetFrameLowering &TFI = *STI.getFrameLowering(); + const TargetRegisterInfo &TRI = *STI.getRegisterInfo(); bool Modified = false; calculateFrameObjectOffsets(MF);