15#ifndef LLVM_ADT_SETOPERATIONS_H
16#define LLVM_ADT_SETOPERATIONS_H
22template <
class S1Ty,
class S2Ty>
26 for (
typename S2Ty::const_iterator
SI = S2.begin(), SE = S2.end();
28 if (S1.insert(*SI).second)
39template <
class S1Ty,
class S2Ty>
41 for (
typename S1Ty::iterator
I = S1.begin();
I != S1.end();) {
44 if (!S2.count(
E)) S1.erase(
E);
50template <
class S1Ty,
class S2Ty>
53 for (
typename S1Ty::const_iterator
SI = S1.begin(), SE = S1.end();
62template <
class S1Ty,
class S2Ty>
64 for (
typename S2Ty::const_iterator
SI = S2.begin(), SE = S2.end();
71template <
class S1Ty,
class S2Ty>
73 if (S1.size() > S2.size())
75 for (
const auto It : S1)
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
This is an optimization pass for GlobalISel generic memory operations.
void set_intersect(S1Ty &S1, const S2Ty &S2)
set_intersect(A, B) - Compute A := A ^ B Identical to set_intersection, except that it works on set<>...
bool set_is_subset(const S1Ty &S1, const S2Ty &S2)
set_is_subset(A, B) - Return true iff A in B
void set_subtract(S1Ty &S1, const S2Ty &S2)
set_subtract(A, B) - Compute A := A - B
bool set_union(S1Ty &S1, const S2Ty &S2)
set_union(A, B) - Compute A := A u B, return whether A changed.
S1Ty set_difference(const S1Ty &S1, const S2Ty &S2)
set_difference(A, B) - Return A - B