Summary: | Web Inspector: speed-up markQueriableHeapObjects function. | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Ilya Tikhonovsky <loislo> | ||||
Component: | Web Inspector (Deprecated) | Assignee: | Ilya Tikhonovsky <loislo> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | apavlov, bweinstein, joepeck, keishi, loislo, pfeldman, pmuellr, rik, timothy, yurys | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | All | ||||||
OS: | All | ||||||
Bug Depends on: | |||||||
Bug Blocks: | 87089 | ||||||
Attachments: |
|
Description
Ilya Tikhonovsky
2012-05-17 07:47:38 PDT
Created attachment 142474 [details]
Patch
Comment on attachment 142474 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=142474&action=review > Source/WebCore/inspector/front-end/HeapSnapshot.js:-1180 > - list.push(iter.edge.node.nodeIndex); Please revert this part. > Source/WebCore/inspector/front-end/HeapSnapshot.js:1197 > + ? nodes[nodeIndex + firstEdgeIndexOffset + nodeFieldCount] Please realign these two lines. > Source/WebCore/inspector/front-end/HeapSnapshot.js:1213 > + this._flags = new Uint32Array(this.nodeCount); Does it make any difference? Committed r117545: <http://trac.webkit.org/changeset/117545> (In reply to comment #2) > (From update of attachment 142474 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=142474&action=review > > > Source/WebCore/inspector/front-end/HeapSnapshot.js:-1180 > > - list.push(iter.edge.node.nodeIndex); > > Please revert this part. done > > > Source/WebCore/inspector/front-end/HeapSnapshot.js:1197 > > + ? nodes[nodeIndex + firstEdgeIndexOffset + nodeFieldCount] > > Please realign these two lines. done > > > Source/WebCore/inspector/front-end/HeapSnapshot.js:1213 > > + this._flags = new Uint32Array(this.nodeCount); > > Does it make any difference? This line is the root for the sake of which all the patch has been made. Before the patch the array was sparse. Actually it was a hash map. Now we have no memory overhead and we can make it external. It gives us an additional speed boost and reduces js heap footprint. |