From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Phil Sainty Newsgroups: gmane.emacs.bugs Subject: bug#40007: 28.0.50; Emacs gets very slow when displaying a long line Date: Tue, 24 Mar 2020 21:49:19 +1300 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="96601"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 Cc: 40007@debbugs.gnu.org To: Pieter van Oostrum , Jan Synacek Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Mar 24 09:50:16 2020 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 1jGfGJ-000P0t-RU for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 24 Mar 2020 09:50:15 +0100 Original-Received: from localhost ([::1]:44594 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jGfGI-0004rt-Iu for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 24 Mar 2020 04:50:14 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39773) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jGfG7-0004rn-GA for bug-gnu-emacs@gnu.org; Tue, 24 Mar 2020 04:50:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jGfG6-0000r0-2e for bug-gnu-emacs@gnu.org; Tue, 24 Mar 2020 04:50:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:47889) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jGfG5-0000qq-UW for bug-gnu-emacs@gnu.org; Tue, 24 Mar 2020 04:50:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jGfG5-0000Qa-RW for bug-gnu-emacs@gnu.org; Tue, 24 Mar 2020 04:50:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Phil Sainty Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 24 Mar 2020 08:50:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40007 X-GNU-PR-Package: emacs Original-Received: via spool by 40007-submit@debbugs.gnu.org id=B40007.15850397651588 (code B ref 40007); Tue, 24 Mar 2020 08:50:01 +0000 Original-Received: (at 40007) by debbugs.gnu.org; 24 Mar 2020 08:49:25 +0000 Original-Received: from localhost ([127.0.0.1]:53862 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jGfFV-0000PY-1G for submit@debbugs.gnu.org; Tue, 24 Mar 2020 04:49:25 -0400 Original-Received: from smtp-3.orcon.net.nz ([60.234.4.44]:55269) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jGfFT-0000PL-5R for 40007@debbugs.gnu.org; Tue, 24 Mar 2020 04:49:24 -0400 Original-Received: from [101.53.216.157] (port=44719 helo=[192.168.20.103]) by smtp-3.orcon.net.nz with esmtpa (Exim 4.90_1) (envelope-from ) id 1jGfFP-0003KN-Fh; Tue, 24 Mar 2020 21:49:19 +1300 In-Reply-To: Content-Language: en-GB X-GeoIP: NZ X-Spam_score: -2.9 X-Spam_score_int: -28 X-Spam_bar: -- X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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" Xref: news.gmane.io gmane.emacs.bugs:177672 Archived-At: On 10/03/20 11:46 pm, Pieter van Oostrum wrote: > Jan Synacek writes: > >> 1) emacs -Q >> 2) M-x shell >> 3) execute a program that displays a single line, about ~193000 >> characters long > > Use so-long-mode. For clarity, global-so-long-mode isn't going to help with that recipe, because it doesn't try to detect the *dynamic* creation of very long lines. It only cares about visiting files. In principle it can be employed successfully in other situations, but for now it's up to users to target such things explicitly. E.g.: https://www.reddit.com/r/emacs/comments/ccoksw/solong_mitigating_slowness_due_to_extremely_long/etpi51l/ Note that you probably shouldn't invoke major mode so-long-mode in a shell-mode buffer, but so-long-minor-mode could help somewhat if it were enabled. I think only slightly, though -- in this instance you'll end up with the *end* of a very long line on display, and so performance is going to be fairly poor regardless. Certainly in my test it didn't make a dramatic difference. (The really major benefits of so-long are in preventing certain serious problems which can occur even when only the start of the line is visible, and in those situations the improvements can be extremely good.) As Eli says, the library alleviates some of the problems -- but only some of them. -Phil