[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Why buffer_shared is a mistake
From: |
Dmitry Antipov |
Subject: |
Re: Why buffer_shared is a mistake |
Date: |
Mon, 10 Dec 2012 11:29:46 +0400 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 |
On 12/08/2012 05:58 PM, Eli Zaretskii wrote:
buffer_shared is used only by xdisp.c, with the single exception of
modify_overlay. How about changing modify_overlay to compute this
value by itself?
This is definitely possible (by enhancing window_loop, for example).
But now I'm thinking about maintaining per-buffer window counter,
which value is independent from the redisplay actions. This opens
the way to a different optimizations (e.g. if we're modifying a buffer
which isn't shown in a window, we can avoid redisplay at all).
(My view of the whole thing is: Emacs global state is huge, and
redisplay is controlled by too much amount of global variables.
This is error-prone and makes some valuable things like threading
too complicated or even impossible. So it's desirable to deduce
redisplay actions from per-buffer/window/frame variables rather
than from the global ones.)
Dmitry
window_count.patch
Description: Text document