LIBPFM(3) Linux Programmer's Manual LIBPFM(3)
pfm_initialize - initialize library
#include <perfmon/pfmlib.h> int pfm_initialize(void);
This is the first function that a program must call otherwise the library will not operate. This function probes the underlying hardware looking for valid PMU event tables to activate. Multiple distinct PMU tables may be activated at the same time. The function must be called only once. If the function is called more than once, it does not execute the initialization multiple times, it simply returns the same value as for the first call.
The function returns whether or not it was successful, i.e., at least one PMU was activated. A return value of PFMLIB_SUCCESS indicates success, otherwise the value is an error code.
PFMLIB_ERR_NOTSUPP No PMU was activated.
Stephane Eranian <firstname.lastname@example.org>
This page is part of the perfmon2 (a performance monitoring library) project. Information about the project can be found at ⟨http://perfmon2.sourceforge.net/⟩. If you have a bug report for this manual page, send it to email@example.com. This page was obtained from the project's upstream Git repository ⟨git://git.code.sf.net/p/perfmon2/libpfm4 perfmon2-libpfm4⟩ on 2021-04-01. (At that time, the date of the most recent commit that was found in the repository was 2021-03-23.) If you discover any rendering problems in this HTML version of the page, or you believe there is a better or more up-to-date source for the page, or you have corrections or improvements to the information in this COLOPHON (which is not part of the original manual page), send a mail to firstname.lastname@example.org September, 2009 LIBPFM(3)
Pages that refer to this page: libpfm(3)