[Mesa-dev] [PATCH 1/3] trace: Fix trace_context_transfer_unmap methods.
Jose Fonseca
jfonseca at vmware.com
Sat Jun 2 08:58:02 UTC 2018
If you lookup the declartion of buffer_subdata and texture_subdata,
you'll see the parameters differ for these two methods, except for the
very first two.
Yet trace_context_transfer_unmap was emitting the same parameters for
both.
But you're right, I left this half done somehow - I forgot to actually
emit the parameters to sub_data. I could swear I did it. Maybe I reset
it by accident. Sorry. I'll post a 2nd version after wards.
Jose
On 01/06/18 22:53, Roland Scheidegger wrote:
> I am a bit confused by this, so by the looks of it you only dump things
> (unchanged) for textures, so did it match there?
> Also, I don't really understand why it doesn't work for buffers neither,
> even if some parameters don't make sense there, but if it's a transfer
> this should still be correct?
>
> Roland
>
> Am 01.06.2018 um 20:58 schrieb Jose Fonseca:
>> The emitted buffer_subdata/texture_subdata call didn't match the
>> respective signatures.
>> ---
>> .../auxiliary/driver_trace/tr_context.c | 38 +++++++++----------
>> 1 file changed, 19 insertions(+), 19 deletions(-)
>>
>> diff --git a/src/gallium/auxiliary/driver_trace/tr_context.c b/src/gallium/auxiliary/driver_trace/tr_context.c
>> index 6d918d42a38..1c246b91bd8 100644
>> --- a/src/gallium/auxiliary/driver_trace/tr_context.c
>> +++ b/src/gallium/auxiliary/driver_trace/tr_context.c
>> @@ -1436,27 +1436,27 @@ trace_context_transfer_unmap(struct pipe_context *_context,
>> unsigned stride = transfer->stride;
>> unsigned layer_stride = transfer->layer_stride;
>>
>> - if (resource->target == PIPE_BUFFER)
>> + if (resource->target == PIPE_BUFFER) {
>> trace_dump_call_begin("pipe_context", "buffer_subdata");
>> - else
>> + } else {
>> trace_dump_call_begin("pipe_context", "texture_subdata");
>> -
>> - trace_dump_arg(ptr, context);
>> - trace_dump_arg(ptr, resource);
>> - trace_dump_arg(uint, level);
>> - trace_dump_arg(uint, usage);
>> - trace_dump_arg(box, box);
>> -
>> - trace_dump_arg_begin("data");
>> - trace_dump_box_bytes(tr_trans->map,
>> - resource,
>> - box,
>> - stride,
>> - layer_stride);
>> - trace_dump_arg_end();
>> -
>> - trace_dump_arg(uint, stride);
>> - trace_dump_arg(uint, layer_stride);
>> + trace_dump_arg(ptr, context);
>> + trace_dump_arg(ptr, resource);
>> + trace_dump_arg(uint, level);
>> + trace_dump_arg(uint, usage);
>> + trace_dump_arg(box, box);
>> +
>> + trace_dump_arg_begin("data");
>> + trace_dump_box_bytes(tr_trans->map,
>> + resource,
>> + box,
>> + stride,
>> + layer_stride);
>> + trace_dump_arg_end();
>> +
>> + trace_dump_arg(uint, stride);
>> + trace_dump_arg(uint, layer_stride);
>> + }
>>
>> trace_dump_call_end();
>>
>>
>
More information about the mesa-dev
mailing list