| The Gaudi Framework v29r1 (5cd95fa2)

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

Classes | Macros | Typedefs | Functions
pfmlib.h File Reference
`#include <inttypes.h>`
`#include <stdio.h>`
`#include <perfmon/pfmlib_comp.h>`
`#include <perfmon/pfmlib_os.h>`
Include dependency graph for pfmlib.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Classes
struct | pfmlib_regmask_t
struct | pfmlib_event_t
struct | pfmlib_reg_t
struct | pfmlib_input_param_t
struct | pfmlib_output_param_t
struct | pfmlib_options_t

## Macros
#define | PFMLIB_VERSION ( 3 << 16 | 9 )
#define | PFMLIB_MAJ_VERSION(v) ( ( v ) >> 16 )
#define | PFMLIB_MIN_VERSION(v) ( (v)&0xffff )
#define | PFMLIB_MAX_PMCS 512 /* maximum number of PMCS supported by the library */
#define | PFMLIB_MAX_PMDS 512 /* maximum number of PMDS supported by the library */
#define | PFM_PLM0 0x1 /* priv level 0 */
#define | PFM_PLM1 0x2 /* priv level 1 */
#define | PFM_PLM2 0x4 /* priv level 2 */
#define | PFM_PLM3 0x8 /* priv level 3 */
#define | PFMLIB_REG_MAX PFMLIB_MAX_PMDS
#define | __PFMLIB_REG_BV_BITS ( sizeof( pfmlib_regmask_bits_t ) << 3 )
#define | PFMLIB_BVSIZE(x) ( ( ( x ) + (__PFMLIB_REG_BV_BITS)-1 ) / __PFMLIB_REG_BV_BITS )
#define | PFMLIB_REG_BV PFMLIB_BVSIZE( PFMLIB_REG_MAX )
#define | PFMLIB_MAX_MASKS_PER_EVENT 48 /* maximum number of unit masks per event */
#define | PFMLIB_PFP_SYSTEMWIDE 0x1 /* indicate monitors will be used in a system-wide session */
#define | PFMLIB_NO_PMU -1 /* PMU unused (forced) */
#define | PFMLIB_UNKNOWN_PMU 0 /* type not yet known (dynamic) */
#define | PFMLIB_GEN_IA64_PMU 1 /* Intel IA-64 architected PMU */
#define | PFMLIB_ITANIUM_PMU 2 /* Intel Itanium */
#define | PFMLIB_ITANIUM2_PMU 3 /* Intel Itanium 2 */
#define | PFMLIB_MONTECITO_PMU 4 /* Intel Dual-Core Itanium 2 9000 */
#define | PFMLIB_AMD64_PMU 16 /* AMD AMD64 (K7, K8, Fam 10h) */
#define | PFMLIB_GEN_IA32_PMU 63 /* Intel architectural PMU for X86 */
#define | PFMLIB_I386_P6_PMU 32 /* Intel PIII (P6 core) */
#define | PFMLIB_PENTIUM4_PMU 33 /* Intel Pentium4/Xeon/EM64T */
#define | PFMLIB_COREDUO_PMU 34 /* Intel Core Duo/Core Solo */
#define | PFMLIB_I386_PM_PMU 35 /* Intel Pentium M */
#define | PFMLIB_CORE_PMU 36 /* obsolete, use PFMLIB_INTEL_CORE_PMU */
#define | PFMLIB_INTEL_CORE_PMU 36 /* Intel Core */
#define | PFMLIB_INTEL_PPRO_PMU 37 /* Intel Pentium Pro */
#define | PFMLIB_INTEL_PII_PMU 38 /* Intel Pentium II */
#define | PFMLIB_INTEL_ATOM_PMU 39 /* Intel Atom */
#define | PFMLIB_INTEL_NHM_PMU 40 /* Intel Nehalem */
#define | PFMLIB_INTEL_WSM_PMU 41 /* Intel Westmere */
#define | PFMLIB_MIPS_20KC_PMU 64 /* MIPS 20KC */
#define | PFMLIB_MIPS_24K_PMU 65 /* MIPS 24K */
#define | PFMLIB_MIPS_25KF_PMU 66 /* MIPS 25KF */
#define | PFMLIB_MIPS_34K_PMU 67 /* MIPS 34K */
#define | PFMLIB_MIPS_5KC_PMU 68 /* MIPS 5KC */
#define | PFMLIB_MIPS_74K_PMU 69 /* MIPS 74K */
#define | PFMLIB_MIPS_R10000_PMU 70 /* MIPS R10000 */
#define | PFMLIB_MIPS_R12000_PMU 71 /* MIPS R12000 */
#define | PFMLIB_MIPS_RM7000_PMU 72 /* MIPS RM7000 */
#define | PFMLIB_MIPS_RM9000_PMU 73 /* MIPS RM9000 */
#define | PFMLIB_MIPS_SB1_PMU 74 /* MIPS SB1/SB1A */
#define | PFMLIB_MIPS_VR5432_PMU 75 /* MIPS VR5432 */
#define | PFMLIB_MIPS_VR5500_PMU 76 /* MIPS VR5500 */
#define | PFMLIB_MIPS_ICE9A_PMU 77 /* SiCortex ICE9A */
#define | PFMLIB_MIPS_ICE9B_PMU 78 /* SiCortex ICE9B */
#define | PFMLIB_POWERPC_PMU 90 /* POWERPC */
#define | PFMLIB_CRAYX2_PMU 96 /* Cray X2 */
#define | PFMLIB_CELL_PMU 100 /* CELL */
#define | PFMLIB_PPC970_PMU 110 /* IBM PowerPC 970(FX,GX) */
#define | PFMLIB_PPC970MP_PMU 111 /* IBM PowerPC 970MP */
#define | PFMLIB_POWER3_PMU 112 /* IBM POWER3 */
#define | PFMLIB_POWER4_PMU 113 /* IBM POWER4 */
#define | PFMLIB_POWER5_PMU 114 /* IBM POWER5 */
#define | PFMLIB_POWER5p_PMU 115 /* IBM POWER5+ */
#define | PFMLIB_POWER6_PMU 116 /* IBM POWER6 */
#define | PFMLIB_POWER7_PMU 117 /* IBM POWER7 */
#define | PFMLIB_SPARC_ULTRA12_PMU 130 /* UltraSPARC I, II, IIi, and IIe */
#define | PFMLIB_SPARC_ULTRA3_PMU 131 /* UltraSPARC III */
#define | PFMLIB_SPARC_ULTRA3I_PMU 132 /* UltraSPARC IIIi and IIIi+ */
#define | PFMLIB_SPARC_ULTRA3PLUS_PMU 133 /* UltraSPARC III+ and IV */
#define | PFMLIB_SPARC_ULTRA4PLUS_PMU 134 /* UltraSPARC IV+ */
#define | PFMLIB_SPARC_NIAGARA1_PMU 135 /* Niagara-1 */
#define | PFMLIB_SPARC_NIAGARA2_PMU 136 /* Niagara-2 */
#define | PFMLIB_SUCCESS 0 /* success */
#define | PFMLIB_ERR_NOTSUPP -1 /* function not supported */
#define | PFMLIB_ERR_INVAL -2 /* invalid parameters */
#define | PFMLIB_ERR_NOINIT -3 /* library was not initialized */
#define | PFMLIB_ERR_NOTFOUND -4 /* event not found */
#define | PFMLIB_ERR_NOASSIGN -5 /* cannot assign events to counters */
#define | PFMLIB_ERR_FULL -6 /* buffer is full or too small */
#define | PFMLIB_ERR_EVTMANY -7 /* event used more than once */
#define | PFMLIB_ERR_MAGIC -8 /* invalid library magic number */
#define | PFMLIB_ERR_FEATCOMB -9 /* invalid combination of features */
#define | PFMLIB_ERR_EVTSET -10 /* incompatible event sets */
#define | PFMLIB_ERR_EVTINCOMP -11 /* incompatible event combination */
#define | PFMLIB_ERR_TOOMANY -12 /* too many events or unit masks */
#define | PFMLIB_ERR_IRRTOOBIG -13 /* code range too big */
#define | PFMLIB_ERR_IRREMPTY -14 /* empty code range */
#define | PFMLIB_ERR_IRRINVAL -15 /* invalid code range */
#define | PFMLIB_ERR_IRRTOOMANY -16 /* too many code ranges */
#define | PFMLIB_ERR_DRRINVAL -17 /* invalid data range */
#define | PFMLIB_ERR_DRRTOOMANY -18 /* too many data ranges */
#define | PFMLIB_ERR_BADHOST -19 /* not supported by host CPU */
#define | PFMLIB_ERR_IRRALIGN -20 /* bad alignment for code range */
#define | PFMLIB_ERR_IRRFLAGS -21 /* code range missing flags */
#define | PFMLIB_ERR_UMASK -22 /* invalid or missing unit mask */
#define | PFMLIB_ERR_NOMEM -23 /* out of memory */
#define | __PFMLIB_REGMASK_EL(g) ( ( g ) / __PFMLIB_REG_BV_BITS )
#define | __PFMLIB_REGMASK_MASK(g) ( ( (pfmlib_regmask_bits_t)1 ) << ( ( g ) % __PFMLIB_REG_BV_BITS ) )

