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: Sat, 23 Jul 2022 17:47:13 +0300 Message-ID: <83a68zj37y.fsf@gnu.org> References: <837d46mjen.fsf@gnu.org> <174616cd5c33bfc14b1f@heytings.org> <837d44jr4p.fsf@gnu.org> <83bktghrn0.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12715"; mail-complaints-to="usenet@ciao.gmane.io" Cc: gerd.moellmann@gmail.com, 56682@debbugs.gnu.org, monnier@iro.umontreal.ca To: gregory@heytings.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jul 23 16:48:13 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 1oFGQN-00034y-8J for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 23 Jul 2022 16:48:11 +0200 Original-Received: from localhost ([::1]:38256 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oFGQL-00082X-O5 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 23 Jul 2022 10:48:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45400) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oFGQE-00082K-NG for bug-gnu-emacs@gnu.org; Sat, 23 Jul 2022 10:48:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56271) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oFGQE-0005qU-EQ for bug-gnu-emacs@gnu.org; Sat, 23 Jul 2022 10:48:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oFGQE-0006jj-Ad for bug-gnu-emacs@gnu.org; Sat, 23 Jul 2022 10:48:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 23 Jul 2022 14:48:02 +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.165858764425718 (code B ref 56682); Sat, 23 Jul 2022 14:48:02 +0000 Original-Received: (at 56682) by debbugs.gnu.org; 23 Jul 2022 14:47:24 +0000 Original-Received: from localhost ([127.0.0.1]:46020 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oFGPc-0006gk-Aw for submit@debbugs.gnu.org; Sat, 23 Jul 2022 10:47:24 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:60644) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oFGPa-0006gS-8c for 56682@debbugs.gnu.org; Sat, 23 Jul 2022 10:47:23 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:40010) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oFGPU-0005n2-UO; Sat, 23 Jul 2022 10:47:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=+hAnf7S02i16lfCjYfzgIjbdZ8zhFf4YZmi5+frPypI=; b=IZVI3f5RM0Vj IQEmtv46EJVnCAQJZz0tb/L7EIGCstnny+N0PbmOTMdoZDYBwc9EiWvk5L3l4mUImUOW04ND8IPC6 XxfOZwl+svSR1atDnYFqXmJeivY/pt4ILBe0ZakQ/Z7C2uKayMKYIKW3h62/jHPGcHE14YbKDaJdz eFLylqxrtfcHdvTuAhepsUuKpOrzVSYWqdu2ScDCrC/mH/4EzBhjunovDtQZ0nuoLngtVWPcF/g80 4Dx74Od8m59QqlAaKz5OPtttQqxVeIkRbWyuO98p0va4Hvr1OpDKwfqLIKFw+D7tCiSi+/UFZ1n4J 1NSthCc5EW0e00vpwxaWfA==; Original-Received: from [87.69.77.57] (port=2906 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 1oFGPU-00035T-Cu; Sat, 23 Jul 2022 10:47:16 -0400 In-Reply-To: <83bktghrn0.fsf@gnu.org> (message from Eli Zaretskii on Sat, 23 Jul 2022 16:42:43 +0300) 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:237754 Archived-At: Another observation: any command that calls current_column, directly or indirectly, will be very slow with long lines. This includes "C-x =" and column-number-mode, for example. I installed a change to avoid calling current_column where possible, but the problem is we have a bytecode which calls it, and it is impossible to avoid the call because it could break some callers. Perhaps we should expose the long-line-optimization flag to Lisp, so that commands like what-cursor-position could refrain from calling current-column.