Measuring per thread CPU consumption & others statistics for NPTL

From: Peter Zaitsev
Date: Sun Nov 16 2003 - 11:12:23 EST


Dear Kernel developers,

I would wish to add to MySQL profiling of CPU and system usage, which
would allow for example to see amount of system/user CPU needed to
process particular query as well as amount of IO needed.

With LinuxThreads I probably can use times() or getrusage() for this
purpose, as Threads share a lot of infrastructure with processes.

This however would not work with NPTL threads.


Are there any ways to get similar information for thread rather than
process ?

Second question is about accuracy - Is any way to get system/user CPU
consumption information with more than 1/100 sec accuracy ?

Thank you for your advices.

--
Peter Zaitsev, Full-Time Developer
MySQL AB, www.mysql.com

Are you MySQL certified? www.mysql.com/certification

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