## Typedefs
typedef unsigned long | pfmlib_regmask_bits_t
typedef int | pfm_err_t

## Functions
pfm_err_t | pfm_set_options (pfmlib_options_t *opt)
pfm_err_t | pfm_initialize (void)
pfm_err_t | pfm_list_supported_pmus (int(*pf)(const char *fmt,...))
pfm_err_t | pfm_get_pmu_name (char *name, int maxlen)
pfm_err_t | pfm_get_pmu_type (int *type)
pfm_err_t | pfm_get_pmu_name_bytype (int type, char *name, size_t maxlen)
pfm_err_t | pfm_is_pmu_supported (int type)
pfm_err_t | pfm_force_pmu (int type)
pfm_err_t | pfm_find_event (const char *str, unsigned int *idx)
pfm_err_t | pfm_find_event_byname (const char *name, unsigned int *idx)
pfm_err_t | pfm_find_event_bycode (int code, unsigned int *idx)
pfm_err_t | pfm_find_event_bycode_next (int code, unsigned int start, unsigned int *next)
pfm_err_t | pfm_find_event_mask (unsigned int event_idx, const char *str, unsigned int *mask_idx)
pfm_err_t | pfm_find_full_event (const char *str, pfmlib_event_t *e)
pfm_err_t | pfm_get_max_event_name_len (size_t *len)
pfm_err_t | pfm_get_num_events (unsigned int *count)
pfm_err_t | pfm_get_num_event_masks (unsigned int event_idx, unsigned int *count)
pfm_err_t | pfm_get_event_name (unsigned int idx, char *name, size_t maxlen)
pfm_err_t | pfm_get_full_event_name (pfmlib_event_t *e, char *name, size_t maxlen)
pfm_err_t | pfm_get_event_code (unsigned int idx, int *code)
pfm_err_t | pfm_get_event_mask_code (unsigned int idx, unsigned int mask_idx, unsigned int *code)
pfm_err_t | pfm_get_event_counters (unsigned int idx, pfmlib_regmask_t *counters)
pfm_err_t | pfm_get_event_description (unsigned int idx, char **str)
pfm_err_t | pfm_get_event_code_counter (unsigned int idx, unsigned int cnt, int *code)
pfm_err_t | pfm_get_event_mask_name (unsigned int event_idx, unsigned int mask_idx, char *name, size_t maxlen)
pfm_err_t | pfm_get_event_mask_description (unsigned int event_idx, unsigned int mask_idx, char **desc)
pfm_err_t | pfm_dispatch_events (pfmlib_input_param_t *p, void *model_in, pfmlib_output_param_t *q, void *model_out)
pfm_err_t | pfm_get_impl_pmcs (pfmlib_regmask_t *impl_pmcs)
pfm_err_t | pfm_get_impl_pmds (pfmlib_regmask_t *impl_pmds)
pfm_err_t | pfm_get_impl_counters (pfmlib_regmask_t *impl_counters)
pfm_err_t | pfm_get_num_pmds (unsigned int *num)
pfm_err_t | pfm_get_num_pmcs (unsigned int *num)
pfm_err_t | pfm_get_num_counters (unsigned int *num)
pfm_err_t | pfm_get_hw_counter_width (unsigned int *width)
pfm_err_t | pfm_get_version (unsigned int *version)
char * | pfm_strerror (int code)
pfm_err_t | pfm_get_cycle_event (pfmlib_event_t *e)
pfm_err_t | pfm_get_inst_retired_event (pfmlib_event_t *e)

