[Mesa-dev] [PATCH 1/6] blorp: Turn anv_CmdCopyBuffer into a blorp_buffer_copy() helper.

Jason Ekstrand jason at jlekstrand.net
Tue Aug 29 22:46:22 UTC 2017


On August 29, 2017 3:14:08 PM Chris Wilson <chris at chris-wilson.co.uk> wrote:

> Quoting Kenneth Graunke (2017-08-29 22:28:38)
>> Anvil already had code to copy between two buffer objects in the most
>> efficient way possible, using large bpp copies, then smaller bpp copies.
>>
>> This patch moves that logic into BLORP as blorp_buffer_copy(), so we
>> can reuse it in i965 as well.
>
> Just some food for thought...
>
> The render access pattern is terrible for wide linear buffers, as the
> pixel block ends up being scattered across many pages, thrashing the TLB.
> But if instead of telling it to copy as wide as possible, you just
> limited it to a stride of 4096/4 (if memory serves 4 is the largest
> pixel block height) then each pixel block is located inside just one
> page (and hopefully cluster across the eu, further reducing the stride
> may help if the spread ends up taller than wider).

Yes, some benchmarking would have to be done to truly substantiate Ken's 
claim.  I think you may be right that the access patterns aren't great.  If 
we hit the case where you do a one pixel tall blit, that's also not good.  
I think there is a lot of time that could be sink into making this more 
efficient.




More information about the mesa-dev mailing list