MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / find_father

Method find_father

imperative/src/impl/interpreter/interpreter_impl.cpp:1682–1690  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1680}
1681
1682std::shared_ptr<DsuNode> ChannelImpl::DynamicSublinear::find_father(
1683 std::shared_ptr<DsuNode>& x) {
1684 if (x->is_root()) {
1685 return x;
1686 } else {
1687 auto&& fa = find_father(x->parent);
1688 return x->parent = fa;
1689 }
1690}
1691
1692void ChannelImpl::DynamicSublinear::insert_candidate(TensorInfo* ptr) {
1693 // tensor to be inserted must be brand new

Callers

nothing calls this directly

Calls 1

is_rootMethod · 0.45

Tested by

no test coverage detected