Hardware Locality (hwloc)
1.9
|
Enumerations | |
enum | hwloc_restrict_flags_e { HWLOC_RESTRICT_FLAG_ADAPT_DISTANCES, HWLOC_RESTRICT_FLAG_ADAPT_MISC, HWLOC_RESTRICT_FLAG_ADAPT_IO } |
Functions | |
hwloc_obj_t | hwloc_topology_insert_misc_object_by_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t cpuset, const char *name) |
hwloc_obj_t | hwloc_topology_insert_misc_object_by_parent (hwloc_topology_t topology, hwloc_obj_t parent, const char *name) |
int | hwloc_topology_restrict (hwloc_topology_t restrict topology, hwloc_const_cpuset_t cpuset, unsigned long flags) |
int | hwloc_topology_dup (hwloc_topology_t *newtopology, hwloc_topology_t oldtopology) |
Flags to be given to hwloc_topology_restrict().
int hwloc_topology_dup | ( | hwloc_topology_t * | newtopology, |
hwloc_topology_t | oldtopology | ||
) |
Duplicate a topology.
The entire topology structure as well as its objects are duplicated into a new one.
This is useful for keeping a backup while modifying a topology.
hwloc_obj_t hwloc_topology_insert_misc_object_by_cpuset | ( | hwloc_topology_t | topology, |
hwloc_const_cpuset_t | cpuset, | ||
const char * | name | ||
) |
Add a MISC object to the topology.
A new MISC object will be created and inserted into the topology at the position given by bitmap cpuset
. This offers a way to add new intermediate levels to the topology hierarchy.
cpuset
and name
will be copied to setup the new object attributes.
NULL
if the insertion conflicts with the existing topology tree.name
contains some non-printable characters, they will be dropped when exporting to XML, see hwloc_topology_export_xml(). hwloc_obj_t hwloc_topology_insert_misc_object_by_parent | ( | hwloc_topology_t | topology, |
hwloc_obj_t | parent, | ||
const char * | name | ||
) |
Add a MISC object as a leaf of the topology.
A new MISC object will be created and inserted into the topology at the position given by parent. It is appended to the list of existing children, without ever adding any intermediate hierarchy level. This is useful for annotating the topology without actually changing the hierarchy.
name
will be copied to the setup the new object attributes. However, the new leaf object will not have any cpuset
.
name
contains some non-printable characters, they will be dropped when exporting to XML, see hwloc_topology_export_xml(). int hwloc_topology_restrict | ( | hwloc_topology_t restrict | topology, |
hwloc_const_cpuset_t | cpuset, | ||
unsigned long | flags | ||
) |
Restrict the topology to the given CPU set.
Topology topology
is modified so as to remove all objects that are not included (or partially included) in the CPU set cpuset
. All objects CPU and node sets are restricted accordingly.
flags
is a OR'ed set of hwloc_restrict_flags_e.