22{
23 float real_time, proc_time,ipc;
24 long long ins;
25 float real_time_i, proc_time_i, ipc_i;
26 long long ins_i;
28
30 {
31 printf("Could not initialise PAPI_ipc \n");
32 printf(
"retval: %d\n",
retval);
33 exit(1);
34 }
35
37
38
40 {
41 printf(
"retval: %d\n",
retval);
42 exit(1);
43 }
44
45
46 printf("Real_time: %f Proc_time: %f Instructions: %lld IPC: %f\n",
47 real_time, proc_time,ins,ipc);
48
49
51 exit(0);
52}
Simplified call to get instructions per cycle, real and processor time.
Finish using PAPI and free all related resources.