[webkit-dev] On adding 'console.memory' API (and about the whole 'console' object.)

Mike Marchywka marchywka at hotmail.com
Sat May 29 17:26:17 PDT 2010







________________________________
> Date: Sat, 29 May 2010 17:02:52 -0700
> From: sam.weinig at gmail.com
> To: mnaganov at chromium.org
> CC: pfeldman at google.com; webkit-dev at lists.webkit.org
> Subject: Re: [webkit-dev] On adding 'console.memory' API (and about the whole 'console' object.)
>
> In general, hassle should not be used as a rationale for API design :). Another question ,if the browser has multiple heaps, should it report the combined memory use by all the heaps or just the heap used by the page the memory object is coming from?
>


I've got a real world situation where I have a browser response
time problem that appears to be due to virtual memory thrashing. If
I open many windows of iceweasel on debian with 1G ( 768 after video buffer),
and then try to do anything simple, like get the address bar to drop down
or type a form like hotmail email, I more often get a solid
disk light for up to a minute or more before getting any response on the 
screen. If I was going to try to fix this, I'd probably be more concerned
about page faults than gross memory usage but both are important. 

If you are going to provide information for optimizing response time ( I'm
not just talking about miliseconds but rather minutes due to disk IO), 
and not just finding leaks, it might be nice to have some information
on page faults etc. Now it could turn out the VM issue is purely due to a
memory leak and once objects are deleted then this problem will go
away but it is a more general concern. Timing results along
with page faults would be great. 

>
> -Sam
>
> On Sat, May 29, 2010 at 12:48 PM, Mikhail Naganov> wrote:
>
> You mean I should create an .idl description for it? That's not a
>
> problem. Using a vanilla JS object just seemed easier to me, because
>
> adding a new .idl file involves much hassle due to the need of
>
> registering it in a half dozen project files.
>
>
>
> On Sat, May 29, 2010 at 19:44, Sam Weinig> wrote:
>
>> Why does this API use a vanilla JS object for the memory object rather than
>
>> an interface as we do with pretty much every other API?
>
>> -Sam
>
>>
>
>>
>
>> On Fri, May 28, 2010 at 10:50 AM, Mikhail Naganov>
>
>> wrote:
>
>>>
>
>>> Greetings, WebKit deveopers,
>
>>>
>
>>> As a response to requests from web apps developers, I was intended to
>
>>> add a simple API for accessing web app's memory consumption, see
>
>>> https://bugs.webkit.org/show_bug.cgi?id=39646
>
>>>
>
>>> The scenario of using this API is as follows:
>
>>> - a builbot runs web app's common usage scenarios tests;
>
>>> - inside tests, memory usage is recorded via the API proposed;
>
>>> - the results are sent to a server (using XHR or a CGI request);
>
>>> - server plots nice graphs of memory usage status, bound to the
>
>>> changes made to the web app;
>
>>> - thus, if someone does a change that blows up memory usage,
>
>>> developers will notice.
>
>>>
>
>>> As Sam points out, this change may be fine, but he suggests to make it
>
>>> accessible only when a browser runs in a special "developer" mode.
>
>>> This can also be applied to the whole 'console' object.
>
>>>
>
>>> Please, share your thoughts on this.
>
>>
>
>>
>
>
 		 	   		  
_________________________________________________________________
The New Busy think 9 to 5 is a cute idea. Combine multiple calendars with Hotmail. 
http://www.windowslive.com/campaign/thenewbusy?tile=multicalendar&ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_5


More information about the webkit-dev mailing list