Specialize the fast_composite_scaled_nearest_* scalers to positive x units
authorSøren Sandmann Pedersen <ssp@redhat.com>
Wed, 17 Mar 2010 14:50:42 +0000 (10:50 -0400)
committerSøren Sandmann Pedersen <ssp@redhat.com>
Wed, 17 Mar 2010 15:14:20 +0000 (11:14 -0400)
commit265ea1fb4d05a920323f23a02f9dc379312bbdae
tree12a7e96ad2bda8a40f817c2680f14b73bd7fde4e
parent9cd1051523493e0926b146f05cdde34158391602
Specialize the fast_composite_scaled_nearest_* scalers to positive x units

This avoids a test in the inner loop, which improves performance
especially for tiled sources.

On x86-32, I get these results:

Before:
op=1, src_fmt=20028888, dst_fmt=20028888, speed=306.96 MPix/s (73.18 FPS)
op=1, src_fmt=20028888, dst_fmt=10020565, speed=102.67 MPix/s (24.48 FPS)
op=1, src_fmt=10020565, dst_fmt=10020565, speed=324.85 MPix/s (77.45 FPS)

After:
op=1, src_fmt=20028888, dst_fmt=20028888, speed=332.19 MPix/s (79.20 FPS)
op=1, src_fmt=20028888, dst_fmt=10020565, speed=110.41 MPix/s (26.32 FPS)
op=1, src_fmt=10020565, dst_fmt=10020565, speed=363.28 MPix/s (86.61 FPS)
pixman/pixman-fast-path.c