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.bugs Subject: bug#56682: Fix the long lines font locking related slowdowns Date: Tue, 26 Jul 2022 20:29:05 +0300 Message-ID: <8335endbq6.fsf@gnu.org> References: <837d46mjen.fsf@gnu.org> <174616cd5c33bfc14b1f@heytings.org> <837d44jr4p.fsf@gnu.org> <83bktghrn0.fsf@gnu.org> <8a3eaeef010995a5da8d@heytings.org> <837d40ds09.fsf@gnu.org> <83zggwcby5.fsf@gnu.org> <83o7xccagi.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33416"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 56682@debbugs.gnu.org, gregory@heytings.org, monnier@iro.umontreal.ca To: Gerd =?UTF-8?Q?M=C3=B6llmann?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jul 26 19:30:55 2022 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 1oGOOU-0008UK-Fp for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 26 Jul 2022 19:30:54 +0200 Original-Received: from localhost ([::1]:43912 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oGOOT-00028a-EI for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 26 Jul 2022 13:30:53 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53226) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oGONe-00026L-8P for bug-gnu-emacs@gnu.org; Tue, 26 Jul 2022 13:30:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:36338) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oGONd-0001Y5-T6 for bug-gnu-emacs@gnu.org; Tue, 26 Jul 2022 13:30:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oGONd-0000k0-OZ for bug-gnu-emacs@gnu.org; Tue, 26 Jul 2022 13:30:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 26 Jul 2022 17:30:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56682 X-GNU-PR-Package: emacs Original-Received: via spool by 56682-submit@debbugs.gnu.org id=B56682.16588565492750 (code B ref 56682); Tue, 26 Jul 2022 17:30:01 +0000 Original-Received: (at 56682) by debbugs.gnu.org; 26 Jul 2022 17:29:09 +0000 Original-Received: from localhost ([127.0.0.1]:54320 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oGOMm-0000iG-Rh for submit@debbugs.gnu.org; Tue, 26 Jul 2022 13:29:09 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:39938) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oGOMk-0000hj-Ec for 56682@debbugs.gnu.org; Tue, 26 Jul 2022 13:29:06 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:42934) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oGOMf-0001Lp-7K; Tue, 26 Jul 2022 13:29:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=y41QMAxLrjuAS4/a4cufayeXiDMl2qcroOktBtCkoXg=; b=NpH/lLYIFJMmBxNrE1km 1uRk9u8qBLBZ72NBbi+BG3+2tpdnO+EtdblhbyiZwm+gmbOZAdXJ9Jl1oB18CKf7W4+MQR4/LvxbY AwGPBq7OmM31GTPHBLZyDg/m6qXNpQmdlzkamNrABAtogK/WsRJGtavGDyllP1vcWNbdhJRgDGH1+ BR7e5+sWJPG0c51RVOgxK3HfecEgdv9Vnaj033botBrMd6jkT+uDjK6PMeVKySefQDLCgNmGzY5Go 3LFS8pGURBnsXXNXjqixPzO5//8tyQkRPAUsg0guArYmlHbBDsJjSS0HXq/aPdQYbzZo/mpkVr8q8 roqkkpI4GdEZbw==; Original-Received: from [87.69.77.57] (port=4126 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 1oGOMd-0007yn-Em; Tue, 26 Jul 2022 13:29:01 -0400 In-Reply-To: (message from Gerd =?UTF-8?Q?M=C3=B6llmann?= on Tue, 26 Jul 2022 15:08:18 +0200) 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" Xref: news.gmane.io gmane.emacs.bugs:237982 Archived-At: > From: Gerd Möllmann > Cc: Gregory Heytings , 56682@debbugs.gnu.org, > monnier@iro.umontreal.ca > Date: Tue, 26 Jul 2022 15:08:18 +0200 > > What about the following idea, in general. Sorry if that is in the > wrong sub-thread, I'm beginning to loose orientation a bit. > > While iterating, > > - remmember where we started, say it's 'start_pos'. > > - when reaching start_pos + X, without reaching a line end, refuse to do > any complex stuff, no faces, invisible text and so on. > > I could think of numerous variations of that theme. > > I just loaded long-lines.xml in VSCode, and it seems to do something > like that. It says that "tokenization has been disabled" in the long > line. The long line doesn't have the highlighting that the shorter ones > have, and VSCode also wraps the long line instead of truncating it. We keep this possibility in mind all the time, you can see it in, for example, the discussion whether to turn off line truncation. But, as I explained a minute ago, I think we haven't yet exhausted less drastic measures, and there could still be opportunities for speedup in the basic display code or thereabouts. Our display is different from that of VSCode, so the trade-offs are different as well.