GNU bug report logs - #52298
29.0.50; Frequent redisplay cycles induced by c-type-finder-timer-func timer in CC Mode

Previous Next

Package: emacs;

Reported by: Eli Zaretskii <eliz <at> gnu.org>

Date: Sun, 5 Dec 2021 07:47:02 UTC

Severity: normal

Found in version 29.0.50

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

Bug is archived. No further changes may be made.

Full log


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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Alan Mackenzie <acm <at> muc.de>
Cc: acm <at> muc.de, 52298 <at> debbugs.gnu.org
Subject: Re: bug#52298: 29.0.50; Frequent redisplay cycles induced by
 c-type-finder-timer-func timer in CC Mode
Date: Fri, 10 Dec 2021 20:51:32 +0200
> Date: Fri, 10 Dec 2021 18:16:21 +0000
> Cc: 52298 <at> debbugs.gnu.org, acm <at> muc.de
> From: Alan Mackenzie <acm <at> muc.de>
> 
> > Both of these are called from the timer function.  Are they using
> > with-silent-modifications?
> 
> I'm pretty sure they are.
> 
> I think that modify_text_properties is calling modiff_incr even when
> inhibit_modification_hooks is non-nil.  I tried putting an `if' around
> that bit of the code, without any great success.

AFAIK, with-silent-modifications is supposed to prevent BUF_MODIFF
from increasing.  Are you sure you see that?  And what kind of 'if'
did you try to put and where?

> The main reason for all the redisplaying (which I got from
> trace-redisplay displaying "redisplay_preserve_echo_area (8)") is the
> call from detect_input_pending_run_timers in keyboard.c.  It is calling
> redisplay_preserve_echo_area each time the timer triggers.

This is normal, not something you need to investigate: every time a
timer function fires, we make one more iteration through the Emacs
idle loop, and that includes a call to redisplay_preserve_echo_area.

Once again, the problem is not that redisplay is invoked, the problem
is that it doesn't exit almost immediately, after detecting that
nothing's changed.




This bug report was last modified 3 years and 212 days ago.

Previous Next


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