GNU bug report logs - #25706
26.0.50; Slow C file fontification

Previous Next

Packages: cc-mode, emacs;

Reported by: Sujith <m.sujith <at> gmail.com>

Date: Mon, 13 Feb 2017 18:41:01 UTC

Severity: normal

Tags: moreinfo

Found in version 26.0.50

Done: Alan Mackenzie <acm <at> muc.de>

Bug is archived. No further changes may be made.

Full log


Message #86 received at 25706 <at> debbugs.gnu.org (full text, mbox):

From: Mattias EngdegÄrd <mattiase <at> acm.org>
To: Alan Mackenzie <acm <at> muc.de>
Cc: Lars Ingebrigtsen <larsi <at> gnus.org>, 25706 <at> debbugs.gnu.org
Subject: Re: bug#25706: 26.0.50; Slow C file fontification
Date: Thu, 3 Dec 2020 15:03:27 +0100
3 dec. 2020 kl. 11.48 skrev Alan Mackenzie <acm <at> muc.de>:

> I've found it.  There was a "harmless" c-backward-syntactic-ws invocation
> in c-determine-limit.  This macro moves back over syntactic whitespace,
> which includes macros.  So this was going back all the way to BOB, from
> which we scanned forward again.

Not bad. Now Emacs starts becoming usable for real code!
I can confirm a big subjective improvement on several big preprocessor-heavy files, and measurements agree.

> It now takes me just under 6 minutes to (time-scroll) through the entire
> buffer, compared with a previous hour.  As already mentioned, it is still
> slightly more sluggish near the end of the buffer than near the start.

Is that with or without my regexp patch?

It looks like there may be more regexp improvements possible. We can take a closer look later on, when the running time is less dominated by other issues.





This bug report was last modified 4 years and 213 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.