Closed GoogleCodeExporter closed 9 years ago
Please edit the subject to "Feature request: expose API to record stacktraces".
Original comment by mohit.a...@gmail.com
on 16 Nov 2009 at 2:35
Can you clarify a bit what API you had in mind? perftools has no "way" of
recording
stacktraces so that pprof can read them; if you look at
doc/cpuprofile-fileformat.html and a heap profile output file, you'll see the
two
different formats we use for those two applications. I'm not sure there can be
a way
of just recording stacktraces; the traces themselves are meaningless without
some
application-specific data associated with them.
Perhaps your best way forward would be to look at how we encode existing data,
either
in the cpu profiler or the heap profiler, and try to write something equivalent
for
an application you'd like (thread contention, perhaps). That might serve as a
good
way to start thinking about this problem, and what generalizations might make
sense
for it.
Original comment by csilv...@gmail.com
on 16 Nov 2009 at 4:04
I'm thinking that perftools can provide an API that takes in an object that has
methods for emitting extra data in a binary profile record and for reading it
back.
Such an object might be subclassed from an abstract class that perftools can
define.
This takes care of outputting and reading back the extra data that only the
application understands. Thus perftools will emit the stacktraces along with
this
extra application specific data using this method.
The code that interprets these binary records and emits out graphs can
similarly take
in user-defined functions or objects to do the needful.
Original comment by mohit.a...@gmail.com
on 16 Nov 2009 at 6:00
Ok, I think the best plan of attack is for you to propose a patch, and we can
go from
there. Ideally, the patch would include an actual user of this code so we can
see
how it works in practice.
Original comment by csilv...@gmail.com
on 16 Nov 2009 at 4:35
Ok - I can work on that. But I may not be able to get to it soon.
Original comment by mohit.a...@gmail.com
on 16 Nov 2009 at 4:51
Any more word on this?
Original comment by csilv...@gmail.com
on 2 Aug 2010 at 4:52
> Any more word on this?
Sorry - no progress on this. It'll be really great if someone else can take
this up - I myself am involved in a startup and probably won't have time for
this at least this year.
Original comment by mohit.a...@gmail.com
on 2 Aug 2010 at 4:56
It's a year later, so I'm going to close this WillNotFix. Feel free to reopen
if you'd like to draw up a patch.
Original comment by csilv...@gmail.com
on 31 Aug 2011 at 10:15
Original issue reported on code.google.com by
mohit.a...@gmail.com
on 16 Nov 2009 at 2:34