lkml.org 
[lkml]   [2008]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] Performance Counters for Linux, v3

* stephane eranian <eranian@googlemail.com> wrote:

> Hi,
>
> Given the level of abstractions you are using for the API, and given
> your argument that the kernel can do the HW resource scheduling better
> than anybody else.
>
> What happens in the following test case:
>
> - 2-way system (cpu0, cpu1)
>
> - on cpu0, two processes P1, P2, each self-monitoring and counting event E1.
> Event E1 can only be measured on counter C1.
>
> - on cpu1, there is a cpu-wide session, monitoring event E1, thus using C1
>
> - the scheduler decides to migrate P1 onto CPU1. You now have a
> conflict on C1.
>
> How is this managed?

If there's a single unit of sharable resource [such as an event counter,
or a physical CPU], then there's just three main possibilities: either
user 1 gets it all, or user 2 gets it all, or they share it.

We've implemented the essence of these variants, with sharing the resource
being the sane default, and with the sysadmin also having a configuration
vector to reserve the resource to himself permanently. (There could be
more variations of this.)

What is your point?

Ingo


\
 
 \ /
  Last update: 2008-12-15 00:17    [W:0.172 / U:0.120 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site