71 long long (
values[3] )[2];
75 int index_array[2], number;
93 if (!
quiet) printf(
"Trouble adding events\n");
94 test_skip(__FILE__,__LINE__,
"Adding events",0);
130 printf(
"Test case: Overflow dispatch of 2nd event in set with 2 events.\n" );
131 printf(
"---------------------------------------------------------------\n" );
132 printf(
"Threshold for overflow is: %d\n",
THRESHOLD );
133 printf(
"Using %d iterations of c += a*b\n",
NUM_FLOPS );
134 printf(
"-----------------------------------------------\n" );
136 printf(
"Test type : %16d%16d\n", 1, 2 );
143 "one counter had no overflows", 1 );
146 for ( k = 0; k < 3; k++ ) {
151 index_array, &number );
154 "PAPI_get_overflow_event_index",
retval );
159 for (
i = 0;
i < number;
i++ )
160 printf(
" Event Index %d ", index_array[
i] );
167 printf(
"Case 2 %s Overflows: %d\n",
"Unknown",
total_unknown );
168 printf(
"-----------------------------------------------\n" );
172 test_fail( __FILE__, __LINE__,
"Unknown counter had overflows", 1 );
char event_name[2][PAPI_MAX_STR_LEN]
int PAPI_stop(int EventSet, long long *values)
void test_pass(const char *filename)
int PAPI_overflow(int EventSet, int EventCode, int threshold, int flags, PAPI_overflow_handler_t handler)
static void handler(int EventSet, void *address, long long overflow_vector, void *context)
void test_skip(const char *file, int line, const char *call, int retval)
int PAPI_library_init(int version)
int PAPI_cleanup_eventset(int EventSet)
int PAPI_event_code_to_name(int EventCode, char *out)
int PAPI_get_overflow_event_index(int EventSet, long long overflow_vector, int *array, int *number)
int tests_quiet(int argc, char **argv)
void test_fail(const char *file, int line, const char *call, int retval)
int add_two_nonderived_events(int *num_events, int *papi_event, int *mask)
int PAPI_start(int EventSet)
static ocount_t overflow_counts[3]
static long long values[NUM_EVENTS]