void operator()(GNode src, Galois::UserContext<GNode>& ctx) { for (Graph::edge_iterator ii = graph.edge_begin(src, Galois::ALL), ei = graph.edge_end(src, Galois::ALL); ii != ei; ++ii) { GNode dst = graph.getEdgeDst(ii); Node& ddata = graph.getData(dst, Galois::NONE); if (ddata.component == root) continue; ddata.component = root; mst.push(std::make_pair(src, dst)); ctx.push(dst); } }
void operator()(const GNode& src) const { Node& sdata = graph.getData(src, Galois::NONE); for (Graph::edge_iterator ii = graph.edge_begin(src, Galois::NONE), ei = graph.edge_end(src, Galois::NONE); ii != ei; ++ii) { GNode dst = graph.getEdgeDst(ii); Node& ddata = graph.getData(dst, Galois::NONE); if (sdata.merge(&ddata)) { mst.push(std::make_pair(src, dst)); } else { emptyMerges += 1; } } }
void operator()(GNode item) const { if (graph->getData(item, Galois::NONE).isBad()) wl.push(item); }