Subject: bug#22114: 24.5; [PATCH] Allow profiler.el to display reports after stopping

From: Vasilij Schneidermann <[email-masked]>
Date: Mon, 14 Dec 2015 19:23:21 +0100

> What are the other aspects that worry you?

If you perform `M-x profiler-report` while the profiler is still
running, every time you do the report, the profiler is reset.  This can
be easily observed by starting it, performing an intensive computation,
viewing the report, then viewing it again after a short while.  The
second report has a lower number of CPU cycles/memory usage.  This isn't
really helpful.  Preserving the profiler status on the other hand would
be because you could then take a look at the usage throughout the stages
of an interesting computation, then later stop it to freeze its status
and inspect the final report.  My elisp-only patch achieves the latter,
the patch involving C however does the former as well.

The only remaining thing I'd need to figure out is how to incorporate a
reset function as profiler.el relies on accessing a log to reset the
profiler...