Avoid redundant hash calculations in CustomElementUpgradeSorter
Pointed out by tkent in https://codereview.chromium.org/2242743002/ The original code could do 2 hash calculations for adding a new key-value pair to ParentChildMap (for find() and add()), and rehashing the map may involve copying the HeapHashSet<Member<Node>> objects. Change the value part of ParentChildMap from a HeapHashMap object to its pointer, to avoid redundant hash calculation and object copy. This does not change any functionality of the class. BUG=594918 Review-Url: https://codereview.chromium.org/2290543002 Cr-Commit-Position: refs/heads/master@{#415251}
Showing
Please register or sign in to comment