Bug 99186 - Web Inspector: NMI remove hand made object builders with automatic builder
Summary: Web Inspector: NMI remove hand made object builders with automatic builder
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Ilya Tikhonovsky
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-12 09:36 PDT by Ilya Tikhonovsky
Modified: 2012-10-14 23:21 PDT (History)
13 users (show)

See Also:


Attachments
Patch (16.07 KB, patch)
2012-10-12 09:43 PDT, Ilya Tikhonovsky
no flags Details | Formatted Diff | Diff
Patch (16.11 KB, patch)
2012-10-13 09:19 PDT, Ilya Tikhonovsky
yurys: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ilya Tikhonovsky 2012-10-12 09:36:42 PDT
Our ObjectType to size map handles a map between pointers to strings like "MemoryCache.Image" and the corresponding allocated size.
The builders fetch the data and creates hierarchical structure.
This solution is not scalable solution. I'd like to add another types and need to implement additional builders.
Comment 1 Ilya Tikhonovsky 2012-10-12 09:43:25 PDT
Created attachment 168439 [details]
Patch
Comment 2 Build Bot 2012-10-12 11:46:21 PDT
Comment on attachment 168439 [details]
Patch

Attachment 168439 [details] did not pass mac-ews (mac):
Output: http://queues.webkit.org/results/14282043

New failing tests:
inspector/profiler/memory-instrumentation-cached-images.html
Comment 3 WebKit Review Bot 2012-10-12 12:09:29 PDT
Comment on attachment 168439 [details]
Patch

Attachment 168439 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/14278051

New failing tests:
inspector/profiler/memory-instrumentation-canvas.html
inspector/profiler/memory-instrumentation-cached-images.html
Comment 4 Build Bot 2012-10-12 12:46:22 PDT
Comment on attachment 168439 [details]
Patch

Attachment 168439 [details] did not pass mac-ews (mac):
Output: http://queues.webkit.org/results/14262594

New failing tests:
inspector/profiler/memory-instrumentation-cached-images.html
Comment 5 Ilya Tikhonovsky 2012-10-13 09:19:19 PDT
Created attachment 168556 [details]
Patch
Comment 6 Yury Semikhatsky 2012-10-14 23:11:39 PDT
Comment on attachment 168556 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=168556&action=review

> Source/WebCore/inspector/InspectorMemoryAgent.cpp:126
> +        if (objectType.endsWith(".used", false))

Can we check if the parent block already exists and contains size value? Or better always sum up children sizes.

> Source/WebCore/inspector/MemoryInstrumentationImpl.cpp:43
> +    // TypeToSizeMap uses const char* as the key.

You should probably note that we compare pointers not strings and use hash for pointer not string.
Comment 7 Ilya Tikhonovsky 2012-10-14 23:21:35 PDT
Committed r131290: <http://trac.webkit.org/changeset/131290>