- From: Boris Zbarsky <bzbarsky@MIT.EDU>
- Date: Mon, 07 Jul 2014 21:47:47 -0400
- To: whatwg@lists.whatwg.org
On 7/7/14, 6:58 PM, Brian M. Blakely wrote: > I am not a browser developer, I am a Web developer, but it stands to reason that (as stated in the OP) there may at least be a fruitful memory savings I just measured in Firefox 30, and a bare-bones document (about:blank) uses approximately 550KB of memory. This breaks down as about: * 330KB of JS heap (which presumably would be there anyway for your special document), * 10KB DOM data structures * 210KB layout data (mostly style data, looks like). So you could plausibly save about 220KB of memory. I encourage you to do similar measurements in other browsers as desired. For comparison, a 320x426 canvas (and I doubt you're going to be using ones smaller than that in this special mode) will have a backing store that takes about 545KB for a 2D canvas. The sort of devices where you're likely to actually use WebGL will probably have 4MB+ canvas backing stores, and probably comparable for WebGL. > On the memory front, this could be especially useful when sharing space with the 30+ tabs That would translate into a savings of about 7MB. Not nothing, but just to put that in perspective simply loading http://code.jquery.com/jquery-1.11.1.min.js into those blank tabs above makes them use 1.43MB of memory instead of 550KB. That's without _doing_ anything; just loading the library. So I suspect in practice the script state and canvas backing stores in those 30+ tabs would totally swamp the 7MB of layout/DOM data. -Boris
Received on Tuesday, 8 July 2014 01:48:15 UTC