Go to the source code of this file.
◆ main()
Definition at line 12 of file PAPI_hw_info.c.
13{
16
17
18
19
20
21
22
23
24
26 {
27 printf("Library initialization error! \n");
28 exit(1);
29 }
30
31
33 {
34 printf("PAPI_get_hardware_info error! \n");
35 exit(1);
36 }
37
38
39
40 printf(
"%d CPU at %f Mhz.\n",hwinfo->
totalcpus,hwinfo->
mhz);
42
43
45
46 exit(0);
47
48}
get information about the system hardware
initialize the PAPI library.
Finish using PAPI and free all related resources.
char model_string[PAPI_MAX_STR_LEN]