Re: Re: how to write snappy benchmark?

Havoc Pennington <[email protected]>
Newsgroups gmane.comp.xfree86.forum
Message-ID <[email protected]>
On Sun, Jul 06, 2003 at 04:21:08PM -0700, Allen Akin wrote: 
> I brought up the subject of double-buffered displays without per-window
> backing store because the backing store just papers over the real
> problem, and costs a fair amount of memory in the bargain.  As you said,
> if the apps take a long time to render, you're still stuck looking at a
> stale image for a noticeable amount of time.

Not sure backing store papers over the real problem. Two real problems
it's the correct solution for are:

 - expose event -> application -> repaint round trip causes latency;
   saving window contents on the server side is the right solution 
   here, it avoids the round trip entirely

 - recomputing what to render is expensive. For example, drawing
   Unicode text involves a fair bit of glyph selection, positioning,
   and so forth. The best way to cache that may well be in pixmap
   form, i.e. by just saving the pixels that were drawn, rather 
   than caching it at any higher level.

If the bottleneck is either of those things (and it may well be,
though we still have no hard profile data), then backing store isn't a
band-aid, it's exactly the right fix and it does solve the problem.

"Stale images" are only an issue if your image is changing, and for
the most part here we don't have any kind of animation, we're just
talking about repainting something static.

An interesting question is: if you never had to wake up applications
just to handle exposes, would that mean you could more effectively
keep unused applications paged out and get better system performance
as a result? No way to tell without hard data really.

Havoc
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.