lkml.org 
[lkml]   [2008]   [Dec]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [patch] Performance Counters for Linux, v3
    >        /*
    > * Special "software" counters provided by the kernel, even if
    > * the hardware does not support performance counters. These
    > * counters measure various physical and sw events of the
    > * kernel (and allow the profiling of them as well):
    > */
    > PERF_COUNT_CPU_CLOCK = -1,
    > PERF_COUNT_TASK_CLOCK = -2,
    > /*
    > * Future software events:
    > */
    > /* PERF_COUNT_PAGE_FAULTS = -3,
    > PERF_COUNT_CONTEXT_SWITCHES = -4, */

    ...
    > +[ Note: more hw_event_types are supported as well, but they are CPU
    > + specific and are enumerated via /sys on a per CPU basis. Raw hw event
    > + types can be passed in as negative numbers. For example, to count
    > + "External bus cycles while bus lock signal asserted" events on Intel
    > + Core CPUs, pass in a -0x4064 event type value. ]

    It looks like you have an overlap here. You are using some negative numbers
    to denote your special software events, but also as "raw" hardware events.
    What if these conflict?

    -Tony


    \
     
     \ /
      Last update: 2008-12-11 20:13    [W:2.322 / U:1.308 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site