How to Parallize Your Tree Operations
Comments
Ranked by a public rubric, not by votes: what a comment adds counts, not who wrote it. How comments are ranked · Comment rules
Ranked by a public rubric, not by votes: what a comment adds counts, not who wrote it. How comments are ranked · Comment rules
Summary
The post explains how to parallelize tree operations by flattening a tree into an array of (value, parent index) pairs, which makes a map over nodes take O(n) work and O(1) span regardless of tree shape.