Intel® Math Kernel Library 2018 Developer Reference - C
Retrieves the number of cores, hardware threads, and frequency for the specified coprocessor or host CPU.
int mkl_mic_get_cpuinfo (MKL_MIC_TARGET_TYPE target_type, int target_number, int* ncores, int* nthreads, double* freq);
Name |
Type |
Description |
---|---|---|
target_type |
MKL_MIC_TARGET_TYPE |
Type of the target device. Use one of the following values:
|
target_number |
int |
The device to retrieve the information for. Takes the following values:
If target_type = MKL_TARGET_HOST, the function ignores the target_number parameter, which may have any value. |
Name |
Type |
Description |
---|---|---|
ncores |
int* |
The number of physical cores on the target device. |
nthreads |
int* |
The number of hardware threads on the target device. |
freq |
double* |
The frequency in Hz of the target device. |
Use this function to retrieve the number of cores, hardware threads, and frequency for the host CPU or an Intel Xeon Phi coprocessor.
Name |
Type |
Description |
---|---|---|
ierr |
int |
Result status: = 0 Indicates that the information for the target device is successfully returned. < 0 Indicates a failure to return the information. |