22{
24 int total_events=0;
25 int code;
27 int r;
29
30
32
33
37 }
38
40 printf("Listing all net events\n");
41 }
42
44
45 for(cid=0; cid<numcmp; cid++) {
46
48 test_fail(__FILE__, __LINE__,
"PAPI_get_component_info failed\n",-1);
49 }
50
51 if ( strstr(cmpinfo->
name,
"net") == NULL) {
52 continue;
53 }
54
56 printf("Component %d (%d) - %d events - %s\n",
59 }
60
62
65
69 }
70
73 }
74
75 total_events++;
76
78 }
79
80 }
81
82 if (total_events==0) {
83 test_skip(__FILE__,__LINE__,
"No net events found", 0);
84 }
85
87
88 return 0;
89}
Enumerate PAPI preset or native events for a given component.
Convert a numeric hardware event code to a name.
get information about a specific software component
initialize the PAPI library.
Get the number of components available on the system.
char event_name[2][PAPI_MAX_STR_LEN]
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)
void PAPI_NORETURN test_skip(const char *file, int line, const char *call, int retval)
char name[PAPI_MAX_STR_LEN]