[PATCH 4/4] EXA/evergreen/ni: accelerate PictOpOver with component alpha

Dave Airlie airlied at gmail.com
Mon Jul 22 15:51:29 PDT 2013


On Tue, Jul 23, 2013 at 8:42 AM, Grigori Goronzy <greg at chown.ath.cx> wrote:
> On 23.07.2013 00:30, Dave Airlie wrote:
>>
>> On Mon, Jul 22, 2013 at 2:06 PM, Grigori Goronzy <greg at chown.ath.cx>
>> wrote:
>>>
>>> Subpixel text rendering is typically done with a solid src and a
>>> pixmap mask. Traditionally, this cannot be accelerated in a single
>>> pass and requires two passes [1]. However, we can cheat a little
>>> with a constant blend color.
>>
>>
>> The hw should be able to do things in one pass with dual source blending
>> afaik.
>>
>
> Yes it can do that, and this was actually my first idea. However, dual
> source blending requires additional render target state setup, modifications
> to the shaders, and so on. It's likely also a bit slower than single source
> blending, after all the shader needs to export twice as much data.
>
> It might be worthwhile to get back to this to accelerate some of the other
> PictOps with component alpha, but using the constant blend color was the
> easier and faster solution for the common PictOpOver case. I think it's a
> nice trick, I wonder if any other driver implements it?

Oh yeah I'm not saying we shouldn't merge this, it looks like a great
idea for this case,
and is probably faster than dual source.

but yeah for the other cases I suspect a single pass is going to be
faster than two passes,
even with the extra overheads of dual exports.

Dave.


More information about the xorg-driver-ati mailing list