## Macro Definition Documentation

#define __PFMLIB_REG_BV_BITS ( sizeof( pfmlib_regmask_bits_t ) << 3 )

Definition at line 70 of file pfmlib.h.

#define __PFMLIB_REGMASK_EL | ( |  | g | ) | ( ( g ) / __PFMLIB_REG_BV_BITS )

Definition at line 293 of file pfmlib.h.

#define __PFMLIB_REGMASK_MASK | ( |  | g | ) | ( ( (pfmlib_regmask_bits_t)1 ) << ( ( g ) % __PFMLIB_REG_BV_BITS ) )

Definition at line 294 of file pfmlib.h.

#define PFM_PLM0 0x1 /* priv level 0 */

Definition at line 50 of file pfmlib.h.

#define PFM_PLM1 0x2 /* priv level 1 */

Definition at line 51 of file pfmlib.h.

#define PFM_PLM2 0x4 /* priv level 2 */

Definition at line 52 of file pfmlib.h.

#define PFM_PLM3 0x8 /* priv level 3 */

Definition at line 53 of file pfmlib.h.

#define PFMLIB_AMD64_PMU 16 /* AMD AMD64 (K7, K8, Fam 10h) */

Definition at line 211 of file pfmlib.h.

#define PFMLIB_BVSIZE | ( |  | x | ) | ( ( ( x ) + (__PFMLIB_REG_BV_BITS)-1 ) / __PFMLIB_REG_BV_BITS )

