[cgl_discussion] Enhancements to mpstat utility

Howell, David P david.p.howell at intel.com
Thu Oct 9 12:34:22 PDT 2003


Another item for release 3, from a customer who is moving multi-threaded
APPs to Linux.

They reported using mpstat to help tune the locking in the original
environment, but were 

dismayed that there is no Linux equivalent or other tools for doing the
same.

 

After looking at the open source mpstat that is available for Red Hat
Linux, it just displays

the minimal level of processor utilization statistics
(processor/%user/%system/%idle/intr).

Other versions for Unix report additional information:

- Minor/Major faults

- Interprocessor cross calls

- Context switches

- System calls

- Process migrations from this processor

- Kernel lock statistics (Mutex stalls)

- Wait time

 

This customer said that the inability to use these tools on Linux was
hindering their ability

to tune their application effectively for Linux.

 

My guess is that the current Linux mpstat is exposing everything that is
available from the 

kernel, and that to do better will require additional statistics
gathering in the kernel as well 

as the hooks in the mpstat utility to display them. This may be hard to
sell to LKML.

 

While having all of this under on hood is likely best for the customer,
i.e. in mpstat, it would

seem reasonable if the functionality were offered through several tools;
I was thinking of the 

lockmeter framework and utilities for the kernel locking statistics.
Having a complete set of 

tools for determining bottlenecks would be very useful. Documentation
that describes how 

to use the utilities, and how to identify and debug real problems is
also needed.

 

For customers who are used to using these tools for tuning on other
Unixes, keeping as 

much of the presentation of the stats similar would help, but may be
difficult or impossible 

for Linux. 

 

Reference projects:

            http://freshmeat.net/projects/mpstat/?topic_id=862  -
Utility version used on Linux (?)

            LKML, for kernel changes to enable additional statistics

Documentation:

            - Using the mpstat load displayer (SCO)

            -
http://docs.sun.com/db/doc/806-0625/6j9vfilr4?q=mpstat&a=view 

            -
http://sunsite.uakom.sk/sunworldonline/swol-08-1998/swol-08-perf.html

 

 

These are my opinions and not official opinions of Intel Corp.

 

David Howell

Intel Corporation

Telco Server Development

Server Products Division

Voice: (803) 216-2359  Fax: (803) 216-2178

 

Intel Corporation

Columbia Design Center, CBA-1

100 Center Point Circle, Suite 210

Columbia, SC 29210

 

david.p.howell at intel.com

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.linux-foundation.org/pipermail/cgl_discussion/attachments/20031009/ebbc8003/attachment-0001.htm


More information about the cgl_discussion mailing list