lkml.org 
[lkml]   [2002]   [Dec]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Intel P6 vs P7 system call performance
    On Tue, Dec 17, 2002 at 01:41:55PM -0800, H. Peter Anvin wrote:
    > > No, just take the number of context switches before and after the attempt
    > > to read the time of day.

    > How do you do that from userspace, atomically? A counter in the shared
    > page?

    Yup. You need some shared data for the TSC offset such anyways, so
    moving the context switch counter onto such a page won't be much of
    a problem. Using the %tr trick to get the CPU number would allow for
    some of these data structures to be per-cpu without incurring any LOCK
    overhead, too.

    -ben
    --
    "Do you seek knowledge in time travel?"
    -
    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: 2005-03-22 13:31    [W:4.213 / U:0.152 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site