On Mon, Jan 4, 2016 at 6:16 AM, Matt Esch <[email protected]> wrote: > Hi, > > I'm trying to implement flame graph support using v8's cpu profiler. The > flame graph tool needs to do a full backtrace including non-js frames and > provide the symbols for the frames generated by v8. > > I've been taking a look into how the cpu profiler works. Essentially it > comprises of a cross-platform ticker/stack walker and a cpu profile > generator. For my needs the aggregated data in the cpu profile doesn't have > enough information (or I misunderstand what is logged here). I know that v8 > is taking backtraces. We don't get backtraces for every sample, for example, > if there is currently no js entry frame or if we are currently in GC, but > for the most part v8 is actually collecting full backtraces on an interval. > > What I am looking to do is to manually handle the cpu-profiler samples so I > can build a flame graph. I just want each raw backtrace with the C++ and js > frames left in tact. Ideally I want to see the v8 GC frames too but I'd like > to start with being able to dump each raw stack frame with annotations for > the javascript frames. > > For any of you who might have some experience with the profiler, do you > have any recommendations for how to go about doing this? > > ~Matt
When you say "the CPU profiler" do you mean the --prof command line switch or the programmatic API from include/v8-profiler.h? Tools to post-process the output of the former into flame graphs exist; e.g. `--prof --track_gc_object_stats --trace_gc_verbose --log_timer_events` produces output suitable for Chromium's chrome://tracing tool. -- -- 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/d/optout.
