[Pixman] Resurrecting: Added fast path for "pad" type repeats

Pekka Paalanen ppaalanen at gmail.com
Thu Apr 24 02:28:10 PDT 2014

On Tue, 22 Apr 2014 03:38:36 +0200
soren.sandmann at gmail.com (Søren Sandmann) wrote:

> Pekka Paalanen <ppaalanen at gmail.com> writes:
> > Hi,
> >
> > this thread started from
> > http://lists.freedesktop.org/archives/pixman/2013-February/002619.html
> > and continued in
> > http://lists.freedesktop.org/archives/pixman/2013-March/002677.html
> >
> > I'd like to hear what the thoughts of it are now, more questions
> > below.
> >
> >
> > On Wed, 13 Feb 2013 08:37:06 +0100
> > sandmann at cs.au.dk (Søren Sandmann) wrote:
> >
> >> I pushed the first patch to master. For this one, did you try
> >> comparing Chris' patch to your on ARMv6? Also, did we ever find
> >> out whether it was a bug in Firefox. I'm still somewhat skeptical
> >> that it's intended for a PAD image to be accessed so far out of
> >> bounds.
> >
> > What is the "Chris' patch", has it been merged?
> >
> > Do you still think there is a bug in Firefox, and the (trimmed)
> > Cairo traces are therefore invalid for PAD type repeats?
> The "Chris' patch" is this:
>     http://lists.freedesktop.org/archives/pixman/2013-January/002572.html
> I still believe what I wrote here:
>     http://lists.freedesktop.org/archives/pixman/2013-January/002600.html
> that an operation where
>      - the repeat mode is PAD
>      - the transformation is identity
>      - the source image is smaller than the destination (but it is
> not a 1 x n image)
> suggests that something suboptimal is going on at a higher level than
> pixman because the visual results will be an image surrounded by weird
> horizontal and vertical stripes, which is not normally desirable. And
> if I remember correctly, the firefox-chalkboard source image is
> actually some kind of noise mask that really looks like it should be
> used with repeat=NORMAL, not repeat=PAD.

I agree with your general rationale.

> Still, if this operation is being generated by Firefox (and I'd like
> to make sure that this is not just an artefact of cairo-trace or
> something like that), pixman should make it fast, so I am not opposed
> to the general idea of optimizing it. So a good patch would be able
> to make it upstream.

Very good. I don't think we will be running Firefox on RPi too soon, as
we are concentrating on Epiphany (Web) at the moment.

> Sorry if this is an unsatisfactory answer.

Not at all, it was quite enlightening.

As far as I understand, the only case where we could show a significant
improvement was that Cairo trace from Firefox, where it is questionable
if it is a valid real-world scenario at all, at least in the way
replaying the trace uses Pixman.

I think we will leave this matter be, until we find another case where
the PAD or similar optimizations would be useful.


More information about the Pixman mailing list