From: "João Távora" <joaotavora@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: monnier@iro.umontreal.ca, drew.adams@oracle.com, emacs-devel@gnu.org
Subject: Re: Add user customization fido-completion-styles
Date: Tue, 02 Jun 2020 20:11:49 +0100 [thread overview]
Message-ID: <87h7vtl1u2.fsf@gmail.com> (raw)
In-Reply-To: <83h7vtco49.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 02 Jun 2020 21:35:18 +0300")
Eli Zaretskii <eliz@gnu.org> writes:
> What is 'collection'? is it a function?
I suppose it can be, yes.
> Anyway, I suggest to run the same experiment after loading all the
> code involved in this as *.el files (not *.elc). That should show a
> more detailed profile, which hopefully will give a clue.
That did give some clues. When loading minibuffer.el that section
becomes:
- complete-with-action 1125 75%
- cond 1125 75%
- funcall 1125 75%
- all-completions 24 1%
#<compiled 0x15809d82b069> 15 1%
Which shows there's an compiled function coming from somewhere else,
likely simple.el. When I load simple.el, the profile changes
dramatically, and becomes so deep that it's impossivle to read because
M-x profiler-report truncates the names of functions at a certain point.
So then I remembered loading the compiled minibuffer.elc and loading the
uncompiled simple.el, and I got more interesting results, such as these:
- #<compiled 0x15809c619759> 1264 82%
- completion-flex-all-completions 1233 80%
- completion-substring--all-completions 1212 78%
- completion-pcm--all-completions 1209 78%
- all-completions 1209 78%
- #<lambda -0x5acbf46d069cde1> 318 20%
- let 318 20%
- complete-with-action 318 20%
- all-completions 10 0%
- #<lambda -0xded78e903380374> 5 0%
- and 5 0%
funcall 4 0%
- or 1 0%
equal 1 0%
- #<lambda 0xf61f9dacf96321f> 197 12%
- let 197 12%
- complete-with-action 197 12%
- all-completions 7 0%
- #<lambda 0x7121b4e1cc7fc8f> 4 0%
- and 4 0%
funcall 4 0%
- #<lambda 0xf590d1eef96321f> 180 11%
- let 180 11%
- complete-with-action 180 11%
- all-completions 5 0%
- #<lambda 0x7018618bcc7fc8f> 4 0%
- and 4 0%
funcall 4 0%
+ #<lambda 0xf61e0170f96321f> 177 11%
+ #<lambda 0xf61d91a2f96321f> 172 11%
+ #<lambda -0x15745e458069cde1> 165 10%
+ completion-pcm--hilit-commonality 21 1%
Which are still kind of confusing, but at least kinda point to the time
wasters being in simple.el, i.e. in the "client" code of the completions
code, and _not_ in minibuffer.el, where the completion algorithm itself
lives.
But maybe I'm totally mistaken. Stefan is probably the best person to
shed some light here.
João
next prev parent reply other threads:[~2020-06-02 19:11 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-31 21:02 Add user customization fido-completion-styles Andrew Schwartzmeyer
2020-05-31 23:43 ` João Távora
2020-05-31 23:59 ` Dmitry Gutov
2020-06-01 0:21 ` João Távora
2020-06-01 0:37 ` Andrew Schwartzmeyer
2020-06-01 4:37 ` Andrew Schwartzmeyer
2020-06-02 11:14 ` João Távora
2020-06-02 16:14 ` Drew Adams
2020-06-02 17:51 ` João Távora
2020-06-02 18:11 ` Eli Zaretskii
2020-06-02 18:24 ` João Távora
2020-06-02 18:35 ` Eli Zaretskii
2020-06-02 19:11 ` João Távora [this message]
2020-06-02 19:25 ` Eli Zaretskii
2020-06-02 20:00 ` João Távora
2020-06-02 20:51 ` Drew Adams
2020-06-02 15:40 ` Tassilo Horn
2020-06-02 15:55 ` João Távora
2020-06-02 16:47 ` Tassilo Horn
2020-06-02 17:03 ` João Távora
2020-06-02 18:05 ` Tassilo Horn
2020-06-02 17:10 ` Tassilo Horn
2020-06-02 19:28 ` João Távora
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=87h7vtl1u2.fsf@gmail.com \
--to=joaotavora@gmail.com \
--cc=drew.adams@oracle.com \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=monnier@iro.umontreal.ca \
/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).