-
Notifications
You must be signed in to change notification settings - Fork 187
Upgrading to v2.0 API
To detect whether your building against hwloc 2.0.0 or later:
#if HWLOC_API_VERSION >= 0x20000
...
#endif
Here is a list of recommended ways to work-around API changes:
HWLOC_OBJ_CACHE
Replace with HWLOC_OBJ_L1CACHE, ..., HWLOC_OBJ_L5CACHE, HWLOC_OBJ_L1ICACHE, ..., HWLOC_OBJ_L3ICACHE. hwloc_get_cache_type_depth() is not really needed to disambiguate cache types anymore. hwloc_obj_type_is_cache(), hwloc_obj_type_is_dcache() and hwloc_obj_type_is_icache() may be used to check whether a given type is a cache, data/unified cache or instruction cache.
I/O children
I/O children are not in the main object children list anymore. They are in the list starting at obj->io_first_child and whose size if obj->io_arity.
Misc children
Misc children are not in the main object children list anymore. They are in the list starting at obj->misc_first_child and whose size if obj->misc_arity.
hwloc_topology_insert_misc_object_by_cpuset();
Replaced with hwloc_topology_alloc_group_object() and hwloc_topology_insert_group_object()
hwloc_topology_insert_misc_object_by_parent();
Replaced with hwloc_topology_insert_misc_object()
hwloc_topology_set_fsroot();
Removed. The HWLOC_FSROOT environment variable is still supported for the same behavior.
hwloc_obj_type_sscanf();
Pass an union hwloc_obj_attr_u instead of specific attributes. And get back attributes from the union cache or group fields.
hwloc_fill_object_sets();
Renamed into hwloc_obj_add_children_sets().
hwloc_obj_snprintf();
Removed, long-deprecated by hwloc_obj_type_snprintf() and hwloc_obj_attr_snprintf()
hwloc_topology_ignore_type_keep_structure();
hwloc_topology_ignore_all_keep_structure();
The meaning has changed (only entire levels may be ignored, instead of single objects), the old behavior is not available anymore.
obj->online_cpuset
The field has been removed from hwloc_obj_t. Offline are simply listed in the complete_cpuset as previously.
hwloc_topology_set_custom();
hwloc_custom_insert_topology();
hwloc_custom_insert_group_object_by_parent();
hwloc-assembler
hwloc-assembler-remote
The custom interface is not available anymore. Topologies always start with object with valid cpusets and nodesets.
HWLOC_MEMBIND_REPLICATE
Not available anymore (no supported operating system supports it).
obj->os_level
The object field has been removed.