[Pixman] [PATCH 3/3] Add an iterator that can fetch bilinearly scaled images
Søren Sandmann
sandmann at cs.au.dk
Sat Aug 3 11:32:00 PDT 2013
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
Søren
More information about the Pixman
mailing list