* Eliminate the LiveVarSet class, making applyTranferFuncForMInst a static
function in the one .cpp file that uses it. Use ValueSet's instead.
* Prepare to delete LiveVarSet.h & LiveVarSet.cpp
* Eliminate the ValueSet class, making all old member functions into global
templates that will eventually be moved to Support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1711 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/LiveVar/ValueSet.cpp b/lib/Analysis/LiveVar/ValueSet.cpp
index 431ccc6..88dd25a 100644
--- a/lib/Analysis/LiveVar/ValueSet.cpp
+++ b/lib/Analysis/LiveVar/ValueSet.cpp
@@ -15,28 +15,8 @@
return O << v << " ";
}
-bool ValueSet::setUnion( const ValueSet *S) {
- bool Changed = false;
-
- for (const_iterator SI = S->begin(), SE = S->end(); SI != SE; ++SI)
- if (insert(*SI).second)
- Changed = true;
-
- return Changed;
-}
-
-void ValueSet::setDifference(const ValueSet *S1, const ValueSet *S2) {
- for (const_iterator SI = S1->begin(), SE = S1->end() ; SI != SE; ++SI)
- if (S2->find(*SI) == S2->end()) // if the element is not in set2
- insert(*SI);
-}
-
-void ValueSet::setSubtract(const ValueSet *S) {
- for (const_iterator SI = S->begin() ; SI != S->end(); ++SI)
- erase(*SI);
-}
-
-void ValueSet::printSet() const {
- for (const_iterator I = begin(), E = end(); I != E; ++I)
+void printSet(const ValueSet &S) {
+ for (ValueSet::const_iterator I = S.begin(), E = S.end(); I != E; ++I)
std::cerr << RAV(*I);
}
+