[Mesa-dev] [PATCH] r600g: track dirty registers better.
Benjamin BELLEC
b.bellec at gmail.com
Tue Apr 19 03:50:02 PDT 2011
Le 18/04/2011 16:37, Benjamin BELLEC a écrit :
> Le 18/04/2011 10:20, Dave Airlie a écrit :
>> On Mon, Apr 18, 2011 at 11:00 AM, Dave Airlie <airlied at gmail.com> wrote:
>>> From: Dave Airlie <airlied at redhat.com>
>>>
>>> This is a first step to decreasing the CPU usage, by decreasing how much
>>> stuff we pass to the GPU and hence to the kernel CS checker.
>>>
>>> This adds a check to see if the values we need to write are actually dirty,
>>> and avoids writing if they are. However certain register need to always
>>> be written so we add a new flag to say which ones should be always written
>>> if used. (Note this could probably be done cleaner with a larger refactoring,
>>> since I think the CONST_BUFFER_SIZE_PS/VS and CONST_CACHE_PS/VS might
>>> be better off as a special state).
>>>
>>> It also moves the need_bo to be a flags on the register now.
>>>
>>> With this, a frame of gears goes from emitting 3k dwords to emitting 2k dwords,
>>> and I'm sure it could get a lot smaller.
>>>
>>> TODO:
>>> Currently we flush if we have a BO, this could probably be improved.
>>> Drop the special flush flag and move the buffer size ps/vs to a special state.
>>>
>>
>> I've pushed a v2 of this to the r600g-dirty branch in my repo with
>> another couple of patches on top
>>
>> the v2 just fixes the evergreen paths.
>>
>> The other patches cause regressions, but decrease further the amount
>> of dwords per frame which should decrease time in the kernel parser,
>> just have to figure out the regressions.
>>
>> Dave.
>> _______________________________________________
>> mesa-dev mailing list
>> mesa-dev at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
> Hello,
>
> I just test your branch, it breaks the 3 apps I tested :
>
> - glxgears, I do not see gears. I can see them quickly by moving the
> window at the border of my screen
> - nexuiz-sdl : the menu is break. (not tested ingame)
> - etqw : the menu is break too. In game, I have "phantom" frame. This is
> hard to describe, and I have no screenshots to show you exactly. To sum
> up, I have the impression that the frames are mixed.
>
> I will test your future patches (if any).
>
> Benjamin
All is now fixed.
Also, I have 15.50 % of framerate improvements in nexuiz-sdl on my
system (x86 - RV770 - 1680*1050 - No HDR - No sound)
More information about the mesa-dev
mailing list