Go to the source code of this file.
◆ ERROR_RETURN
| #define ERROR_RETURN |
( |
|
retval | ) |
{ fprintf(stderr, "Error %d %s:line %d: \n", retval,__FILE__,__LINE__); exit(retval); } |
◆ NUM_EVENTS
◆ main()
Definition at line 13 of file PAPI_add_remove_event.c.
56 printf(
"There are %d events in the event set\n", number);
65 for (
i = 0;
i < 2000000;
i++)
75 printf(
"The total instructions executed for the first loop are %lld \n",
values[0] );
76 printf(
"The total cycles executed for the first loop are %lld \n",
values[1]);
80 for (
i = 0;
i < 2000000;
i++)
89 printf(
"Total instructions executed are %lld \n",
values[0] );
90 printf(
"Total cycles executed are %lld \n",
values[1]);
95 printf(
"Removing PAPI_TOT_INS from the eventset\n");
102 printf(
"There is only %d event left in the eventset now\n", number);
int PAPI_stop(int EventSet, long long *values)
int PAPI_add_event(int EventSet, int EventCode)
int PAPI_remove_event(int EventSet, int EventCode)
#define ERROR_RETURN(retval)
int PAPI_library_init(int version)
int PAPI_create_eventset(int *EventSet)
int PAPI_read(int EventSet, long long *values)
int PAPI_start(int EventSet)
static long long values[NUM_EVENTS]
int PAPI_list_events(int EventSet, int *Events, int *number)