Re:Modernizing the DOM Tree in Microsoft Edge
by jdmichal on Wednesday April 19, 2017 @04:58PM
(#14151709)
Right. If you don't cache the ordinal, than "next sibling" and "previous sibling" operations have to scan the array.
But it's a relatively easy performance enhancement to have a validity flag for the ordinals, and only rewrite them when a read requires them. That way, write-heavy workloads won't be punished.
And yes, this was essentially my question. What are the realistic numbers in either scenario.