xf86-video-intel: 2 commits - src/sna/sna_accel.c
Chris Wilson
ickle at kemper.freedesktop.org
Thu Sep 26 01:31:16 PDT 2013
src/sna/sna_accel.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
New commits:
commit 8ef851b223253c38e6367efdeff6b4d551cd2b6b
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Wed Sep 25 15:07:48 2013 +0100
sna: Promote self-copies to the GPU
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 38288ee..9f0a4e4 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -4865,6 +4865,8 @@ sna_self_copy_boxes(DrawablePtr src, DrawablePtr dst, GCPtr gc,
int alu = gc ? gc->alu : GXcopy;
int16_t tx, ty;
+ assert(pixmap == get_drawable_pixmap(dst));
+
assert(RegionNumRects(region));
if (((dx | dy) == 0 && alu == GXcopy))
return;
@@ -4914,8 +4916,14 @@ sna_self_copy_boxes(DrawablePtr src, DrawablePtr dst, GCPtr gc,
if (!DAMAGE_IS_ALL(priv->gpu_damage)) {
assert(!priv->clear);
- RegionTranslate(region, tx, ty);
- sna_damage_add(&priv->gpu_damage, region);
+ if (priv->cpu_bo == NULL) {
+ sna_damage_all(&priv->gpu_damage,
+ pixmap->drawable.width,
+ pixmap->drawable.height);
+ } else {
+ RegionTranslate(region, tx, ty);
+ sna_damage_add(&priv->gpu_damage, region);
+ }
}
assert_pixmap_damage(pixmap);
} else {
commit 1c7df83ca734c3d4206539c65d6f7a5c10537aa6
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Wed Sep 25 15:07:24 2013 +0100
sna: Micro-optimise copies
Defer the read of the fExpose bit until we need it.
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 7c03c61..38288ee 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -5825,7 +5825,7 @@ sna_do_copy(DrawablePtr src, DrawablePtr dst, GCPtr gc,
region.extents.y2 = clamp(region.extents.y2, sy - dy);
src_extents = region.extents;
- expose = gc->fExpose;
+ expose = true;
if (region.extents.x1 < src->x)
region.extents.x1 = src->x;
@@ -5888,7 +5888,7 @@ sna_do_copy(DrawablePtr src, DrawablePtr dst, GCPtr gc,
/* Pixmap sources generate a NoExposed (we return NULL to do this) */
clip = NULL;
- if (expose)
+ if (expose && gc->fExpose)
clip = miHandleExposures(src, dst, gc,
sx - src->x, sy - src->y,
width, height,
More information about the xorg-commit
mailing list