Performance-Monitoring Counters Library, for Intel/AMD Processors and Linux
This example introduces
   rabbit command-line options -version -processor
                               -Verbose -alignment -Measure [0|1|2]

Return to Main Menu


Command-Line Options -processor -version Print information about the processor, library version, and rabbit version. -version subsumes -processor. Use the command pmc_query to print more information about the /dev/pmc module. -Verbose Print internal function names to stderr as the functions are called. For developers and the insatiably curious; to be avoided. The library must have been compiled with -DPMC_VERBOSE. -alignment Print information about the size and alignment of internal data structures. For developers and the insatiably curious; to be avoided. The library must have been compiled with -DPMC_CHECK_ALIGNMENT=1. -Measure [0|1|2] Print information about the number of cycles and events used by some parts of the library itself. The option usage is similar to -Stat. For developers and the insatiably curious; to be avoided. The library must have been compiled with -DPMC_MEASURE. Additional information about the cost of low-level operations can be obtained from pmc_test.c when the library is compiled with -DPMC_ALLOW_SYSTEM_TEST.
Implementation Notes Intel's backward compatibility among processors makes it relatively easy to compile for one processor type and run on another. This can lead rabbit astray, with its extensive processor-dependence for events selected at run-time. Use 'rabbit -v' to verify that the library was compiled for the processor in use. Use 'rabbit -g 0 date' to verify that the device driver for /dev/pmc was also compiled properly; an error message is issued if there is a compatibility problem. Other than the Advanced Micro Devices Athlon, competing processors from AMD, VIA/Cyrix, etc., have not been considered, nor has any other architecture. No provision is made for a multiprocessor system. No provision is made for operating systems other than Linux. As usual for hardware performance counters that are not part of process state, measurements should be taken on an otherwise idle system. The activity of other processes, especially the OS kernel and daemons, cannot be excluded except indirectly with the --user and --os options, or by modifying the OS kernel. It is not clear what will happen (other than general malfunctions) if the OS or another program also manipulates the performance-monitoring counters by some other mechanism.

Performance-Monitoring Counters Library, for Intel/AMD Processors and Linux
Author: Don Heller, dheller@scl.ameslab.gov
Last revised: 30 October 2000