diff options
author | Chris Lattner <sabre@nondot.org> | 2002-02-05 02:51:01 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2002-02-05 02:51:01 +0000 |
commit | 5e5dfa307a6999cef7cba6d1a594f880ab72c043 (patch) | |
tree | f57e9d4dd8fb10d74fa747964759e48f86e7ac9d /lib/Target/SparcV9/LiveVar/ValueSet.cpp | |
parent | 0665a5f1f5716a69982f4bcd654e5ace975d0c0a (diff) | |
download | external_llvm-5e5dfa307a6999cef7cba6d1a594f880ab72c043.zip external_llvm-5e5dfa307a6999cef7cba6d1a594f880ab72c043.tar.gz external_llvm-5e5dfa307a6999cef7cba6d1a594f880ab72c043.tar.bz2 |
* 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
Diffstat (limited to 'lib/Target/SparcV9/LiveVar/ValueSet.cpp')
-rw-r--r-- | lib/Target/SparcV9/LiveVar/ValueSet.cpp | 26 |
1 files changed, 3 insertions, 23 deletions
diff --git a/lib/Target/SparcV9/LiveVar/ValueSet.cpp b/lib/Target/SparcV9/LiveVar/ValueSet.cpp index 431ccc6..88dd25a 100644 --- a/lib/Target/SparcV9/LiveVar/ValueSet.cpp +++ b/lib/Target/SparcV9/LiveVar/ValueSet.cpp @@ -15,28 +15,8 @@ ostream &operator<<(ostream &O, RAV V) { // func to print a Value 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); } + |