GNU bug report logs - #11545
24.0.96-mac-2.92; Strange speed problem scrolling in C++ code

Previous Next

Packages: cc-mode, emacs;

Reported by: John Wiegley <jwiegley <at> gmail.com>

Date: Wed, 23 May 2012 07:27:02 UTC

Severity: normal

Done: Stefan Kangas <stefan <at> marxist.se>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Stefan Kangas <stefan <at> marxist.se>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#11545: closed (24.0.96-mac-2.92; Strange speed problem
 scrolling in C++ code)
Date: Sat, 02 Nov 2019 11:09:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Sat, 02 Nov 2019 12:08:47 +0100
with message-id <87h83meds0.fsf <at> marxist.se>
and subject line Re: 24.0.96-mac-2.92; Strange speed problem scrolling in C++ code
has caused the debbugs.gnu.org bug report #11545,
regarding 24.0.96-mac-2.92; Strange speed problem scrolling in C++ code
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
11545: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=11545
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: John Wiegley <jwiegley <at> gmail.com>
To: YAMAMOTO Mitsuharu <mituharu <at> math.s.chiba-u.ac.jp>
Cc: bug-cc-mode <at> gnu.org, bug-gnu-emacs <at> gnu.org,
	mituharu+bug-gnu-emacs-mac <at> math.s.chiba-u.ac.jp
Subject: Re: 24.0.96-mac-2.92; Strange speed problem scrolling in C++ code
Date: Wed, 23 May 2012 02:24:49 -0500
>>>>> YAMAMOTO Mitsuharu <mituharu <at> math.s.chiba-u.ac.jp> writes:

> With the Time Profiler in Instrument.app, I found that fontification
> of CC Mode in Emacs 24 is much heavier and causes frequent GCs than
> that in Emacs 23.  Please try the following:
> 
>   1. Start Emacs 24 Mac port with -Q (alternatively, pressing the
>      shift key.)
>   2. M-x load-file PREFIX/share/emacs/23.4/lisp/progmodes/cc-fonts.elc
>      RTE.
>   3. Replay scrolling a large C++ file.
> 
> I'm not sure if this slowdown is intended or expected.

Indeed, this makes the speed situation much better on Emacs 24.0.97.

 - When I scroll a large C++ file in Emacs 24.0.97 the first time, the
   performance is very choppy, even on a powerful Mac Pro machine.

   There are moments toward the end of the file when I can actually count out
   10 seconds or so before it moves on to the next page.  The file is 17,983
   lines long, consisting entirely of type declarations, enum, #define's and
   prototypes.

 - If I press M-<, go back to the top of the file, and then scroll to the
   bottom again, there are basically no pauses.

 - If I delete the buffer and re-open the file, scrolling is the same as
   before.

 - If I delete the buffer and load cc-fonts.elc from Emacs 23.4, scrolling
   performance is *much* better.  It is less choppy, and although it still
   shows one long pause toward the end (garbage collection?), that's it.

 - As before, going to the top with M-< and re-scrolling shows perfect speed,
   no lag whatsoever; and killing the buffer and re-scrolling shows the same
   faster performance as before, with less lag (but still a little bit).

The strange thing is, cc-fonts.el.gz is identical between Emacs 23.4 and Emacs
24.0.97!  Only the .elc's differ.  Have we found a byte-compilation issue in
Emacs 24?

John


[Message part 3 (message/rfc822, inline)]
From: Stefan Kangas <stefan <at> marxist.se>
To: Alan Mackenzie <acm <at> muc.de>
Cc: John Wiegley <jwiegley <at> gmail.com>,
 YAMAMOTO Mitsuharu <mituharu <at> math.s.chiba-u.ac.jp>, 11545-done <at> debbugs.gnu.org
Subject: Re: 24.0.96-mac-2.92; Strange speed problem scrolling in C++ code
Date: Sat, 02 Nov 2019 12:08:47 +0100
Hi Alan,

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

>> Just to follow up on this bug, which has seen no update in the last 7
>> years.  Has it been fixed by now?
>
> "Fixed" doesn't seem the right term, really.  There have been several
> improvemnts in the scrolling speed over the years (the latest less than
> an hour ago ;-).  When I scroll through a typical ~700k C++ buffer, I now
> experience mild sluggishness, a C-v taking a small fraction of a second,
> but longer than instantaneous.  This is perhaps less than ideal on a
> slowish machine (which mine is not), but there's a tradeoff between rapid
> fontification and correct fontification.
>
> I think this bug should now be closed.

Thanks for that explanation.  I'm consequently closing the bug.

Best regards,
Stefan Kangas


This bug report was last modified 5 years and 209 days ago.

Previous Next


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