Compute the (reduced) set of children of node i in this graph. * * This returns the minimal subset of the children of i whose descendants together equal all of * i's descendants (unless i is part of a cycle of dependencies). Note that DepGraph does not * store the set of children; this information is inferred from the descendant sets. * * Complexity: O(N) where N=Desc
| 230 | * Complexity: O(N) where N=Descendants(i).Count() (which is bounded by TxCount()). |
| 231 | */ |
| 232 | SetType GetReducedChildren(DepGraphIndex i) const noexcept |
| 233 | { |
| 234 | SetType children = Descendants(i); |
| 235 | children.Reset(i); |
| 236 | for (auto child : children) { |
| 237 | if (children[child]) { |
| 238 | children -= Descendants(child); |
| 239 | children.Set(child); |
| 240 | } |
| 241 | } |
| 242 | return children; |
| 243 | } |
| 244 | |
| 245 | /** Compute the aggregate feerate of a set of nodes in this graph. |
| 246 | * |