[llvm] r271600 - [PM/LoadCombine] Inline getAnalysisUsage(). NFCI.
Davide Italiano via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 2 15:04:44 PDT 2016
Author: davide
Date: Thu Jun 2 17:04:43 2016
New Revision: 271600
URL: http://llvm.org/viewvc/llvm-project?rev=271600&view=rev
Log:
[PM/LoadCombine] Inline getAnalysisUsage(). NFCI.
Modified:
llvm/trunk/lib/Transforms/Scalar/LoadCombine.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/LoadCombine.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoadCombine.cpp?rev=271600&r1=271599&r2=271600&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LoadCombine.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LoadCombine.cpp Thu Jun 2 17:04:43 2016
@@ -65,7 +65,11 @@ public:
using llvm::Pass::doInitialization;
bool doInitialization(Function &) override;
bool runOnBasicBlock(BasicBlock &BB) override;
- void getAnalysisUsage(AnalysisUsage &AU) const override;
+ void getAnalysisUsage(AnalysisUsage &AU) const override {
+ AU.setPreservesCFG();
+ AU.addRequired<AAResultsWrapperPass>();
+ AU.addPreserved<GlobalsAAWrapperPass>();
+ }
const char *getPassName() const override { return LDCOMBINE_NAME; }
static char ID;
@@ -262,13 +266,6 @@ bool LoadCombine::runOnBasicBlock(BasicB
return Combined;
}
-void LoadCombine::getAnalysisUsage(AnalysisUsage &AU) const {
- AU.setPreservesCFG();
-
- AU.addRequired<AAResultsWrapperPass>();
- AU.addPreserved<GlobalsAAWrapperPass>();
-}
-
char LoadCombine::ID = 0;
BasicBlockPass *llvm::createLoadCombinePass() {
More information about the llvm-commits
mailing list