That's not true. PIPE_TRANSFER_DISCARD_WHOLE_RESOURCE does not copy
data in radeon drivers. It really does what st/mesa does - it creates
a new buffer and throws away the old one, which doesn't take any GPU
bandwidth. Doing that at a lower level should be faster in theory (+
drivers have multiple options how to implement the discarding).

Only PIPE_TRANSFER_DISCARD_RANGE copies data in radeon drivers, which
is not used here.

Marek

On Wed, Apr 17, 2013 at 8:15 PM, Eric Anholt <e...@anholt.net> wrote:
> Marek Olšák <mar...@gmail.com> writes:
>
>> The next patch makes sure _NEW_BUFFER_OBJECT is not needlessly set
>> for this code.
>
> This seems like a pretty dubious optimization -- on UMA systems you're
> increasing the memory bandwidth usage in the "&& data" case, and only
> trying to eliminate update_array_object_max_element, which also happens
> with _NEW_PROGRAM (I bet it's true every time that a _NEW_BUFFER_OBJECT
> was flagged, anyway).
>
> In short, for the Mesa core change, I'd like to see some actual
> performance justification on this one.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to