diff options
author | Glenn Morris <rgm@gnu.org> | 2012-11-20 20:52:03 -0500 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2012-11-20 20:52:03 -0500 |
commit | b6729a180f4b81ac26bd7b61f5330643b2d5e994 (patch) | |
tree | 7601c6f535547bd214c73dd0ce68ab0a1fcf79c8 /doc/lispref | |
parent | 38a2f91778682f903416137d36bab29251dd1db2 (diff) | |
download | emacs-b6729a180f4b81ac26bd7b61f5330643b2d5e994.tar.gz |
Add a bit more about profiling to the lispref
* doc/lispref/debugging.texi (Profiling):
Add some basic information about the profile report buffer.
(Debugging): Mention profiling in the introduction.
Diffstat (limited to 'doc/lispref')
-rw-r--r-- | doc/lispref/ChangeLog | 4 | ||||
-rw-r--r-- | doc/lispref/debugging.texi | 19 |
2 files changed, 19 insertions, 4 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index cda6ed27837..b5bbd8ef93f 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,6 +1,8 @@ 2012-11-21 Glenn Morris <rgm@gnu.org> - * debugging.texi (Profiling) [!tex]: Mention --enable-profiling. + * debugging.texi (Profiling): Mention --enable-profiling (if !tex). + Add some basic information about the profile report buffer. + (Debugging): Mention profiling in the introduction. 2012-11-20 Glenn Morris <rgm@gnu.org> diff --git a/doc/lispref/debugging.texi b/doc/lispref/debugging.texi index ef1342ea289..3439a8ae152 100644 --- a/doc/lispref/debugging.texi +++ b/doc/lispref/debugging.texi @@ -32,6 +32,9 @@ program. @item You can use the ERT package to write regression tests for the program. @xref{Top,the ERT manual,, ERT, ERT: Emacs Lisp Regression Testing}. + +@item +You can profile the program to get hints about how to make it more efficient. @end itemize Other useful tools for debugging input and output problems are the @@ -834,10 +837,20 @@ generate another report later on without erasing previous results. When you have finished profiling, type @kbd{M-x profiler-stop} (there is a small overhead associated with profiling). -@c FIXME -@c Basic apperance of the report buffer: +The profiler report buffer shows, on each line, a function that was +called, followed by how much resource (processor or memory) it used in +absolute and percentage times since profiling started. If a given +line has a @samp{+} symbol at the left-hand side, you can expand that +line by typing @key{RET}, in order to see the function(s) called by +the higher-level function. Pressing @key{RET} again will collapse +back to the original state. + +Press @kbd{j} or @kbd{mouse-2} to jump to the definition of a function. +Press @kbd{d} to view a function's documentation. +You can save a profile to a file using @kbd{C-x C-w}. +You can compare two profiles using @kbd{=}. -@c The following commands are available in the report buffer: +@c FIXME reversed calltree? @cindex @file{elp.el} @cindex timing programs |