bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#10539: 24.0.92; low display-time-interval makes Emacs slow


From: Lars Ingebrigtsen
Subject: bug#10539: 24.0.92; low display-time-interval makes Emacs slow
Date: Sat, 23 Apr 2022 16:41:48 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Michael Heerdegen <michael_heerdegen@web.de> writes:

> The docstring of `display-time-interval' says "Seconds between updates
> of time in the mode line.".  Ok, fine.  The doc of
> `display-time-string-forms' includes an example which makes
> `display-time-mode' show seconds.  So, the user may think setting
> `display-time-interval' to 1 is a good idea.
>
> But it is currently not, on the contrary.
>
> First of all, `display-time-update' is a long, complex function.
> Running only its calculations every second consumes some percent CPU by
> itself.

(I'm going through old bug reports that unfortunately weren't resolved
at the time.)

I've tried this in Emacs 29, and the Emacs in question does not show up
on "top" as consuming any CPU, so this has perhaps improved?

> Second, the doc of `display-time-update' says
>
>   Update the display-time info for the mode line.
>   However, don't redisplay right now.
>
> But it _does_ redisplay, it calls `force-mode-line-update' explicitly at
> the end of the code!

As noted in the bug thread, `force-mode-line-update' just sets some
variables to make the next redisplay cycle update the mode lines, so
the doc string is correct, I think.

The discussion then went on to adding some more comments or something,
but I'm not sure whether there's anything more to be done here?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

[Prev in Thread] Current Thread [Next in Thread]