There is no direct way to get statistics about the objects are that are collected, but you may be able to infer this information by looking at the delta between live object counts between two GCs. You can track live object counts by passing the --track_gc_object_stats flag to V8, which records total live object counts and sizes per type during each marking phase of the garbage collector. By using --dump_counters you can print the counters when the d8 shell exits, or in chromium you can use the --enable-stats-table option (probably --nosandbox too) and visiting the chrome://stats/ page (this way you can see inspect objects count while running your app).
Danno On Tue, Jun 11, 2013 at 12:45 AM, <[email protected]> wrote: > Is there a way to get stats about how many instances of a specific > Javascript class are being garbage collected? --trace-gc does not provide > that much details. > > Specifically there is a specific Javascript class that is instantiated > multiple times in my app. I want to verify that this could be the cause of > the observed very frequent > garbage collection, before taking any action to reduce such allocations in > the code. > > Thank you, > Demetrios > > -- > -- > v8-users mailing list > [email protected] > http://groups.google.com/group/v8-users > --- > You received this message because you are subscribed to the Google Groups > "v8-users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- -- v8-users mailing list [email protected] http://groups.google.com/group/v8-users --- You received this message because you are subscribed to the Google Groups "v8-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
