diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2010-05-10 09:39:44 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2010-05-10 10:36:14 +0100 |
commit | f52b6e832292c02c0010b19882e38e1097beeda0 (patch) | |
tree | 9da0d96b7d8a1917f0506095928bf5158d9e5e2f /src/i830.h | |
parent | 848ab66384508c3ad3e5fb4884e4527f3ebd3bde (diff) |
uxa: Rearrange checking and preparing of composite textures.
x11perf regression caused by 2D driver
https://bugs.freedesktop.org/show_bug.cgi?id=28047
caused by
commit a7b800513fcc94e063dfd68d2f63b6bab7fae47d
uxa: Extract sub-region from in-memory buffers.
The issue is that as we extract the region prior to checking whether the
composite can in fact be accelerated, we perform expensive surplus
operations. This is particularly noticeable for ComponentAlpha text,
such as rgb10text. The solution here is to rearrange the
check_composite() prior to acquiring the sources, and only extracting
the subregion if the render path can not actually handle the texture.
Performance (on PineView):
a7b800513^: aa=68600 glyphs/s, rgb=29900 glyphs/s
a7b800513: aa=65700 glyphs/s, rgb=13200 glyphs/s
now: aa=66800 glyph/s, rgb=28800 glyphs/s
The residual lossage seems to be from the extra function call and
dixPrivate lookups. Hmm. More warning is the extremely low performance,
however the results are consistent so the improvement looks real...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/i830.h')
-rw-r--r-- | src/i830.h | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -447,8 +447,9 @@ void i830_set_gem_max_sizes(ScrnInfoPtr scrn); drm_intel_bo *i830_allocate_framebuffer(ScrnInfoPtr scrn); /* i830_render.c */ -Bool i830_check_composite(int op, PicturePtr sourcec, PicturePtr mask, +Bool i830_check_composite(int op, PicturePtr source, PicturePtr mask, PicturePtr dest); +Bool i830_check_composite_texture(ScreenPtr screen, PicturePtr picture); Bool i830_prepare_composite(int op, PicturePtr sourcec, PicturePtr mask, PicturePtr dest, PixmapPtr sourcecPixmap, PixmapPtr maskPixmap, PixmapPtr destPixmap); @@ -460,6 +461,7 @@ void i830_done_composite(PixmapPtr dest); /* i915_render.c */ Bool i915_check_composite(int op, PicturePtr sourcec, PicturePtr mask, PicturePtr dest); +Bool i915_check_composite_texture(ScreenPtr screen, PicturePtr picture); Bool i915_prepare_composite(int op, PicturePtr sourcec, PicturePtr mask, PicturePtr dest, PixmapPtr sourcecPixmap, PixmapPtr maskPixmap, PixmapPtr destPixmap); @@ -473,6 +475,7 @@ void gen4_render_state_init(ScrnInfoPtr scrn); void gen4_render_state_cleanup(ScrnInfoPtr scrn); Bool i965_check_composite(int op, PicturePtr sourcec, PicturePtr mask, PicturePtr dest); +Bool i965_check_composite_texture(ScreenPtr screen, PicturePtr picture); Bool i965_prepare_composite(int op, PicturePtr sourcec, PicturePtr mask, PicturePtr dest, PixmapPtr sourcecPixmap, PixmapPtr maskPixmap, PixmapPtr destPixmap); |