Definition at line 71 of file pfmlib.h.

#define PFMLIB_CELL_PMU 100 /* CELL */

Definition at line 245 of file pfmlib.h.

#define PFMLIB_CORE_PMU 36 /* obsolete, use PFMLIB_INTEL_CORE_PMU */

Definition at line 217 of file pfmlib.h.

#define PFMLIB_COREDUO_PMU 34 /* Intel Core Duo/Core Solo */

Definition at line 215 of file pfmlib.h.

#define PFMLIB_CRAYX2_PMU 96 /* Cray X2 */

Definition at line 243 of file pfmlib.h.

#define PFMLIB_ERR_BADHOST -19 /* not supported by host CPU */

Definition at line 287 of file pfmlib.h.

#define PFMLIB_ERR_DRRINVAL -17 /* invalid data range */

Definition at line 285 of file pfmlib.h.

#define PFMLIB_ERR_DRRTOOMANY -18 /* too many data ranges */

Definition at line 286 of file pfmlib.h.

#define PFMLIB_ERR_EVTINCOMP -11 /* incompatible event combination */

Definition at line 278 of file pfmlib.h.

#define PFMLIB_ERR_EVTMANY -7 /* event used more than once */

Definition at line 274 of file pfmlib.h.

#define PFMLIB_ERR_EVTSET -10 /* incompatible event sets */

Definition at line 277 of file pfmlib.h.

#define PFMLIB_ERR_FEATCOMB -9 /* invalid combination of features */

Definition at line 276 of file pfmlib.h.

#define PFMLIB_ERR_FULL -6 /* buffer is full or too small */

Definition at line 273 of file pfmlib.h.

#define PFMLIB_ERR_INVAL -2 /* invalid parameters */

Definition at line 269 of file pfmlib.h.

#define PFMLIB_ERR_IRRALIGN -20 /* bad alignment for code range */

Definition at line 288 of file pfmlib.h.

#define PFMLIB_ERR_IRREMPTY -14 /* empty code range */

Definition at line 282 of file pfmlib.h.

#define PFMLIB_ERR_IRRFLAGS -21 /* code range missing flags */

Definition at line 289 of file pfmlib.h.

#define PFMLIB_ERR_IRRINVAL -15 /* invalid code range */

Definition at line 283 of file pfmlib.h.

#define PFMLIB_ERR_IRRTOOBIG -13 /* code range too big */

Definition at line 281 of file pfmlib.h.

#define PFMLIB_ERR_IRRTOOMANY -16 /* too many code ranges */

Definition at line 284 of file pfmlib.h.

#define PFMLIB_ERR_MAGIC -8 /* invalid library magic number */

Definition at line 275 of file pfmlib.h.

#define PFMLIB_ERR_NOASSIGN -5 /* cannot assign events to counters */

Definition at line 272 of file pfmlib.h.

#define PFMLIB_ERR_NOINIT -3 /* library was not initialized */

Definition at line 270 of file pfmlib.h.

#define PFMLIB_ERR_NOMEM -23 /* out of memory */

Definition at line 291 of file pfmlib.h.

#define PFMLIB_ERR_NOTFOUND -4 /* event not found */

Definition at line 271 of file pfmlib.h.

