[Top][All Lists]

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

Re: Excessive redisplay from lots of process output

From: Spencer Baugh
Subject: Re: Excessive redisplay from lots of process output
Date: Fri, 24 Feb 2023 15:33:52 -0500

On Fri, Feb 24, 2023 at 3:19 PM Eli Zaretskii <eliz@gnu.org> wrote:
> > From: Spencer Baugh <sbaugh@janestreet.com>
> > Date: Fri, 24 Feb 2023 15:08:17 -0500
> > Cc: emacs-devel@gnu.org,
> >   azeng@janestreet.com
> >
> > > This is normal.
> >
> > Just to make sure I understand, you said earlier:
> >
> > >There are many variables and flags Emacs uses to decide when something
> > >changed that needs the display to be updated.  Those should generally
> > >prevent Emacs from running the expensive parts of redisplay if they
> > >are unnecessary.  The question is why this doesn't work in your case.
> >
> > Are you saying this does not apply in the case of reading from
> > process output? That after reading process output, we always do
> > an expensive redisplay?
> Whether redisplay is expensive or not depends on many factors.  But we
> always flush the frame in that case, yes.

Why? It seems unnecessary if nothing has changed.

> > If so, it seems to me that this could be substantially improved.
> > Why do we always do an expensive redisplay after reading process
> > output, even if nothing has been changed to make it necessary?
> We don't always do an expensive redisplay, but we always call XFlush.
> > I would like to improve this so that my Emacs does not do
> > expensive redisplay whenever it reads process output, which is
> > substantially hurting performance for me when there's lots of
> > process output to read.
> AFAIU, what is problematic for you is the X traffic causes by XFlush.

I think that is problematic for anyone running with a slow X server; it
gives the X server a lot to process.  The fact that my X server is
across the network just makes my X server seem artificially slow.

In other words, I think XFlush should be considered "expensive" and
avoided where possible.

reply via email to

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