PAPI 7.1.0.0
Loading...
Searching...
No Matches
ppc64_events.h
Go to the documentation of this file.
1#ifndef PPC64_EVENTS_H_
2#define PPC64_EVENTS_H_
3/*
4* File: ppc64_events.h
5* CVS:
6* Author: Maynard Johnson
7* maynardj@us.ibm.com
8* Mods: <your name here>
9* <your email address>
10*
11*/
12
13#ifdef ARCH_EVTS
14#include ARCH_EVTS
15#else
16#define GROUP_INTS 8
17#if defined(_POWER5)
18#define PAPI_MAX_NATIVE_EVENTS 512
19#elif defined(_POWER6)
20#define PAPI_MAX_NATIVE_EVENTS 1024
21#else
22#define PAPI_MAX_NATIVE_EVENTS 1024
23#endif
24#define MAX_GROUPS (GROUP_INTS * 32)
25#endif
26
27typedef struct PPC64_register
28{
29 /* indicate which counters this event can live on */
30 unsigned int selector;
31 /* Buffers containing counter cmds for each possible metric */
32 int counter_cmd[MAX_COUNTERS];
33 /* which group this event belongs */
34 unsigned int group[GROUP_INTS];
36
37/* Override void* definitions from PAPI framework layer */
38/* with typedefs to conform to PAPI component layer code. */
39#undef hwd_register_t
41
42typedef struct PPC64_groups
43{
44#ifdef __perfctr__
45 unsigned int mmcr0;
46 unsigned int mmcr1L;
47 unsigned int mmcr1U;
48 unsigned int mmcra;
49 unsigned int counter_cmd[MAX_COUNTERS];
50#else
51/* Buffer containing counter cmds for this group */
52 unsigned int counter_cmd[MAX_COUNTERS];
53#endif
55
57
58typedef struct native_event_entry
59{
60 /* description of the resources required by this native event */
62 /* If it exists, then this is the name of this event */
63 char *name;
64 /* If it exists, then this is the description of this event */
65 char *description;
67
68typedef struct PPC64_native_map
69{
70 /* native event name */
71 char *name;
72 /* real index in the native table */
73 int index;
75
77#ifndef __perfctr__
78extern hwd_pminfo_t pminfo;
79extern pm_groups_info_t pmgroups;
80#endif
83
85
86#endif /*PPC64_EVENTS_H_ */
pm_info_t hwd_pminfo_t
Definition: aix.h:81
#define MAX_COUNTERS
Definition: perfctr-x86.h:8
int check_native_name()
Definition: ppc64_events.c:168
pm_groups_info_t pmgroups
Definition: aix.c:44
hwd_groups_t group_map[MAX_GROUPS]
Definition: aix.c:47
#define MAX_GROUPS
Definition: ppc64_events.h:24
PPC64_native_map_t native_name_map[PAPI_MAX_NATIVE_EVENTS]
Definition: aix.c:46
PPC64_register_t hwd_register_t
Definition: ppc64_events.h:40
native_event_entry_t native_table[PAPI_MAX_NATIVE_EVENTS]
Definition: aix.c:41
PPC64_groups_t hwd_groups_t
Definition: ppc64_events.h:56
hwd_pminfo_t pminfo
Definition: aix.c:43
#define PAPI_MAX_NATIVE_EVENTS
Definition: ppc64_events.h:22
unsigned int selector
Definition: ppc64_events.h:30
Definition: perfctr-x86.h:134
hwd_register_t resources
Definition: ppc64_events.h:61
char * name
Definition: ppc64_events.h:63