#define PFMLIB_ERR_NOTSUPP -1 /* function not supported */

Definition at line 268 of file pfmlib.h.

#define PFMLIB_ERR_TOOMANY -12 /* too many events or unit masks */

Definition at line 279 of file pfmlib.h.

#define PFMLIB_ERR_UMASK -22 /* invalid or missing unit mask */

Definition at line 290 of file pfmlib.h.

#define PFMLIB_GEN_IA32_PMU 63 /* Intel architectural PMU for X86 */

Definition at line 212 of file pfmlib.h.

#define PFMLIB_GEN_IA64_PMU 1 /* Intel IA-64 architected PMU */

Definition at line 207 of file pfmlib.h.

#define PFMLIB_I386_P6_PMU 32 /* Intel PIII (P6 core) */

Definition at line 213 of file pfmlib.h.

#define PFMLIB_I386_PM_PMU 35 /* Intel Pentium M */

Definition at line 216 of file pfmlib.h.

#define PFMLIB_INTEL_ATOM_PMU 39 /* Intel Atom */

Definition at line 221 of file pfmlib.h.

#define PFMLIB_INTEL_CORE_PMU 36 /* Intel Core */

Definition at line 218 of file pfmlib.h.

#define PFMLIB_INTEL_NHM_PMU 40 /* Intel Nehalem */

Definition at line 222 of file pfmlib.h.

#define PFMLIB_INTEL_PII_PMU 38 /* Intel Pentium II */

Definition at line 220 of file pfmlib.h.

#define PFMLIB_INTEL_PPRO_PMU 37 /* Intel Pentium Pro */

Definition at line 219 of file pfmlib.h.

#define PFMLIB_INTEL_WSM_PMU 41 /* Intel Westmere */

Definition at line 223 of file pfmlib.h.

#define PFMLIB_ITANIUM2_PMU 3 /* Intel Itanium 2 */

Definition at line 209 of file pfmlib.h.

#define PFMLIB_ITANIUM_PMU 2 /* Intel Itanium */

Definition at line 208 of file pfmlib.h.

#define PFMLIB_MAJ_VERSION | ( |  | v | ) | ( ( v ) >> 16 )

Definition at line 35 of file pfmlib.h.

#define PFMLIB_MAX_MASKS_PER_EVENT 48 /* maximum number of unit masks per event */

Definition at line 79 of file pfmlib.h.

#define PFMLIB_MAX_PMCS 512 /* maximum number of PMCS supported by the library */

Definition at line 41 of file pfmlib.h.

#define PFMLIB_MAX_PMDS 512 /* maximum number of PMDS supported by the library */

Definition at line 42 of file pfmlib.h.

#define PFMLIB_MIN_VERSION | ( |  | v | ) | ( (v)&0xffff )

Definition at line 36 of file pfmlib.h.

#define PFMLIB_MIPS_20KC_PMU 64 /* MIPS 20KC */

Definition at line 225 of file pfmlib.h.

#define PFMLIB_MIPS_24K_PMU 65 /* MIPS 24K */

Definition at line 226 of file pfmlib.h.

#define PFMLIB_MIPS_25KF_PMU 66 /* MIPS 25KF */

Definition at line 227 of file pfmlib.h.

#define PFMLIB_MIPS_34K_PMU 67 /* MIPS 34K */

Definition at line 228 of file pfmlib.h.

#define PFMLIB_MIPS_5KC_PMU 68 /* MIPS 5KC */

Definition at line 229 of file pfmlib.h.

#define PFMLIB_MIPS_74K_PMU 69 /* MIPS 74K */

Definition at line 230 of file pfmlib.h.

#define PFMLIB_MIPS_ICE9A_PMU 77 /* SiCortex ICE9A */

Definition at line 238 of file pfmlib.h.

#define PFMLIB_MIPS_ICE9B_PMU 78 /* SiCortex ICE9B */

Definition at line 239 of file pfmlib.h.

#define PFMLIB_MIPS_R10000_PMU 70 /* MIPS R10000 */

Definition at line 231 of file pfmlib.h.

#define PFMLIB_MIPS_R12000_PMU 71 /* MIPS R12000 */

Definition at line 232 of file pfmlib.h.

#define PFMLIB_MIPS_RM7000_PMU 72 /* MIPS RM7000 */

Definition at line 233 of file pfmlib.h.

#define PFMLIB_MIPS_RM9000_PMU 73 /* MIPS RM9000 */

