[llvm] r309819 - [InlineCost] Remove redundant call. NFC.
Chad Rosier via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 2 07:50:27 PDT 2017
Author: mcrosier
Date: Wed Aug 2 07:50:27 2017
New Revision: 309819
URL: http://llvm.org/viewvc/llvm-project?rev=309819&view=rev
Log:
[InlineCost] Remove redundant call. NFC.
Modified:
llvm/trunk/lib/Analysis/InlineCost.cpp
Modified: llvm/trunk/lib/Analysis/InlineCost.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/InlineCost.cpp?rev=309819&r1=309818&r2=309819&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/InlineCost.cpp (original)
+++ llvm/trunk/lib/Analysis/InlineCost.cpp Wed Aug 2 07:50:27 2017
@@ -1636,11 +1636,12 @@ InlineCost llvm::getInlineCost(
// Never inline functions with conflicting attributes (unless callee has
// always-inline attribute).
- if (!functionsHaveCompatibleAttributes(CS.getCaller(), Callee, CalleeTTI))
+ Function *Caller = CS.getCaller();
+ if (!functionsHaveCompatibleAttributes(Caller, Callee, CalleeTTI))
return llvm::InlineCost::getNever();
// Don't inline this call if the caller has the optnone attribute.
- if (CS.getCaller()->hasFnAttribute(Attribute::OptimizeNone))
+ if (Caller->hasFnAttribute(Attribute::OptimizeNone))
return llvm::InlineCost::getNever();
// Don't inline functions which can be interposed at link-time. Don't inline
More information about the llvm-commits
mailing list