Tkanks for reply, I said 9 times and 2 times because of I add the "--trace_gc" and "--trace_gc_verbose" v8 will print 9 or 2 messages, not the breakpoint trigged how many times though the breakpoint triggered twice indeed.
在 2013年8月7日星期三UTC+8下午7时02分37秒,Ben Noordhuis写道: > > On Wed, Aug 7, 2013 at 10:49 AM, <[email protected] <javascript:>> wrote: > > > > I used "gdb --args ../out/ia32.debug/d8 --trace_gc > --trace_gc_verbose > > run.js" and "r" > > > > to run the benchmark without any breakpoint, the gc will be > triggered 9 > > times(all in the newspace). > > > > but if I set a breakpoint at Heap::CollectGarbage where I think is > the > > gc's entry point, and "c" to complete the benchmark the gc just only > > triggered 2 times( in the newspace) > > > > why? thank you. > > There is more than one Heap::CollectGarbage() method. It's possible > you set a breakpoint on one but not the other. > > Besides that, there's also Heap::CollectAllGarbage() and maybe others. > > Maybe Heap::GarbageCollectionPrologue() is a better place to intercept > things, I think it's called for both scavenges and full GC. > -- -- 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.
