From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "T.V Raman" Newsgroups: gmane.emacs.devel Subject: Re: Observe Slowness In minibuffer-next-completion and friends Date: Fri, 10 Nov 2023 09:01:24 -0800 Message-ID: References: <86cywiqhlr.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28988"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: emacs-devel@gnu.org To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Nov 10 18:02:23 2023 Return-path: Envelope-to: ged-emacs-devel@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 1r1Utj-0007NN-9w for ged-emacs-devel@m.gmane-mx.org; Fri, 10 Nov 2023 18:02:23 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r1UtB-0003xw-A0; Fri, 10 Nov 2023 12:01:49 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r1Usy-0003mo-Rs for emacs-devel@gnu.org; Fri, 10 Nov 2023 12:01:40 -0500 Original-Received: from mail-pl1-x62d.google.com ([2607:f8b0:4864:20::62d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r1Usu-0005Ro-Pz for emacs-devel@gnu.org; Fri, 10 Nov 2023 12:01:36 -0500 Original-Received: by mail-pl1-x62d.google.com with SMTP id d9443c01a7336-1cc1e1e74beso19981385ad.1 for ; Fri, 10 Nov 2023 09:01:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1699635687; x=1700240487; darn=gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=IoF2bOPAQKJirvhkqhJIrZlnP3nYbf6ZEil5cLTFt+Q=; b=xJZucuYIqJtsNW9/tMkr4jGmk3Tgk8SCivp93R9CirmiX9QVNRfPZi/3mm0pwMLtWT Jdtu9kye+Oa5/jE/oLcYiKzJI1cMaWGsCbHcP80yU+jy0TJdrNol1Rnf2Zi/LU1Je3rE GYKIigNaISmiUaAETFswR4qr+tZzAP644NiykcwS+5a9LVc8T2la4GNY0fZstl2J1nj6 KixTOCca5qQfdRbANstWqKKwIe+xpj9uTcSK0NU+g5ZYmE0rxO5cme1yAjIfuXDVM/iU hPc1TEjzUiwQyIDinUXkol+ePJkJDdFxpqmeknLv3zwupqnc8kZvQCs59UN3U7ae9+eB 88pg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699635687; x=1700240487; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=IoF2bOPAQKJirvhkqhJIrZlnP3nYbf6ZEil5cLTFt+Q=; b=HzH7wkkQmrMkXTmvW98yRXBJ6jOAjPbSQb2xaMGWGQUJ7XSTWbXzfeoHyfP+bVeZKG KM5RO/0XfmgwbpX0rDYgKa3m1cO3/oU63yv5kY8eES4idwxrfyGFRhR3S2d7LsBSyJBU KIZs29kor1I6gfPdG6bmEOcWN8GbGOCh252jGlJCXlA0Zs2tLRPIguKLJcfFTpHbEKQd xrsEcgHOp/x4h5b52w8D4oUgyXdSypiZSw0Oc3y8/86/eAufgRMk7BqWQ3TtUnANQQJP 7JhdijUalPKZBYwvzFjy0UO2IaYYBPk0WSnJDrekbRSW4Z4UYnKwgCBe8fFBQHSmQOAj u0Ww== X-Gm-Message-State: AOJu0YyWG3UgDLgq7LH/QL+KslC2o3mrmnEsl9HhIYQY6kSDE1aAnXbk W9rzNk/60TntyHKWxTHliHJWU+Rq7SrZx4gHd9MlbA== X-Google-Smtp-Source: AGHT+IGgNL6+1znvT/i6Uvbku4Mipm59cl4PqOiuNKQZj84ozJ/JZA/8Ced5x2i/tCKKEin39gyzjg== X-Received: by 2002:a17:902:d2ce:b0:1cc:3f10:4175 with SMTP id n14-20020a170902d2ce00b001cc3f104175mr10034388plc.28.1699635687009; Fri, 10 Nov 2023 09:01:27 -0800 (PST) Original-Received: from raman9 ([2601:646:9e02:3290:8b13:25df:570a:8c42]) by smtp.gmail.com with ESMTPSA id v11-20020a170902d68b00b001bde6fa0a39sm5594534ply.167.2023.11.10.09.01.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Nov 2023 09:01:26 -0800 (PST) In-Reply-To: <86cywiqhlr.fsf@mail.linkov.net> (Juri Linkov's message of "Fri, 10 Nov 2023 09:49:36 +0200") Received-SPF: pass client-ip=2607:f8b0:4864:20::62d; envelope-from=raman@google.com; helo=mail-pl1-x62d.google.com X-Spam_score_int: -175 X-Spam_score: -17.6 X-Spam_bar: ----------------- X-Spam_report: (-17.6 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, ENV_AND_HDR_SPF_MATCH=-0.5, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, USER_IN_DEF_DKIM_WL=-7.5, USER_IN_DEF_SPF_WL=-7.5 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:312502 Archived-At: Juri Linkov writes: I dont have native compilation enabled, so the async path likely plays no role in this? >> This appears to be new as of this afternoon's update on Git: >> >> Type: >> C-h f next- >> Then press down-arrow to move to next completion; the completion list >> appears to be not active for about a second. I already tried setting >> completion-highlight-face to nil, but the slowness remains; from >> memory this feels new compared to yesterday > > The first time I tried it was very slow, it took about 3 seconds. > Then on next attempts it was instantaneous. This means only one thing > that you have to wait a little until asynchronous native compilation > finishes its job. > > That said, I think there are more opportunities for optimization. > What I don't like is that it checks the presence of the completions > window for the every key pressed. A possible optimization would be > to set a minibuffer-local variable when the completions window > is displayed, and unset it when the window disappears. However, > still can't handle the case when the user closes the completions > window manually with e.g. 'C-x 0'. --