lkml.org 
[lkml]   [2013]   [Aug]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH V11 13/15] perf tools: expand perf_event__synthesize_sample()
    On Wed, Aug 14, 2013 at 03:48:35PM +0300, Adrian Hunter wrote:

    SNIP

    > index 81c170f..4c97f36 100644
    > --- a/tools/perf/util/evsel.c
    > +++ b/tools/perf/util/evsel.c
    > @@ -1389,7 +1389,6 @@ int perf_evsel__parse_sample(struct perf_evsel *evsel, union perf_event *event,
    > }
    >
    > if (type & PERF_SAMPLE_REGS_USER) {
    > - /* First u64 tells us if we have any regs in sample. */

    ;-)

    > OVERFLOW_CHECK_u64(array);
    > data->user_regs.abi = *array;

    SNIP

    > +
    > + if (type & PERF_SAMPLE_REGS_USER) {
    > + if (sample->user_regs.abi) {
    > + *array++ = sample->user_regs.abi;
    > + sz = hweight_long(sample_regs_user) * sizeof(u64);
    > + memcpy(array, sample->user_regs.regs, sz);
    > + array = (void *)array + sz;
    > + } else {
    > + *array++ = 0;
    > + }
    > + }

    Acked-by: Jiri Olsa <jolsa@redhat.com>


    \
     
     \ /
      Last update: 2013-08-14 19:21    [W:8.242 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site