From: "Basil L. Contovounesios" <contovob@tcd.ie>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: Michael Albinus <michael.albinus@gmx.de>,
Stefan Monnier <monnier@iro.umontreal.ca>,
emacs-devel@gnu.org
Subject: Re: master 695f679: Remove ; ; ; ###tramp-autoload cookie from Tramp defcustoms (Bug#47063)
Date: Sat, 27 Mar 2021 01:18:33 +0000 [thread overview]
Message-ID: <878s69pf6e.fsf@tcd.ie> (raw)
In-Reply-To: <87v99d7efl.fsf@gnus.org> (Lars Ingebrigtsen's message of "Fri, 26 Mar 2021 23:11:58 +0100")
[-- Attachment #1: Type: text/plain, Size: 2612 bytes --]
Lars Ingebrigtsen <larsi@gnus.org> writes:
> Hm... I'm not quite sure I understand these benchmarks. There are no
> completion predicates for any eww-* symbols, I think? So there
> shouldn't be any differences here at all, if I read the patch correctly.
Oops, sorry, I conflated completion-predicate with command-modes.
The eww completion is only one half of the benchmark; the rest operates
over all commands in obarray (but less than 1% of those have a
completion-predicate, hence the (failed) attempt to prefilter obarray).
> What I was wondering was -- if (at some point in the future) we have,
> say, 2K symbols with a completion predicate -- would putting that
> condition-case inside the loop make things slower or not? My gut
> feeling says that it's probably not an issue (so we should just go ahead
> and do it), but it'd be nice to know...
Here's the attached benchmark on 16K commands (warning: takes a while):
== TAB RET ==
bench-vanilla-no-pred 3.533359 100 2.058253
bench-vanilla-no-pred 3.531937 100 2.054076
bench-vanilla-no-pred 3.529376 100 2.052615
bench-vanilla-with-pred 3.627937 105 2.127567
bench-vanilla-with-pred 3.616596 105 2.117001
bench-vanilla-with-pred 3.612720 105 2.114463
bench-vanilla-safe-pred 3.639222 105 2.132278
bench-vanilla-safe-pred 3.647615 105 2.134284
bench-vanilla-safe-pred 3.636989 105 2.127953
bench-safe-no-pred 3.573388 100 2.087055
bench-safe-no-pred 3.555347 100 2.069622
bench-safe-no-pred 3.545747 100 2.063041
bench-safe-with-pred 3.653066 105 2.145138
bench-safe-with-pred 3.643867 105 2.140400
bench-safe-with-pred 3.659689 105 2.150498
== b e n c h - TAB C-a C-k RET ==
bench-vanilla-no-pred 0.649064 0 0.000000
bench-vanilla-no-pred 0.652256 0 0.000000
bench-vanilla-no-pred 0.677194 0 0.000000
bench-vanilla-with-pred 1.652515 40 0.750009
bench-vanilla-with-pred 1.653861 40 0.753575
bench-vanilla-with-pred 1.672873 40 0.747151
bench-vanilla-safe-pred 1.669653 40 0.742116
bench-vanilla-safe-pred 1.673809 40 0.743255
bench-vanilla-safe-pred 1.672750 40 0.741095
bench-safe-no-pred 0.646114 0 0.000000
bench-safe-no-pred 0.644843 0 0.000000
bench-safe-no-pred 0.646764 0 0.000000
bench-safe-with-pred 1.672326 40 0.743054
bench-safe-with-pred 1.677331 40 0.742163
bench-safe-with-pred 1.711009 40 0.759025
So condition-case still looks negligible relative to the rest of the
work, and my vote's for putting it around the call to
read-extended-command-predicate.
--
Basil
[-- Attachment #2: bench3.el --]
[-- Type: application/emacs-lisp, Size: 5730 bytes --]
next prev parent reply other threads:[~2021-03-27 1:18 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20210313133546.6042.78482@vcs0.savannah.gnu.org>
[not found] ` <20210313133547.AA06C20B2E@vcs0.savannah.gnu.org>
2021-03-13 22:27 ` master 695f679: Remove ; ; ; ###tramp-autoload cookie from Tramp defcustoms (Bug#47063) Basil L. Contovounesios
2021-03-13 23:20 ` Stefan Monnier
2021-03-14 8:39 ` Michael Albinus
2021-03-14 12:59 ` Basil L. Contovounesios
2021-03-14 14:57 ` Stefan Monnier
2021-03-24 22:19 ` Basil L. Contovounesios
2021-03-25 8:25 ` Michael Albinus
2021-03-26 15:18 ` Basil L. Contovounesios
2021-03-26 15:24 ` Michael Albinus
2021-03-25 9:12 ` Lars Ingebrigtsen
2021-03-25 14:05 ` Stefan Monnier
2021-03-26 11:28 ` Lars Ingebrigtsen
2021-03-26 13:39 ` Stefan Monnier
2021-03-26 14:42 ` Michael Albinus
2021-03-26 18:39 ` Basil L. Contovounesios
2021-03-26 15:36 ` Basil L. Contovounesios
2021-03-26 16:37 ` Stefan Monnier
2021-03-26 18:18 ` Basil L. Contovounesios
2021-03-26 22:12 ` Lars Ingebrigtsen
2021-03-26 15:57 ` Basil L. Contovounesios
2021-03-26 15:33 ` Basil L. Contovounesios
2021-03-26 16:32 ` Stefan Monnier
2021-03-26 18:18 ` Basil L. Contovounesios
2021-03-26 15:27 ` Basil L. Contovounesios
2021-03-26 22:11 ` Lars Ingebrigtsen
2021-03-27 1:18 ` Basil L. Contovounesios [this message]
2021-03-27 12:33 ` Lars Ingebrigtsen
2021-03-27 20:29 ` Basil L. Contovounesios
2021-03-14 14:57 ` Stefan Monnier
2021-03-14 18:42 ` Michael Albinus
2021-03-14 20:30 ` Stefan Monnier
2021-03-15 9:00 ` Michael Albinus
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878s69pf6e.fsf@tcd.ie \
--to=contovob@tcd.ie \
--cc=emacs-devel@gnu.org \
--cc=larsi@gnus.org \
--cc=michael.albinus@gmx.de \
--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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.