From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#25682: 25.1; font-lock: fontifying too slow in some modes on very long lines Date: Thu, 31 Oct 2019 19:26:23 +0200 Message-ID: <831rusomgw.fsf@gnu.org> References: <87wock6dxy.fsf@gnus.org> Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="180339"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 25682@debbugs.gnu.org, public@ryanb.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Oct 31 18:27:12 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iQEE2-000kiq-CK for geb-bug-gnu-emacs@m.gmane.org; Thu, 31 Oct 2019 18:27:10 +0100 Original-Received: from localhost ([::1]:52976 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iQEE1-0004D6-8e for geb-bug-gnu-emacs@m.gmane.org; Thu, 31 Oct 2019 13:27:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47905) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iQEDv-0004CP-Ln for bug-gnu-emacs@gnu.org; Thu, 31 Oct 2019 13:27:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iQEDu-0006Ga-LZ for bug-gnu-emacs@gnu.org; Thu, 31 Oct 2019 13:27:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:45399) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iQEDu-0006GM-Hg for bug-gnu-emacs@gnu.org; Thu, 31 Oct 2019 13:27:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iQEDu-0005t4-Cw for bug-gnu-emacs@gnu.org; Thu, 31 Oct 2019 13:27: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: Thu, 31 Oct 2019 17:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25682 X-GNU-PR-Package: emacs Original-Received: via spool by 25682-submit@debbugs.gnu.org id=B25682.157254279222592 (code B ref 25682); Thu, 31 Oct 2019 17:27:02 +0000 Original-Received: (at 25682) by debbugs.gnu.org; 31 Oct 2019 17:26:32 +0000 Original-Received: from localhost ([127.0.0.1]:54220 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iQEDQ-0005sK-7L for submit@debbugs.gnu.org; Thu, 31 Oct 2019 13:26:32 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:38718) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iQEDO-0005s7-92 for 25682@debbugs.gnu.org; Thu, 31 Oct 2019 13:26:30 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:57660) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1iQEDI-0005pM-7Q; Thu, 31 Oct 2019 13:26:24 -0400 Original-Received: from [176.228.60.248] (port=1048 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1iQEDH-0007qF-If; Thu, 31 Oct 2019 13:26:24 -0400 In-reply-to: <87wock6dxy.fsf@gnus.org> (message from Lars Ingebrigtsen on Thu, 31 Oct 2019 18:07:53 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:170542 Archived-At: > From: Lars Ingebrigtsen > Date: Thu, 31 Oct 2019 18:07:53 +0100 > Cc: 25682@debbugs.gnu.org > > > 1. put the single long line under the === below (18572 chars long) into a file > > 2. run emacs -Q > > 3. type C-x C-f RET to open the file > > 4. type M-x compilation-mode RET > > > > this consistently hangs emacs for 9-10s for me on modern hardware, a 2014 > > retina macbook pro. > > The example was corrupted in transit (line-folded), so I've included a > fixed-up version as an attachment here. The profile is below. > Running M-x compilation-mode takes about five seconds for me, but this > laptop is pretty fast. Yours is an optimized build, right? - ... 3375 98% - compilation--ensure-parse 3362 98% - save-excursion 3362 98% - if 3362 98% - progn 3362 98% - let 3362 98% - let* 3362 98% - unwind-protect 3362 98% - progn 3362 98% - compilation--parse-region 3362 98% - if 3362 98% - compilation-parse-errors 3362 98% - let 3362 98% - while 3362 98% - let 3362 98% - let 3362 98% while 3362 98% Automatic GC 13 0% - command-execute 50 1% - call-interactively 50 1% - funcall-interactively 48 1% - execute-extended-command 48 1% - execute-extended-command--shorter 45 1% - completion-try-completion 45 1% - completion--nth-completion 45 1% - completion--some 45 1% - # 45 1% - completion-pcm-try-completion 28 0% - completion-pcm--find-all-completions 26 0% completion-pcm--all-completions 26 0% - completion-pcm--merge-try 2 0% completion-pcm--merge-completions 1 0% completion-basic-try-completion 17 0% - command-execute 1 0% - call-interactively 1 0% - funcall-interactively 1 0% - compilation-mode 1 0% - run-mode-hooks 1 0% - hack-local-variables 1 0% - hack-dir-local-variables 1 0% - dir-locals-find-file 1 0% - locate-dominating-file 1 0% dir-locals--all-files 1 0% - sit-for 1 0% redisplay 1 0% - byte-code 2 0% - read-extended-command 2 0% - completing-read 2 0% - completing-read-default 2 0% read-from-minibuffer 2 0%