Go to the source code of this file.
|
| int | main (int argc, char **argv) |
| |
◆ main()
| int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 25 of file papi_hw_int.c.
34 unsigned long long seconds;
35 unsigned long long ns;
46 printf(
"\nTesting PAPI_HW_INT\n");
56 if (!
quiet) printf(
"Could not add PAPI_HW_INT\n");
65 printf(
"\nRunning for 3 seconds\n");
68 clock_gettime(CLOCK_REALTIME,&before);
74 clock_gettime(CLOCK_REALTIME,&after);
76 seconds=after.tv_sec - before.tv_sec;
77 ns = after.tv_nsec - before.tv_nsec;
78 ns = (seconds*1000000000ULL)+ns;
81 if (ns>3000000000ULL)
break;
91 printf(
"\tMeasured interrupts = %lld\n",
count);
94 printf(
"\tAssuming HZ=250, expect roughly 750\n");
97 if (!
quiet) printf(
"\n");
100 if (!
quiet) printf(
"Too few interrupts!\n");
101 test_fail( __FILE__, __LINE__,
"Too few interrupts!", 1 );
int PAPI_stop(int EventSet, long long *values)
void test_pass(const char *filename)
int PAPI_reset(int EventSet)
void test_skip(const char *file, int line, const char *call, int retval)
int PAPI_add_named_event(int EventSet, const char *EventName)
int PAPI_library_init(int version)
int PAPI_create_eventset(int *EventSet)
int tests_quiet(int argc, char **argv)
void test_fail(const char *file, int line, const char *call, int retval)
int PAPI_start(int EventSet)