sna: Further refine choice of placement when uploading source data.

The goal is cheaply spot a simple copy operation that can be performed
on the CPU without having to load both parties onto the GPU.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Chris Wilson 2012-06-17 17:01:12 +01:00
parent 5a675b61f2
commit 7905ddae1d
1 changed files with 1 additions and 5 deletions

View File

@ -123,11 +123,7 @@ static inline Bool
unattached(DrawablePtr drawable)
{
struct sna_pixmap *priv = sna_pixmap_from_drawable(drawable);
if (priv == NULL || DAMAGE_IS_ALL(priv->cpu_damage))
return true;
return priv->gpu_bo == NULL && priv->cpu_bo == NULL;
return priv == NULL || (priv->gpu_damage == NULL && priv->cpu_damage);
}
static inline Bool