Go to the source code of this file.
◆ main()
| int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 17 of file get_event_component.c.
18{
19
23 int numcmp, cid, our_cid;
25
26
28
29
33 }
34
36
37
38
39 for( cid = 0; cid < numcmp; cid++ )
40 {
42
43 if (cmpinfo == NULL)
44 {
45 test_fail( __FILE__, __LINE__,
"PAPI_get_component_info", 2 );
46 }
47
51 continue;
52 }
53
54
58
59 do {
62 printf(
"Getting information about event: %#x failed\n",
i);
63 }
64 continue;
65 }
67
68 if (our_cid!=cid) {
70 printf(
"%d %d %s\n",cid,our_cid,info.
symbol);
71 }
72 test_fail( __FILE__, __LINE__,
"component mismatch", 1 );
73 }
74
76 printf(
"%d %d %s\n",cid,our_cid,info.
symbol);
77 }
78
79
81
82 }
83
85
86 return 0;
87}
Enumerate PAPI preset or native events for a given component.
get information about a specific software component
return component an event belongs to
Get the event's name and description info.
initialize the PAPI library.
Get the number of components available on the system.
int tests_quiet(int argc, char **argv)
void PAPI_NORETURN test_fail(const char *file, int line, const char *call, int retval)
void PAPI_NORETURN test_pass(const char *filename)
char description[PAPI_MAX_STR_LEN]
char name[PAPI_MAX_STR_LEN]
char disabled_reason[PAPI_HUGE_STR_LEN]
char symbol[PAPI_HUGE_STR_LEN]