Bug 13359 - Feature request: Tool for tracking down javascript object allocations
Summary: Feature request: Tool for tracking down javascript object allocations
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 523.x (Safari 3)
Hardware: Mac OS X 10.4
: P2 Enhancement
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-16 03:41 PDT by Jonathan del Strother
Modified: 2016-04-28 17:07 PDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan del Strother 2007-04-16 03:41:41 PDT
I'm working on a fairly complex javascript application at the moment, which is gaining 600 objects on each xhr request.  I'm really struggling to find out where those objects are coming from.
Hopefully I'll have fixed this by the time this feature request is fulfilled, but for those that might struggle with this in future : 

It would be incredibly helpful if there was a debugging tool that would show a report of javascript objects created between two time points, and show what objects reference them.  Something along the lines of ObjectAlloc would be perfect.  I'm not aware of such a tool on any browser - it would be a great asset to js developers.
Comment 1 Joseph Pecoraro 2016-04-28 17:07:26 PDT
Heap Snapshots are now available in the JavaScript Allocations Timeline in Web Inspector. It allows you to take snapshots which record some info about all JavaScript objects, and then comparisons let you investigate objects created between two points in time. You can also view outward references and the shortest path from a GC Root to the object.

Try it out in WebKit Nightlies or the Safari Technology Preview:
<https://webkit.org/downloads/>

Please file enhancement requests or report any issues you find!