Status: New
Owner: ----
New issue 2479 by [email protected]: Object is not being collected
when it was passed as an argument to a function that is still alive (under
unclear other circumstance)
http://code.google.com/p/v8/issues/detail?id=2479
Detailed description of the issue.
1. Go to http://jsfiddle.net/KAjfY/72/
2. Hit Create leak
3. Make a heap snapshot
4. There're alive object of class Child which should not be alive.
It will not be there forever, in may go away after you click button again,
but the new object will appear and will not be collected. There can be
several of them.
To give the idea of how bad can it go, here's heavier setup
http://jsfiddle.net/KAjfY/68/ Clicking several times may lead up to 37 Mb
of heap consumption. In the real application it can be even worse.
Another reproduction can be found here. http://jsfiddle.net/KAjfY/73/
Retains path goes through global function heavyCtrl here.
This may not work for the first time, but it definitely leaks after several
tries.
The issue is relevant for both current stable Chrome (23.0.1271.101) and
developer (25.0.1364.26 dev).
This http://jsfiddle.net/KAjfY/68/ easily reproduces the issue even with
run with --noopt.
See some of retain paths attached. It seems that they all connects the
leaked object with a function where it was passed as an argument.
If there any known workarounds, I will also appreciate this.
Attachments:
Screen Shot 2013-01-10 at 6.28.30 PM.png 86.0 KB
Screen Shot 2013-01-10 at 6.30.06 PM.png 96.5 KB
Screen Shot 2013-01-10 at 6.38.02 PM.png 44.2 KB
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev