26 assert(NumClasses == 0 &&
"grow() called after compress().");
33 assert(NumClasses == 0 &&
"join() called after compress().");
54 assert(NumClasses == 0 &&
"findLeader() called after compress().");
63 for (
unsigned i = 0, e = EC.
size();
i != e; ++
i)
64 EC[
i] = (EC[
i] ==
i) ? NumClasses++ : EC[EC[
i]];
71 for (
unsigned i = 0, e = EC.
size();
i != e; ++
i)
72 if (EC[
i] < Leader.
size())
73 EC[
i] = Leader[EC[
i]];
void push_back(const T &Elt)
void grow(unsigned N)
grow - Increase capacity to hold 0 .
void compress()
compress - Compress equivalence classes by numbering them 0 .
void reserve(size_type N)
void uncompress()
uncompress - Change back to the uncompressed representation that allows editing.
unsigned join(unsigned a, unsigned b)
Join the equivalence classes of a and b.
unsigned findLeader(unsigned a) const
findLeader - Compute the leader of a's equivalence class.
LLVM_ATTRIBUTE_ALWAYS_INLINE size_type size() const
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())