PAPI 7.1.0.0
Loading...
Searching...
No Matches
pfmlib_gen_ia32_priv.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2006-2007 Hewlett-Packard Development Company, L.P.
3 * Contributed by Stephane Eranian <eranian@hpl.hp.com>
4 *
5 * Permission is hereby granted, free of charge, to any person obtaining a copy
6 * of this software and associated documentation files (the "Software"), to deal
7 * in the Software without restriction, including without limitation the rights
8 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
9 * of the Software, and to permit persons to whom the Software is furnished to do so,
10 * subject to the following conditions:
11 *
12 * The above copyright notice and this permission notice shall be included in all
13 * copies or substantial portions of the Software.
14 *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
16 * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
17 * PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
18 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
19 * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE
20 * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 *
22 * This file is part of libpfm, a performance monitoring support library for
23 * applications on Linux/ia64.
24 */
25#ifndef __PFMLIB_GEN_IA32_PRIV_H__
26#define __PFMLIB_GEN_IA32_PRIV_H__
27
28#define PFMLIB_GEN_IA32_MAX_UMASK 16
29
30typedef struct {
31 char *pme_uname; /* unit mask name */
32 char *pme_udesc; /* event/umask description */
33 unsigned int pme_ucode; /* unit mask code */
35
36typedef struct {
37 char *pme_name; /* event name */
38 char *pme_desc; /* event description */
39 unsigned int pme_code; /* event code */
40 unsigned int pme_numasks; /* number of umasks */
41 unsigned int pme_flags; /* flags */
42 unsigned int pme_fixed; /* fixed counter index, < FIXED_CTR0 if unsupported */
43 pme_gen_ia32_umask_t pme_umasks[PFMLIB_GEN_IA32_MAX_UMASK]; /* umask desc */
45
46/*
47 * pme_flags value
48 */
49#define PFMLIB_GEN_IA32_UMASK_COMBO 0x01 /* unit mask can be combined (default exclusive) */
50
51typedef struct {
52 unsigned int version:8;
53 unsigned int num_cnt:8;
54 unsigned int cnt_width:8;
55 unsigned int ebx_length:8;
56} pmu_eax_t;
57
58typedef struct {
59 unsigned int num_cnt:6;
60 unsigned int cnt_width:6;
61 unsigned int reserved:20;
62} pmu_edx_t;
63
64typedef struct {
65 unsigned int no_core_cycle:1;
66 unsigned int no_inst_retired:1;
67 unsigned int no_ref_cycle:1;
68 unsigned int no_llc_ref:1;
69 unsigned int no_llc_miss:1;
70 unsigned int no_br_retired:1;
71 unsigned int no_br_mispred_retired:1;
72 unsigned int reserved:25;
73} pmu_ebx_t;
74
75#endif /* __PFMLIB_GEN_IA32_PRIV_H__ */
#define PFMLIB_GEN_IA32_MAX_UMASK
char * pme_name
unsigned int pme_code
unsigned int pme_numasks
unsigned int pme_fixed
char * pme_desc
unsigned int pme_flags
unsigned int version
unsigned int cnt_width
unsigned int num_cnt
unsigned int ebx_length
unsigned int no_ref_cycle
unsigned int no_br_retired
unsigned int no_inst_retired
unsigned int no_llc_miss
unsigned int no_core_cycle
unsigned int no_llc_ref
unsigned int reserved
unsigned int no_br_mispred_retired
unsigned int num_cnt
unsigned int reserved
unsigned int cnt_width