subtree cleanup