Definition at line 234 of file pfmlib.h.

#define PFMLIB_MIPS_SB1_PMU 74 /* MIPS SB1/SB1A */

Definition at line 235 of file pfmlib.h.

#define PFMLIB_MIPS_VR5432_PMU 75 /* MIPS VR5432 */

Definition at line 236 of file pfmlib.h.

#define PFMLIB_MIPS_VR5500_PMU 76 /* MIPS VR5500 */

Definition at line 237 of file pfmlib.h.

#define PFMLIB_MONTECITO_PMU 4 /* Intel Dual-Core Itanium 2 9000 */

Definition at line 210 of file pfmlib.h.

#define PFMLIB_NO_PMU -1 /* PMU unused (forced) */

Definition at line 205 of file pfmlib.h.

#define PFMLIB_PENTIUM4_PMU 33 /* Intel Pentium4/Xeon/EM64T */

Definition at line 214 of file pfmlib.h.

#define PFMLIB_PFP_SYSTEMWIDE 0x1 /* indicate monitors will be used in a system-wide session */

Definition at line 120 of file pfmlib.h.

#define PFMLIB_POWER3_PMU 112 /* IBM POWER3 */

Definition at line 249 of file pfmlib.h.

#define PFMLIB_POWER4_PMU 113 /* IBM POWER4 */

Definition at line 250 of file pfmlib.h.

#define PFMLIB_POWER5_PMU 114 /* IBM POWER5 */

Definition at line 251 of file pfmlib.h.

#define PFMLIB_POWER5p_PMU 115 /* IBM POWER5+ */

Definition at line 252 of file pfmlib.h.

#define PFMLIB_POWER6_PMU 116 /* IBM POWER6 */

Definition at line 253 of file pfmlib.h.

#define PFMLIB_POWER7_PMU 117 /* IBM POWER7 */

Definition at line 254 of file pfmlib.h.

#define PFMLIB_POWERPC_PMU 90 /* POWERPC */

Definition at line 241 of file pfmlib.h.

#define PFMLIB_PPC970_PMU 110 /* IBM PowerPC 970(FX,GX) */

Definition at line 247 of file pfmlib.h.

#define PFMLIB_PPC970MP_PMU 111 /* IBM PowerPC 970MP */

Definition at line 248 of file pfmlib.h.

#define PFMLIB_REG_BV PFMLIB_BVSIZE( PFMLIB_REG_MAX )

Definition at line 72 of file pfmlib.h.

#define PFMLIB_REG_MAX PFMLIB_MAX_PMDS

Definition at line 66 of file pfmlib.h.

#define PFMLIB_SPARC_NIAGARA1_PMU 135 /* Niagara-1 */

Definition at line 261 of file pfmlib.h.

#define PFMLIB_SPARC_NIAGARA2_PMU 136 /* Niagara-2 */

Definition at line 262 of file pfmlib.h.

#define PFMLIB_SPARC_ULTRA12_PMU 130 /* UltraSPARC I, II, IIi, and IIe */

Definition at line 256 of file pfmlib.h.

#define PFMLIB_SPARC_ULTRA3_PMU 131 /* UltraSPARC III */

Definition at line 257 of file pfmlib.h.

#define PFMLIB_SPARC_ULTRA3I_PMU 132 /* UltraSPARC IIIi and IIIi+ */

Definition at line 258 of file pfmlib.h.

#define PFMLIB_SPARC_ULTRA3PLUS_PMU 133 /* UltraSPARC III+ and IV */

Definition at line 259 of file pfmlib.h.

#define PFMLIB_SPARC_ULTRA4PLUS_PMU 134 /* UltraSPARC IV+ */

Definition at line 260 of file pfmlib.h.

#define PFMLIB_SUCCESS 0 /* success */

Definition at line 267 of file pfmlib.h.

#define PFMLIB_UNKNOWN_PMU 0 /* type not yet known (dynamic) */

Definition at line 206 of file pfmlib.h.

#define PFMLIB_VERSION ( 3 << 16 | 9 )

Definition at line 34 of file pfmlib.h.

## Typedef Documentation

typedef int pfm_err_t

Definition at line 150 of file pfmlib.h.

typedef unsigned long pfmlib_regmask_bits_t

Definition at line 58 of file pfmlib.h.

## Function Documentation

