lkml.org 
[lkml]   [2012]   [May]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [GIT PULL 0/8] Annotation weekly ponies delivery
    Date
    Hi,

    On Tue, 15 May 2012 00:06:25 +0900, Namhyung Kim wrote:
    > 2012-05-14 (월), 13:55 +0200, Ingo Molnar:
    >> Another detail seems to be that the bug takes per-task-inherited
    >> profiling. Doing:
    >>
    >> perf record -a -e cycles:pp make -j64 bzImage
    >>
    >> produces the expected number of events. Without the '-a' the bug
    >> Linus found triggers.
    >>
    >> Similarly, 'perf top' does not trigger the bug - because it's
    >> using per CPU, not per task (inherited) profiling.
    >>
    >
    > perf_evlist__config_attrs() has this:
    >
    > if (evlist->cpus->map[0] < 0)
    > opts->no_inherit = true;
    >
    > meaning that per task profiling won't enable event inheritance. I don't
    > know why it's needed though.

    I found this on commit 5d2cd90922c7 ("perf evsel: Fix use of inherit"):

    - /*
    - * Don't allow mmap() of inherited per-task counters. This
    - * would create a performance issue due to all children writing
    - * to the same buffer.
    - *
    - * FIXME:
    - * Proper fix is not to pass 'inherit' to perf_evsel__open*,
    - * but a 'flags' parameter, with 'group' folded there as well,
    - * then introduce a PERF_O_{MMAP,GROUP,INHERIT} enum, and if
    - * O_MMAP is set, emit a warning if cpu < 0 and O_INHERIT is
    - * set. Lets go for the minimal fix first tho.
    - */
    - evsel->attr.inherit = (cpus->map[cpu] >= 0) && inherit;

    Hmm.. still don't know what to do then.

    Thanks,
    Namhyung
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2012-05-15 08:41    [W:0.028 / U:59.768 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site