From: npostavs@users.sourceforge.net
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: 13455@debbugs.gnu.org
Subject: bug#13455: 24.2.91; profiler.el: missing documentation, menu stuff etc
Date: Sun, 17 Jul 2016 01:14:16 -0400 [thread overview]
Message-ID: <8737n8ethz.fsf@users.sourceforge.net> (raw)
In-Reply-To: <87vcaxc2vo.fsf@web.de> (Michael Heerdegen's message of "Wed, 16 Jan 2013 02:50:35 +0100")
[-- Attachment #1: Type: text/plain, Size: 1020 bytes --]
tags 13455 patch
quit
Michael Heerdegen <michael_heerdegen@web.de> writes:
> (1) Add the main commands to the Emacs-Lisp -> Profiling menu
> (presumably into a new submenu), so that people can find it.
It seems this was added in 24.4.
>
> (2) Missing commentary header. At least say that it's documented in the
> elisp manual.
There is now a comment pointing to the manual.
>
> (4) Add a menu for the profiler report.
As mentioned by Glenn, this is also present.
>
> (3) "If a given line has a `+' symbol at the left-hand side, you can
> expand that line by typing <RET>, in order to see the function(s) called
> by the higher-level function. Pressing <RET> again will collapse back
> to the original state."
>
> Why not make mouse-1 do this, too?
This is still not the case, though it's easy enough to add. Also, I'd
like to add mention of prefix arg for profiler-report-toggle-entry, I
was about make a feature request for an expand-all command, until I
realized this already worked. Here's a patch:
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: patch --]
[-- Type: text/x-diff, Size: 2363 bytes --]
From c0100625ce2ab45f6980a221a02c7fc106818218 Mon Sep 17 00:00:00 2001
From: Noam Postavsky <npostavs@gmail.com>
Date: Sun, 17 Jul 2016 00:21:42 -0400
Subject: [PATCH v1] Make profiler a bit friendier.
* doc/lispref/debugging.texi (Profiling):
* lisp/profiler.el (profiler-report-toggle-entry): Document use of
prefix argument to expand whole call trees.
(profiler-report-mode-map): Add mouse-1 binding for
profiler-report-toggle-entry (Bug #13455).
---
doc/lispref/debugging.texi | 5 +++--
lisp/profiler.el | 4 +++-
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/doc/lispref/debugging.texi b/doc/lispref/debugging.texi
index 98c4705..2f83b40 100644
--- a/doc/lispref/debugging.texi
+++ b/doc/lispref/debugging.texi
@@ -840,8 +840,9 @@ Profiling
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.
+the higher-level function. Use a prefix argument (@key{C-u RET}) to
+see the whole call tree below a 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.
diff --git a/lisp/profiler.el b/lisp/profiler.el
index 401cae5..dac42fe 100644
--- a/lisp/profiler.el
+++ b/lisp/profiler.el
@@ -534,6 +534,7 @@ profiler-report-mode-map
(define-key map "\r" 'profiler-report-toggle-entry)
(define-key map "\t" 'profiler-report-toggle-entry)
(define-key map "i" 'profiler-report-toggle-entry)
+ (define-key map [mouse-1] 'profiler-report-toggle-entry)
(define-key map "f" 'profiler-report-find-entry)
(define-key map "j" 'profiler-report-find-entry)
(define-key map [mouse-2] 'profiler-report-find-entry)
@@ -692,7 +693,8 @@ profiler-report-collapse-entry
(defun profiler-report-toggle-entry (&optional arg)
"Expand entry at point if the tree is collapsed,
-otherwise collapse."
+otherwise collapse. With prefix argument, expand all subentries
+below entry at point."
(interactive "P")
(or (profiler-report-expand-entry arg)
(profiler-report-collapse-entry)))
--
2.8.0
next prev parent reply other threads:[~2016-07-17 5:14 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-16 1:50 bug#13455: 24.2.91; profiler.el: missing documentation, menu stuff etc Michael Heerdegen
2013-01-20 2:42 ` Glenn Morris
2013-01-20 4:17 ` Michael Heerdegen
2016-07-17 5:14 ` npostavs [this message]
2016-07-19 23:42 ` Michael Heerdegen
2016-07-29 0:15 ` npostavs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8737n8ethz.fsf@users.sourceforge.net \
--to=npostavs@users.sourceforge.net \
--cc=13455@debbugs.gnu.org \
--cc=michael_heerdegen@web.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).