Types and functions for the PU (processing unit) map functionality.
More...
#include <hwloc.h>
#include "error.h"
Go to the source code of this file.
|
struct | ghost_pumap |
| The PU (processing units) map containing all available processing units inside a given CPU set. More...
|
|
Types and functions for the PU (processing unit) map functionality.
@{
- Author
- Moritz Kreutzer morit.nosp@m.z.kr.nosp@m.eutze.nosp@m.r@fa.nosp@m.u.de
The PU (processing units) map containing all available processing units inside a given CPU set.
ghost_error ghost_pumap_create |
( |
hwloc_cpuset_t |
cpuset | ) |
|
Create a PU map.
- Parameters
-
cpuset | The CPU set to be covered by the PU map. |
- Returns
- GHOST_SUCCESS on success or an error indicator.
void ghost_pumap_destroy |
( |
| ) |
|
Get the PU map.
- Parameters
-
map | Where to store the map. |
- Returns
- GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_pumap_nidle |
( |
int * |
nPUs, |
|
|
int |
numaNode |
|
) |
| |
Get the number of idle processing units in total or in a given NUMA node.
- Parameters
-
nPUs | Where to store the number. |
numaNode | The NUMA node to consider or GHOST_NUMANODE_ANY. |
- Returns
- GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_pumap_npu |
( |
int * |
nPUs, |
|
|
int |
numaNode |
|
) |
| |
Get the number of processing units in total or in a given NUMA node.
- Parameters
-
nPUs | Where to store the number. |
numaNode | The NUMA node to consider or GHOST_NUMANODE_ANY. |
- Returns
- ::GHOST_SUCCESS on success or an error indicator.
ghost_error ghost_pumap_setbusy |
( |
hwloc_bitmap_t |
cpuset | ) |
|
Set the given CPU set in the PU map to busy.
- Parameters
-
cpuset | The CPU set to be set busy. |
- Returns
- GHOST_SUCCESS on success or an error indicator.
If the CPU set is not included in the PU map's CPU set an error is returned.
ghost_error ghost_pumap_setidle |
( |
hwloc_bitmap_t |
cpuset | ) |
|
Set the given CPU set in the PU map to idle.
- Parameters
-
cpuset | The CPU set to be set idle. |
- Returns
- GHOST_SUCCESS on success or an error indicator.
If the CPU set is not included in the PU map's CPU set an error is returned.
Set the given index in the PU map to idle.
- Parameters
-
- Returns
- GHOST_SUCCESS on success or an error indicator.
If the index is not included in the PU map's CPU set an error is returned.
pthread_mutex_t ghost_pumap_mutex |