Re: Keeping track of entering and leaving the kernel

From: Chris Wedgwood (cw@f00f.org)
Date: Thu Apr 20 2000 - 18:26:11 EST


> I am trying to figure out how to modify the kernel such that I can
> keep track of when code inside the kernel is run. In other words, I
> would like to insert a piece of code that gets called when there is
> a transition from user mode to kernel mode and vice versa. I am
> using a recent version of the 2.3 kernel.

Under intel there are various msr that can count various events for
ring 0 and ring 3 (you have two counters which you can configure). I
guess you should be able to count ring 3 cycles vs ring 0 cycles.

-cw

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



This archive was generated by hypermail 2b29 : Sun Apr 23 2000 - 21:00:18 EST