aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Analysis
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2008-03-19 21:56:59 +0000
committerDevang Patel <dpatel@apple.com>2008-03-19 21:56:59 +0000
commit3aab76e3790476cc00f04706e7c6d71fcf2e92a1 (patch)
tree88b334fb5710b2d63089bdb840135dc1e8f7ebfa /include/llvm/Analysis
parent9f15357bf1a50b2bec0864bfbf4d6a8aa8c8148c (diff)
downloadexternal_llvm-3aab76e3790476cc00f04706e7c6d71fcf2e92a1.zip
external_llvm-3aab76e3790476cc00f04706e7c6d71fcf2e92a1.tar.gz
external_llvm-3aab76e3790476cc00f04706e7c6d71fcf2e92a1.tar.bz2
PassInfo keep tracks whether a pass is an analysis pass or not.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48554 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis')
-rw-r--r--include/llvm/Analysis/Dominators.h4
-rw-r--r--include/llvm/Analysis/FindUsedTypes.h2
-rw-r--r--include/llvm/Analysis/IntervalPartition.h2
-rw-r--r--include/llvm/Analysis/LoopInfo.h5
-rw-r--r--include/llvm/Analysis/LoopPass.h2
-rw-r--r--include/llvm/Analysis/MemoryDependenceAnalysis.h2
-rw-r--r--include/llvm/Analysis/PostDominators.h2
-rw-r--r--include/llvm/Analysis/ScalarEvolution.h2
8 files changed, 12 insertions, 9 deletions
diff --git a/include/llvm/Analysis/Dominators.h b/include/llvm/Analysis/Dominators.h
index 1b7fa75..ce305d5 100644
--- a/include/llvm/Analysis/Dominators.h
+++ b/include/llvm/Analysis/Dominators.h
@@ -664,7 +664,7 @@ public:
static char ID; // Pass ID, replacement for typeid
DominatorTreeBase<BasicBlock>* DT;
- DominatorTree() : FunctionPass(intptr_t(&ID), true) {
+ DominatorTree() : FunctionPass(intptr_t(&ID)) {
DT = new DominatorTreeBase<BasicBlock>(false);
}
@@ -837,7 +837,7 @@ protected:
public:
DominanceFrontierBase(intptr_t ID, bool isPostDom)
- : FunctionPass(ID, true), IsPostDominators(isPostDom) {}
+ : FunctionPass(ID), IsPostDominators(isPostDom) {}
/// getRoots - Return the root blocks of the current CFG. This may include
/// multiple blocks if we are computing post dominators. For forward
diff --git a/include/llvm/Analysis/FindUsedTypes.h b/include/llvm/Analysis/FindUsedTypes.h
index 6a128c8..b0d38c5 100644
--- a/include/llvm/Analysis/FindUsedTypes.h
+++ b/include/llvm/Analysis/FindUsedTypes.h
@@ -25,7 +25,7 @@ class FindUsedTypes : public ModulePass {
std::set<const Type *> UsedTypes;
public:
static char ID; // Pass identification, replacement for typeid
- FindUsedTypes() : ModulePass((intptr_t)&ID, true) {}
+ FindUsedTypes() : ModulePass((intptr_t)&ID) {}
/// getTypes - After the pass has been run, return the set containing all of
/// the types used in the module.
diff --git a/include/llvm/Analysis/IntervalPartition.h b/include/llvm/Analysis/IntervalPartition.h
index 42d27fe..8b85e7c 100644
--- a/include/llvm/Analysis/IntervalPartition.h
+++ b/include/llvm/Analysis/IntervalPartition.h
@@ -47,7 +47,7 @@ class IntervalPartition : public FunctionPass {
public:
static char ID; // Pass identification, replacement for typeid
- IntervalPartition() : FunctionPass((intptr_t)&ID, true), RootInterval(0) {}
+ IntervalPartition() : FunctionPass((intptr_t)&ID), RootInterval(0) {}
// run - Calculate the interval partition for this function
virtual bool runOnFunction(Function &F);
diff --git a/include/llvm/Analysis/LoopInfo.h b/include/llvm/Analysis/LoopInfo.h
index cc2b10e..ab7cb7e 100644
--- a/include/llvm/Analysis/LoopInfo.h
+++ b/include/llvm/Analysis/LoopInfo.h
@@ -879,7 +879,7 @@ class LoopInfo : public FunctionPass {
public:
static char ID; // Pass identification, replacement for typeid
- LoopInfo() : FunctionPass(intptr_t(&ID), true) {
+ LoopInfo() : FunctionPass(intptr_t(&ID)) {
LI = new LoopInfoBase<BasicBlock>();
}
@@ -919,6 +919,9 @@ public:
return LI->isLoopHeader(BB);
}
+ /// isAnalysis - Return true if this pass is implementing an analysis pass.
+ bool isAnalysis() const { return true; }
+
/// runOnFunction - Calculate the natural loop information.
///
virtual bool runOnFunction(Function &F);
diff --git a/include/llvm/Analysis/LoopPass.h b/include/llvm/Analysis/LoopPass.h
index 8ebbbaf..c0cdce2 100644
--- a/include/llvm/Analysis/LoopPass.h
+++ b/include/llvm/Analysis/LoopPass.h
@@ -29,7 +29,7 @@ class PMStack;
class LoopPass : public Pass {
public:
- explicit LoopPass(intptr_t pid, bool AP = false) : Pass(pid, AP) {}
+ explicit LoopPass(intptr_t pid) : Pass(pid) {}
// runOnLoop - This method should be implemented by the subclass to perform
// whatever action is necessary for the specfied Loop.
diff --git a/include/llvm/Analysis/MemoryDependenceAnalysis.h b/include/llvm/Analysis/MemoryDependenceAnalysis.h
index c683a6b..c6ef41f 100644
--- a/include/llvm/Analysis/MemoryDependenceAnalysis.h
+++ b/include/llvm/Analysis/MemoryDependenceAnalysis.h
@@ -66,7 +66,7 @@ class MemoryDependenceAnalysis : public FunctionPass {
static Instruction* const Dirty;
static char ID; // Class identification, replacement for typeinfo
- MemoryDependenceAnalysis() : FunctionPass((intptr_t)&ID, true) {}
+ MemoryDependenceAnalysis() : FunctionPass((intptr_t)&ID) {}
/// Pass Implementation stuff. This doesn't do any analysis.
///
diff --git a/include/llvm/Analysis/PostDominators.h b/include/llvm/Analysis/PostDominators.h
index f20f050..07910e9 100644
--- a/include/llvm/Analysis/PostDominators.h
+++ b/include/llvm/Analysis/PostDominators.h
@@ -25,7 +25,7 @@ struct PostDominatorTree : public FunctionPass {
static char ID; // Pass identification, replacement for typeid
DominatorTreeBase<BasicBlock>* DT;
- PostDominatorTree() : FunctionPass((intptr_t)&ID, true) {
+ PostDominatorTree() : FunctionPass((intptr_t)&ID) {
DT = new DominatorTreeBase<BasicBlock>(true);
}
diff --git a/include/llvm/Analysis/ScalarEvolution.h b/include/llvm/Analysis/ScalarEvolution.h
index 5894d8c..4d9d5e5 100644
--- a/include/llvm/Analysis/ScalarEvolution.h
+++ b/include/llvm/Analysis/ScalarEvolution.h
@@ -192,7 +192,7 @@ namespace llvm {
void *Impl; // ScalarEvolution uses the pimpl pattern
public:
static char ID; // Pass identification, replacement for typeid
- ScalarEvolution() : FunctionPass((intptr_t)&ID, true), Impl(0) {}
+ ScalarEvolution() : FunctionPass((intptr_t)&ID), Impl(0) {}
/// getSCEV - Return a SCEV expression handle for the full generality of the
/// specified expression.