Mixed pixmap creation

Jonathan Morton jonathan.morton at movial.com
Thu Oct 14 02:34:43 PDT 2010


On Thu, 2010-10-14 at 17:07 +0800, fancy fang wrote:
> However, I wonder why Unit Pixmap needs a system buffer and the system
> buffer is malloced in exaCreatePixmap_mixed instead of other places,
> such as exaDoPrepareAccess_mixed.

Sometimes an operation involving a solid colour can be optimised into a
simpler operation, or is unable to be accelerated at all.  In that case
it can be a win to keep it on the CPU, rather than allocating directly
on the GPU and then having to fetch it back.  Often, synchronising with
and fetching data from the GPU is very slow.

I would however remind the developers involved that malloc() and free()
have costs of their own.  As long as those costs are considered in the
design, that's fine.

-- 
------
From: Jonathan Morton
      jonathan.morton at movial.com




More information about the xorg-devel mailing list