From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrew Cohen Newsgroups: gmane.emacs.bugs Subject: bug#63842: 30.0.50; Slow 'gnus-summary-refer-thread' Date: Mon, 19 Jun 2023 20:58:15 +0800 Message-ID: <87bkhbpq1k.fsf@ust.hk> References: <871qiu6m1f.fsf@ledu-giraud.fr> <87bkhxl9th.fsf@ust.hk> <87ilc44r3u.fsf@ledu-giraud.fr> <831qiduv5f.fsf@gnu.org> <87352rr8vz.fsf@ledu-giraud.fr> <87fs6rashz.fsf@ust.hk> <87352ppwed.fsf@ledu-giraud.fr> <87ttv54myy.fsf@ust.hk> <87o7lco5dv.fsf@ledu-giraud.fr> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24405"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Andrew Cohen , Eli Zaretskii , 63842@debbugs.gnu.org, cohen@andy.bu.edu To: Manuel Giraud Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jun 19 14:59:21 2023 Return-path: Envelope-to: geb-bug-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 1qBETY-0006Ca-N8 for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 19 Jun 2023 14:59:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qBETJ-0008Ls-55; Mon, 19 Jun 2023 08:59:05 -0400 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 1qBETG-0008Lk-Kg for bug-gnu-emacs@gnu.org; Mon, 19 Jun 2023 08:59:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qBETG-0007ls-Bm for bug-gnu-emacs@gnu.org; Mon, 19 Jun 2023 08:59:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qBETG-0006YK-1Z for bug-gnu-emacs@gnu.org; Mon, 19 Jun 2023 08:59:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Andrew Cohen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 19 Jun 2023 12:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63842 X-GNU-PR-Package: emacs Original-Received: via spool by 63842-submit@debbugs.gnu.org id=B63842.168717951425150 (code B ref 63842); Mon, 19 Jun 2023 12:59:02 +0000 Original-Received: (at 63842) by debbugs.gnu.org; 19 Jun 2023 12:58:34 +0000 Original-Received: from localhost ([127.0.0.1]:55794 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qBESo-0006Xa-3k for submit@debbugs.gnu.org; Mon, 19 Jun 2023 08:58:34 -0400 Original-Received: from andy.bu.edu ([128.197.41.152]:36342) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qBESm-0006XN-4x for 63842@debbugs.gnu.org; Mon, 19 Jun 2023 08:58:32 -0400 Original-Received: from [193.176.211.165] (helo=clove) by andy.bu.edu with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qBESf-0004D0-7R; Mon, 19 Jun 2023 08:58:26 -0400 In-Reply-To: <87o7lco5dv.fsf@ledu-giraud.fr> (Manuel Giraud's message of "Sun, 18 Jun 2023 22:57:32 +0200") X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-Spam_report: Spam detection software, running on the system "andy.bu.edu", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: >>>>> "MG" == Manuel Giraud writes: MG> Andrew Cohen writes: >> OK, I think I understand the problem. [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:263678 Archived-At: >>>>> "MG" == Manuel Giraud writes: MG> Andrew Cohen writes: >> OK, I think I understand the problem. [...] MG> From my tiny testing set, it does not seems to me that parsing MG> all the headers is the way to go: the call to MG> 'gnus-search-run-query' in gnus-search.el line 2206 directly MG> returns direcly the correct set of messages and the call to MG> 'gnus-get-newsgroup-headers-xover' later looks like some "deep" MG> search (eg. on subject content). OK, I understand it now. This isn't really about searching, or subject content (the fact that Manuel sees some articles not in the thread but with similar subject remains a bit of a mystery). To get everything right, any articles in the thread that need to be added to the summary buffer have to be added to the dependencies hash. In the case of searching we know exactly which articles need to be added so we have no need for 'gnus-read-all-available-headers to be non-nil: the "found" articles are each added to the hash. The only case where 'gnus-read-all-available-headers needs to be non-nil is when we don't know exactly which articles are part of the thread in which case we have to parse a larger set. This is what happens in the 3rd case in the conditional (the "t" clause) in 'gnus-summary-refer-thread. That is, this variable is only relevant in those cases where we don't have a configured search engine and just retrieve a lot of headers and hope for the best. So the setting of 'gnus-read-all-available-headers is just in the wrong place. Thanks to Manuel for figuring out the error. I'll push the fix shortly. Best, Andy -- Andrew Cohen