[cairo] towards 24.8

Carl Worth cworth at cworth.org
Mon Jun 18 21:14:33 PDT 2007


On Mon, 18 Jun 2007 13:27:05 -0700, Vladimir Vukicevic wrote:
> So I've got this working!  The current work in progress is in the 
> fixed-24-8 branch in my tree 
> (git://git.cairographics.org/~vladimir/cairo I believe).

I haven't looked at the code yet, but Vladimir asked me to take a
quick look at the performance impact. So I compared current HEAD
(02f753c2) to what's currently in his fixed-24-8 branch (7ecff8b3).

He was expecting no speedups, but perhaps some slowdown due to
copying/converting from 24.8 to pixman/X's 16.16.

Here are the results I got from several runs (that is, I kept running
things until the results stopped changing).

I'm not sure how meaningful things are here. Some comments:

 * The pattern_create_radial test does stress the double_to_fixed
   conversion code, and that has certainly changed, (but only in which
   magic numbers are used, not the arithmetic, right?). But also, the
   standard deviation values are larger than the performance difference
   for some of those, (though, again, I couldn't make these speedups go
   away no matter how many times I ran the test). Anyone care to look at
   the resulting assembly code for double_to_fixed and guess if a speedup
   is possible?

 * It's strange to see the rectangles test as both a speedup and as a
   slowdown, (but note that it's reporting a speedup for xlib and a
   slowdown for the image backend). Any theories for that?

 * The 10% slowdown for paint seems the most worrisome. Perhaps with a
   quick look at some profiles for that.

All in all, it may be that the performance impact isn't severe. But
cairo_paint with either a solid or an image surface onto an image
surface seems common enough to warrant another look at least.

-Carl

old: f01e9aa1f1058f738d550baaeae39060fe81f806-df22308f8f9f1823f9adb0734461e7f0496162e1-59f72768dbe5c8d660a2e74c7e6dc792ebebed33
new: f01e9aa1f1058f738d550baaeae39060fe81f806-e1b898dd5fe2dad774bb3ab5a46371244d5e2468-59f72768dbe5c8d660a2e74c7e6dc792ebebed33
Speedups
========
image-rgb       pattern_create_radial-16     3.66 10.72% ->   3.38 10.09%:  1.17x speedup
▏
image-rgba      pattern_create_radial-16     3.41 21.15% ->   3.09 15.01%:  1.12x speedup
▏
 xlib-rgb       pattern_create_radial-16     3.94 2.36% ->   3.54 2.99%:  1.11x speedup
▏
 xlib-rgb                  rectangles-512   10.43 4.05% ->  10.47 8.45%:  1.11x speedup
▏
 xlib-rgba      pattern_create_radial-16     3.93 3.33% ->   3.54 0.50%:  1.11x speedup
▏
image-rgb    mosaic_tessellate_curves-800   77.78 0.66% ->  73.17 0.84%:  1.07x speedup
▏
 xlib-rgb           long-dashed-lines-512   67.99 1.01% ->  63.50 0.87%:  1.07x speedup
▏
image-rgb           long-dashed-lines-512   69.52 1.41% ->  65.23 0.87%:  1.07x speedup
▏
image-rgba          long-dashed-lines-512   69.49 1.43% ->  65.04 0.80%:  1.06x speedup

 xlib-rgba   mosaic_tessellate_curves-800   77.97 0.89% ->  73.69 0.74%:  1.06x speedup

image-rgba   mosaic_tessellate_curves-800   77.83 0.70% ->  73.39 0.69%:  1.06x speedup

 xlib-rgba          long-dashed-lines-512   69.15 1.27% ->  65.44 0.97%:  1.06x speedup

 xlib-rgb    mosaic_tessellate_curves-800   77.65 0.64% ->  73.73 0.64%:  1.06x speedup

Slowdowns
=========
image-rgba  paint_similar_rgba_source-256    0.08 6.90% ->   0.11 17.46%:  1.12x slowdown
▏
image-rgb      paint_solid_rgb_source-512    0.81 9.19% ->   0.77 3.39%:  1.10x slowdown
▏
image-rgb        paint_solid_rgb_over-512    0.82 10.13% ->   0.78 5.66%:  1.09x slowdown
▏
image-rgb     paint_solid_rgba_source-512    0.81 8.72% ->   0.77 3.03%:  1.09x slowdown
▏
image-rgb                  rectangles-512    3.61 3.22% ->   3.86 2.60%:  1.07x slowdown
▏
image-rgba                 rectangles-512    3.61 2.81% ->   3.83 2.56%:  1.05x slowdown

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://cairographics.org/archives/cairo/attachments/20070618/602c6356/attachment.pgp 


More information about the cairo mailing list