vmprof-python icon indicating copy to clipboard operation
vmprof-python copied to clipboard

vmprof ideas - what is next?

Open planrich opened this issue 8 years ago • 5 comments

There are several ideas, this issue summarizes them and encourages discussion:

  • online profiling (or profile streaming)
  • query runtime information. python -m vmprof.stat -p <pid> prints if profiling is enabled, how many bytes have been saved, ...
  • network statistics (like statsd, profiles TCP and UDP timer and counters)

planrich avatar Apr 01 '17 15:04 planrich

We have two new pull requests:

  • "real time profiling"
  • reduce the number of symbols written to profile log

planrich avatar Apr 15 '17 14:04 planrich

  • callgrind output format #115

planrich avatar Apr 15 '17 14:04 planrich

I/O statistics would be pretty handy, and I wouldn't mind giving a hand there - but if we're going to be adding lots of possibly optional information, the file format itself could stand being a bit more generic, kind of like PNG works. In particular it would be useful if starting with 0.5.0, all future versions could just skip over the data they do not understand, without being forced to upgrade.

Runtime information just telling us if profiling is enabled and how it's going seems... marginally useful. What would be more interesting is if we could:

  • Query which file is being written to (so that the client can open it and follow the stream directly)
  • Force flushing the current IP / function names / etc.

The latter part is somewhat important in that currently this is the main piece of information that's not available until profiling is over. If we could get at (portions of) it earlier, online / runtime profiling just reduces to reading the profiling file as it is being written.

bawr avatar Apr 16 '17 15:04 bawr

So, I started some initial work on being able to read the profiling file as it is being written, and it's actually not too bad - the only thing we'd need to have very decent vmprof integration while the program is running would be to have a way to ask the process to write the symbols during runtime, and that shouldn't be hard.

(I'll start a dedicated PR for this once my other PR is resolved and I know what to rebase onto. ;) )

bawr avatar Apr 29 '17 13:04 bawr

Binary distribution of vmprof for people who don't/can't have visual studio installed on their computer?

Cabu avatar Oct 18 '17 08:10 Cabu