summaryrefslogtreecommitdiff
path: root/include/llvm/Analysis/IntervalPartition.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-08-09 22:52:06 +0000
committerChris Lattner <sabre@nondot.org>2002-08-09 22:52:06 +0000
commit89f2aa5fd8125b67e4759a9342002c7f99a64751 (patch)
treefffb15d2ef32a9ba17755b1f60d0e8635a0c76ff /include/llvm/Analysis/IntervalPartition.h
parentcc367a3ea0d593aa1f70305316d3290dcf4bda02 (diff)
downloadllvm-89f2aa5fd8125b67e4759a9342002c7f99a64751.tar.gz
llvm-89f2aa5fd8125b67e4759a9342002c7f99a64751.tar.bz2
llvm-89f2aa5fd8125b67e4759a9342002c7f99a64751.tar.xz
* IntervalPartition no longer derives from vector
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3281 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/IntervalPartition.h')
-rw-r--r--include/llvm/Analysis/IntervalPartition.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/include/llvm/Analysis/IntervalPartition.h b/include/llvm/Analysis/IntervalPartition.h
index a295ce1034..197c469db9 100644
--- a/include/llvm/Analysis/IntervalPartition.h
+++ b/include/llvm/Analysis/IntervalPartition.h
@@ -27,12 +27,13 @@
// BasicBlock is a (possibly nonexistent) loop with a "tail" of non looping
// nodes following it.
//
-class IntervalPartition : public FunctionPass, public std::vector<Interval*> {
+class IntervalPartition : public FunctionPass {
typedef std::map<BasicBlock*, Interval*> IntervalMapTy;
IntervalMapTy IntervalMap;
typedef std::vector<Interval*> IntervalListTy;
Interval *RootInterval;
+ std::vector<Interval*> Intervals;
public:
static AnalysisID ID; // We are an analysis, we must have an ID
@@ -60,7 +61,7 @@ public:
// isDegeneratePartition() - Returns true if the interval partition contains
// a single interval, and thus cannot be simplified anymore.
- bool isDegeneratePartition() { return size() == 1; }
+ bool isDegeneratePartition() { return Intervals.size() == 1; }
// TODO: isIrreducible - look for triangle graph.
@@ -75,6 +76,9 @@ public:
AU.setPreservesAll();
}
+ // Interface to Intervals vector...
+ const std::vector<Interval*> &getIntervals() const { return Intervals; }
+
private:
// destroy - Reset state back to before function was analyzed
void destroy();