summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/RegUsageInfoCollector.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/CodeGen/RegUsageInfoCollector.cpp')
-rw-r--r--llvm/lib/CodeGen/RegUsageInfoCollector.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/RegUsageInfoCollector.cpp b/llvm/lib/CodeGen/RegUsageInfoCollector.cpp
index 2b418feb29e..f49ea25bbf3 100644
--- a/llvm/lib/CodeGen/RegUsageInfoCollector.cpp
+++ b/llvm/lib/CodeGen/RegUsageInfoCollector.cpp
@@ -95,7 +95,7 @@ bool RegUsageInfoCollector::runOnMachineFunction(MachineFunction &MF) {
unsigned RegMaskSize = (TRI->getNumRegs() + 31) / 32;
RegMask.resize(RegMaskSize, 0xFFFFFFFF);
- const Function *F = MF.getFunction();
+ const Function &F = MF.getFunction();
PhysicalRegisterUsageInfo *PRUI = &getAnalysis<PhysicalRegisterUsageInfo>();
@@ -127,7 +127,7 @@ bool RegUsageInfoCollector::runOnMachineFunction(MachineFunction &MF) {
if (!TargetFrameLowering::isSafeForNoCSROpt(F)) {
const uint32_t *CallPreservedMask =
- TRI->getCallPreservedMask(MF, F->getCallingConv());
+ TRI->getCallPreservedMask(MF, F.getCallingConv());
if (CallPreservedMask) {
// Set callee saved register as preserved.
for (unsigned i = 0; i < RegMaskSize; ++i)
@@ -145,7 +145,7 @@ bool RegUsageInfoCollector::runOnMachineFunction(MachineFunction &MF) {
DEBUG(dbgs() << " \n----------------------------------------\n");
- PRUI->storeUpdateRegUsageInfo(F, std::move(RegMask));
+ PRUI->storeUpdateRegUsageInfo(&F, std::move(RegMask));
return false;
}
OpenPOWER on IntegriCloud