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

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

bug#14886: Fwd: A significant slowdown calling font-lock-fontify-buffer


From: Juanma Barranquero
Subject: bug#14886: Fwd: A significant slowdown calling font-lock-fontify-buffer from a hook
Date: Wed, 17 Jul 2013 01:03:32 +0200

Package: emacs
Version: 24.3.50
X-Debbugs-Cc: address@hidden


Filed.


---------- Forwarded message ----------
From: Eli Zaretskii <address@hidden>
Date: Tue, Jul 16, 2013 at 8:47 PM
Subject: Re: A significant slowdown calling font-lock-fontify-buffer from a hook
To: Juanma Barranquero <address@hidden>
Cc: address@hidden


> From: Juanma Barranquero <address@hidden>
> Date: Tue, 16 Jul 2013 20:26:56 +0200
> Cc: Emacs developers <address@hidden>
>
> > Is the "calling from a hook" an important part of this issue?
>
> Doing
>
>   emacs -Q src/xdisp.c
>   M-x font-lock-fontify-buffer <RET>
>
> I don't see the slowdown.

First, you need to turn off global-font-lock-mode before visiting
xdisp.c.  Second, if you do turn off global-font-lock-mode, invoking
font-lock-fontify-buffer will fail in Emacs 24.3.  You need to do
something like this instead:

  M-: (let ((c-standard-font-lock-fontify-region-function
'font-lock-default-fontify-region)) (font-lock-fontify-buffer)) RET

If I do this in Emacs 24.3 and in the current trunk, I do see a
significant slowdown: it takes 18 sec with 24.3, and 72 sec with the
current trunk.

So I think the invocation from hook is not a factor here, which is a
Good Thing, because debugging this will be much simpler ;-)





reply via email to

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