Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
storage/spanlatch: catch identical upper bound on recomputation durin…
…g removal This change modifies `adjustUpperBoundOnRemoval` to avoid a degenerate case in element removal where all intervals have the same end key. In this case, we would previously adjust the upper bound of every node from the root of the tree to the node that the interval was being removed from. We now check whether removing the element with the largest end key is actually changing the upper bound of the node. If there are other elements with the same end key then this is not the case and we can avoid repeat calls to `adjustUpperBoundOnRemoval` while traversing back up the tree. This came up while profiling a benchmark that was giving suprising results. Release note: None
- Loading branch information