[Mesa-dev] [PATCH 1/3] gallium: split transfer_inline_write into buffer and texture callbacks
sroland at vmware.com
Fri Jul 22 23:31:49 UTC 2016
Am 22.07.2016 um 22:40 schrieb Marek Olšák:
> Would anybody from VMWare like to comment?
I didn't really feel compelled to ;-).
The change looks reasonable to me. The whole transfer_inline_write thing
is there to make things faster, so if it's help saving cpu cycles by
using two separate functions that looks good (plus, buffers and textures
are quite different indeed). (We'll have some code to adapt of course,
but this should be trivial.)
Roland Scheidegger <sroland at vmware.com>
> On Mon, Jul 18, 2016 at 2:25 PM, Marek Olšák <maraeo at gmail.com> wrote:
>> From: Marek Olšák <marek.olsak at amd.com>
>> to reduce the call indirections with u_resource_vtbl.
>> The worst call tree you could get was:
>> - u_transfer_inline_write_vtbl
>> - u_default_transfer_inline_write
>> - u_transfer_map_vtbl
>> - driver_transfer_map
>> - u_transfer_unmap_vtbl
>> - driver_transfer_unmap
>> That's 6 indirect calls. Some drivers only had 5. The goal is to have
>> 1 indirect call for drivers that care. The resource type can be determined
>> statically at most call sites.
>> The new interface is:
>> pipe_context::buffer_subdata(ctx, resource, usage, offset, size, data)
>> pipe_context::texture_subdata(ctx, resource, level, usage, box, data,
>> stride, layer_stride)
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
More information about the mesa-dev