Re: [PATCH] perf_events: fix ordering bug in perf_output_sample()

From: Stephane Eranian
Date: Thu Mar 18 2010 - 17:29:15 EST


On Thu, Mar 18, 2010 at 7:33 PM, Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
> On Thu, 2010-03-18 at 14:42 +0200, Stephane Eranian wrote:
>> Â Â Â In order to parse a sample correctly based on the information
>> Â Â Â requested via sample_type, the kernel needs to save each component
>> Â Â Â in a known order. There is no type value saved with each component.
>> Â Â Â The current convention is that each component is saved according to
>> Â Â Â the order in enum perf_event_sample_format. But perf_output_sample()
>> Â Â Â was not completely following this convention, thereby making samples
>> Â Â Â impossible to parse without internal kernel knowledge.
>>
>> Â Â Â This patch puts things in the right order.
>
> NAK, not so actually, its in the order specified in the
> PERF_RECORD_SAMPLE comment.
>
And why is that order different than the one in the enum?
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/