[Pixman] [PATCH 3/3] Add an iterator that can fetch bilinearly scaled images

Siarhei Siamashka siarhei.siamashka at gmail.com
Sun Aug 4 16:53:15 PDT 2013


On Sat, 03 Aug 2013 20:32:00 +0200
sandmann at cs.au.dk (Søren Sandmann) wrote:

> Søren Sandmann <sandmann at cs.au.dk> writes:
> 
> >> Here the new C code appears to be slower for all scaling ratios.
> >> I suspect that a possible reason is the use of 64-bit arithmetic
> >> operations on a 32-bit processor.
> >>
> >> The performance of C code is generally more important for less
> >> common CPU architectures, because they are usually lacking special
> >> optimizations.
> >
> > Yeah, a slowdown like that is not really acceptable considering that x86
> > will rarely benefit from this code. I'll try to make a version with 32
> > bit arithmetic.
> 
> Okay, new version to follow - compared to the earlier one sent to the
> list, this one uses only 32 bit arithmetic when sizeof (long) <=
> 4. Compared to the version discussed on IRC, this version is somewhat
> faster because by storing the cached source lines in AGBR format (rather
> than ARGB), it avoids a bit of shift/mask activity.
> 
> The 64 bit version of this new version is now faster than the old C code
> at all scaling ratio. Various data is available here:
> 
>    http://people.freedesktop.org/~sandmann/separable.v2

Thanks a lot. This looks really good.

-- 
Best regards,
Siarhei Siamashka


More information about the Pixman mailing list