X-Git-Url: http://plrg.eecs.uci.edu/git/?p=oota-llvm.git;a=blobdiff_plain;f=include%2Fllvm%2FAnalysis%2FSparsePropagation.h;h=2c7f5dd73547e993c7a9b5d77e79bc81aae4bcf0;hp=7841dc26a1b25fb1ecf7758b89ec41f0fea83b44;hb=74e437e7b1e30e86d453fb2317800b418d0290fd;hpb=c31dc2ec76e7f9c7ee75761a80f5090f9dfc8ca2 diff --git a/include/llvm/Analysis/SparsePropagation.h b/include/llvm/Analysis/SparsePropagation.h index 7841dc26a1b..2c7f5dd7354 100644 --- a/include/llvm/Analysis/SparsePropagation.h +++ b/include/llvm/Analysis/SparsePropagation.h @@ -21,18 +21,18 @@ #include namespace llvm { - class Value; - class Constant; - class Argument; - class Instruction; - class PHINode; - class TerminatorInst; - class BasicBlock; - class Function; - class SparseSolver; - class raw_ostream; - - template class SmallVectorImpl; +class Value; +class Constant; +class Argument; +class Instruction; +class PHINode; +class TerminatorInst; +class BasicBlock; +class Function; +class SparseSolver; +class raw_ostream; + +template class SmallVectorImpl; /// AbstractLatticeFunction - This class is implemented by the dataflow instance /// to specify what the lattice values are and how they handle merges etc. @@ -64,9 +64,7 @@ public: /// IsUntrackedValue - If the specified Value is something that is obviously /// uninteresting to the analysis (and would always return UntrackedVal), /// this function can return true to avoid pointless work. - virtual bool IsUntrackedValue(Value *V) { - return false; - } + virtual bool IsUntrackedValue(Value *V) { return false; } /// ComputeConstant - Given a constant value, compute and return a lattice /// value corresponding to the specified constant. @@ -76,9 +74,7 @@ public: /// IsSpecialCasedPHI - Given a PHI node, determine whether this PHI node is /// one that the we want to handle through ComputeInstructionState. - virtual bool IsSpecialCasedPHI(PHINode *PN) { - return false; - } + virtual bool IsSpecialCasedPHI(PHINode *PN) { return false; } /// GetConstant - If the specified lattice value is representable as an LLVM /// constant value, return it. Otherwise return null. The returned value @@ -120,12 +116,12 @@ class SparseSolver { /// compute transfer functions. AbstractLatticeFunction *LatticeFunc; - DenseMap ValueState; // The state each value is in. - SmallPtrSet BBExecutable; // The bbs that are executable. + DenseMap ValueState; // The state each value is in. + SmallPtrSet BBExecutable; // The bbs that are executable. - std::vector InstWorkList; // Worklist of insts to process. + std::vector InstWorkList; // Worklist of insts to process. - std::vector BBWorkList; // The BasicBlock work list + std::vector BBWorkList; // The BasicBlock work list /// KnownFeasibleEdges - Entries in this set are edges which have already had /// PHI nodes retriggered. @@ -137,10 +133,8 @@ class SparseSolver { public: explicit SparseSolver(AbstractLatticeFunction *Lattice) - : LatticeFunc(Lattice) {} - ~SparseSolver() { - delete LatticeFunc; - } + : LatticeFunc(Lattice) {} + ~SparseSolver() { delete LatticeFunc; } /// Solve - Solve for constants and executable blocks. ///