From 4320495319466c12543985ff7e653aedf81f8f36 Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Wed, 11 Mar 2015 18:34:58 +0000 Subject: Have getRegPressureSetLimit take a MachineFunction so that a we can inspect the subtarget and function when computing values. llvm-svn: 231951 --- llvm/lib/CodeGen/RegisterClassInfo.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/lib/CodeGen/RegisterClassInfo.cpp') diff --git a/llvm/lib/CodeGen/RegisterClassInfo.cpp b/llvm/lib/CodeGen/RegisterClassInfo.cpp index 4e1ede8618f..178fa18ac5a 100644 --- a/llvm/lib/CodeGen/RegisterClassInfo.cpp +++ b/llvm/lib/CodeGen/RegisterClassInfo.cpp @@ -176,6 +176,6 @@ unsigned RegisterClassInfo::computePSetLimit(unsigned Idx) const { } compute(RC); unsigned NReserved = RC->getNumRegs() - getNumAllocatableRegs(RC); - return TRI->getRegPressureSetLimit(Idx) - - TRI->getRegClassWeight(RC).RegWeight * NReserved; + return TRI->getRegPressureSetLimit(*MF, Idx) - + TRI->getRegClassWeight(RC).RegWeight * NReserved; } -- cgit v1.2.3