LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* finding per-process hw interrupt counts
@ 2008-02-18 1:15 Vince Weaver
0 siblings, 0 replies; only message in thread
From: Vince Weaver @ 2008-02-18 1:15 UTC (permalink / raw)
is there a way to find out how many times a userspace program is forced to
context switch due to a hardware interrupt?
The reason for this:
I am measuring the retired instruction count of programs using performance
counters (perfmon2 patchset), and trying to find out where the
descrepancies compe from.
On x86, it seems to be:
reported_count = expected_count + 1*major_pagefaults + \
1*hardware_interrupts + known_errata + 1
I can get the pagefault info from getrusage(). The hardware_interrupts
count is my best guess at what is causing the rest, based on the LOC
field in /proc/interrupts. That's not per-process though.
Is this info available? If not, is it possible to patch the kernel to
make it so?
Thanks for any help
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-02-18 1:21 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-18 1:15 finding per-process hw interrupt counts Vince Weaver
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).