From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: Long delay after M-x commandname Date: Mon, 11 Oct 2021 15:07:29 +0300 Message-ID: <83fst7rchq.fsf@gnu.org> References: Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28011"; mail-complaints-to="usenet@ciao.gmane.io" To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 11 14:16:51 2021 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mZuEc-00073K-Ay for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 11 Oct 2021 14:16:50 +0200 Original-Received: from localhost ([::1]:48382 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mZuEb-0004aj-4d for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 11 Oct 2021 08:16:49 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39000) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mZu5k-0000Wt-Ts for help-gnu-emacs@gnu.org; Mon, 11 Oct 2021 08:07:40 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:51294) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mZu5k-0004qm-Iy for help-gnu-emacs@gnu.org; Mon, 11 Oct 2021 08:07:40 -0400 Original-Received: from [87.69.77.57] (port=2098 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mZu5k-0000Ra-4j for help-gnu-emacs@gnu.org; Mon, 11 Oct 2021 08:07:40 -0400 In-Reply-To: (message from Stefan Monnier via Users list for the GNU Emacs text editor on Mon, 11 Oct 2021 00:03:19 -0400) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:133719 Archived-At: > Date: Mon, 11 Oct 2021 00:03:19 -0400 > From: Stefan Monnier via Users list for the GNU Emacs text editor > > Eduardo Ochs [2021-10-10 21:45:39] wrote: > > > Yesterday I noticed that when I was invoking commands with M-x > > commandname and using tab for completing parts of the name then > > sometimes there would be a long delay - sometimes as long as 10 > > seconds, but my laptop is quite old - between the RET and the > > execution of the command. This delay was big on emacs28 and > > practically imperceptible on emacs27. I have several versions of > > emacs28 here, with names like emacs28_512 for the one correponding to > > HEAD~512 and emacs28_0 for HEAD, and I noticed that this delay was > > growing in recent versions: small in HEAD~256, bigger in HEAD~128, > > much bigger in HEAD~0. > > > > I _guess_ that these delays are caused by the code that generates > > messages like this one: > > > > You can run the command `find-eev-install-intro' with `M-x f--i-i'. > > This message can be suppressed with `extended-command-suggest-shorter`. > > It can take work to find that shortest replacement (it's a kind of > brute-force algorithm which tries all combinations of increasing length > until one works), indeed, tho usually it's negligible. I'm surprised > the time taken has changed significantly recently That code has been > the same Emacs-26, AFAIK. The completion data has an impact on the > performance, so maybe that's what's going on, but it still seems > surprising you'd see such a progressive slowdown. FWIW, I don't see any delay in "emacs -Q", so I think the question becomes what kind of customizations and packages loaded could significantly increase that time.