pfm_err_t pfm_dispatch_events | ( | pfmlib_input_param_t * | p,
|  | void * | model_in,
|  | pfmlib_output_param_t * | q,
|  | void * | model_out
| ) |  |

pfm_err_t pfm_find_event | ( | const char * | str,
|  | unsigned int * | idx
| ) |  |

pfm_err_t pfm_find_event_bycode | ( | int | code,
|  | unsigned int * | idx
| ) |  |

pfm_err_t pfm_find_event_bycode_next | ( | int | code,
|  | unsigned int | start,
|  | unsigned int * | next
| ) |  |

pfm_err_t pfm_find_event_byname | ( | const char * | name,
|  | unsigned int * | idx
| ) |  |

pfm_err_t pfm_find_event_mask | ( | unsigned int | event_idx,
|  | const char * | str,
|  | unsigned int * | mask_idx
| ) |  |

pfm_err_t pfm_find_full_event | ( | const char * | str,
|  | pfmlib_event_t * | e
| ) |  |

pfm_err_t pfm_force_pmu | ( | int | type | ) |

pfm_err_t pfm_get_cycle_event | ( | pfmlib_event_t * | e | ) |

pfm_err_t pfm_get_event_code | ( | unsigned int | idx,
|  | int * | code
| ) |  |

pfm_err_t pfm_get_event_code_counter | ( | unsigned int | idx,
|  | unsigned int | cnt,
|  | int * | code
| ) |  |

pfm_err_t pfm_get_event_counters | ( | unsigned int | idx,
|  | pfmlib_regmask_t * | counters
| ) |  |

pfm_err_t pfm_get_event_description | ( | unsigned int | idx,
|  | char ** | str
| ) |  |

pfm_err_t pfm_get_event_mask_code | ( | unsigned int | idx,
|  | unsigned int | mask_idx,
|  | unsigned int * | code
| ) |  |

pfm_err_t pfm_get_event_mask_description | ( | unsigned int | event_idx,
|  | unsigned int | mask_idx,
|  | char ** | desc
| ) |  |

pfm_err_t pfm_get_event_mask_name | ( | unsigned int | event_idx,
|  | unsigned int | mask_idx,
|  | char * | name,
|  | size_t | maxlen
| ) |  |

pfm_err_t pfm_get_event_name | ( | unsigned int | idx,
|  | char * | name,
|  | size_t | maxlen
| ) |  |

pfm_err_t pfm_get_full_event_name | ( | pfmlib_event_t * | e,
|  | char * | name,
|  | size_t | maxlen
| ) |  |

pfm_err_t pfm_get_hw_counter_width | ( | unsigned int * | width | ) |

pfm_err_t pfm_get_impl_counters | ( | pfmlib_regmask_t * | impl_counters | ) |

pfm_err_t pfm_get_impl_pmcs | ( | pfmlib_regmask_t * | impl_pmcs | ) |

pfm_err_t pfm_get_impl_pmds | ( | pfmlib_regmask_t * | impl_pmds | ) |

pfm_err_t pfm_get_inst_retired_event | ( | pfmlib_event_t * | e | ) |

pfm_err_t pfm_get_max_event_name_len | ( | size_t * | len | ) |

pfm_err_t pfm_get_num_counters | ( | unsigned int * | num | ) |

pfm_err_t pfm_get_num_event_masks | ( | unsigned int | event_idx,
|  | unsigned int * | count
| ) |  |

pfm_err_t pfm_get_num_events | ( | unsigned int * | count | ) |

pfm_err_t pfm_get_num_pmcs | ( | unsigned int * | num | ) |

pfm_err_t pfm_get_num_pmds | ( | unsigned int * | num | ) |

pfm_err_t pfm_get_pmu_name | ( | char * | name,
|  | int | maxlen
| ) |  |

pfm_err_t pfm_get_pmu_name_bytype | ( | int | type,
|  | char * | name,
|  | size_t | maxlen
| ) |  |

pfm_err_t pfm_get_pmu_type | ( | int * | type | ) |

pfm_err_t pfm_get_version | ( | unsigned int * | version | ) |

pfm_err_t pfm_initialize | ( | void |  | ) |

pfm_err_t pfm_is_pmu_supported | ( | int | type | ) |

pfm_err_t pfm_list_supported_pmus | ( | int(*)(const char *fmt,...) | pf | ) |

pfm_err_t pfm_set_options | ( | pfmlib_options_t * | opt | ) |

char* pfm_strerror | ( | int | code | ) |