isInert does a tree traversal for the inert attribute. One possible optimization is to add a flag on Document saying whether a node with an inert attribute has ever been used and only do the traversal in the case. One thing to be careful of is nodes potentially moving documents.
<rdar://problem/82529669>
Bug 229330 removes the tree traversal for most parts. *** This bug has been marked as a duplicate of bug 229330 ***