Linux Manuals session 3

Section 3: library functions

  • |

    hwloc_get_closest_objs (3) Linux Manual Page

    hwlocality_helper_find_misc – Finding objects, miscellaneous helpers Functionsstatic hwloc_obj_t hwloc_get_pu_obj_by_os_index (hwloc_topology_t topology, unsigned os_index) static hwloc_obj_t hwloc_get_numanode_obj_by_os_index (hwloc_topology_t topology, unsigned os_index) unsigned hwloc_get_closest_objs (hwloc_topology_t topology, hwloc_obj_t src, hwloc_obj_t *restrict objs, unsigned max) static hwloc_obj_t hwloc_get_obj_below_by_type (hwloc_topology_t topology, hwloc_obj_type_t type1, unsigned idx1, hwloc_obj_type_t type2, unsigned idx2) static hwloc_obj_t hwloc_get_obj_below_array_by_type (hwloc_topology_t topology, int nr, hwloc_obj_type_t *typev, unsigned *idxv)…

  • |

    hwloc_get_child_covering_cpuset (3) Linux Manual Page

    hwlocality_helper_find_covering – Finding Objects covering at least CPU set Functionsstatic hwloc_obj_t hwloc_get_child_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t set, hwloc_obj_t parent) static hwloc_obj_t hwloc_get_obj_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t set) static hwloc_obj_t hwloc_get_next_obj_covering_cpuset_by_depth (hwloc_topology_t topology, hwloc_const_cpuset_t set, unsigned depth, hwloc_obj_t prev) static hwloc_obj_t hwloc_get_next_obj_covering_cpuset_by_type (hwloc_topology_t topology, hwloc_const_cpuset_t set, hwloc_obj_type_t type, hwloc_obj_t prev) Detailed DescriptionFunction Documentationstatic hwloc_obj_t hwloc_get_child_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t…

  • |

    hwloc_get_cache_type_depth (3) Linux Manual Page

    hwlocality_helper_find_cache – Looking at Cache Objects Functionsstatic int hwloc_get_cache_type_depth (hwloc_topology_t topology, unsigned cachelevel, hwloc_obj_cache_type_t cachetype) static hwloc_obj_t hwloc_get_cache_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t set) static hwloc_obj_t hwloc_get_shared_cache_covering_obj (hwloc_topology_t topology, hwloc_obj_t obj) Detailed DescriptionFunction Documentationstatic hwloc_obj_t hwloc_get_cache_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t set) [inline], [static]Get the first cache covering a cpuset set. Returns: NULL if no cache matches. Note: This…

  • |

    hwloc_get_cache_covering_cpuset (3) Linux Manual Page

    hwlocality_helper_find_cache – Looking at Cache Objects Functionsstatic int hwloc_get_cache_type_depth (hwloc_topology_t topology, unsigned cachelevel, hwloc_obj_cache_type_t cachetype) static hwloc_obj_t hwloc_get_cache_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t set) static hwloc_obj_t hwloc_get_shared_cache_covering_obj (hwloc_topology_t topology, hwloc_obj_t obj) Detailed DescriptionFunction Documentationstatic hwloc_obj_t hwloc_get_cache_covering_cpuset (hwloc_topology_t topology, hwloc_const_cpuset_t set) [inline], [static]Get the first cache covering a cpuset set. Returns: NULL if no cache matches. Note: This…

  • |

    hwloc_get_area_membind_nodeset (3) Linux Manual Page

    hwlocality_membinding – Memory binding Enumerationsenum hwloc_membind_policy_t { HWLOC_MEMBIND_DEFAULT, HWLOC_MEMBIND_FIRSTTOUCH, HWLOC_MEMBIND_BIND, HWLOC_MEMBIND_INTERLEAVE, HWLOC_MEMBIND_REPLICATE, HWLOC_MEMBIND_NEXTTOUCH, HWLOC_MEMBIND_MIXED } enum hwloc_membind_flags_t { HWLOC_MEMBIND_PROCESS, HWLOC_MEMBIND_THREAD, HWLOC_MEMBIND_STRICT, HWLOC_MEMBIND_MIGRATE, HWLOC_MEMBIND_NOCPUBIND } Functionsint hwloc_set_membind_nodeset (hwloc_topology_t topology, hwloc_const_nodeset_t nodeset, hwloc_membind_policy_t policy, int flags) int hwloc_set_membind (hwloc_topology_t topology, hwloc_const_cpuset_t cpuset, hwloc_membind_policy_t policy, int flags) int hwloc_get_membind_nodeset (hwloc_topology_t topology, hwloc_nodeset_t nodeset, hwloc_membind_policy_t *policy, int flags) int…

  • |

    hwloc_get_area_membind (3) Linux Manual Page

    hwlocality_membinding – Memory binding Enumerationsenum hwloc_membind_policy_t { HWLOC_MEMBIND_DEFAULT, HWLOC_MEMBIND_FIRSTTOUCH, HWLOC_MEMBIND_BIND, HWLOC_MEMBIND_INTERLEAVE, HWLOC_MEMBIND_REPLICATE, HWLOC_MEMBIND_NEXTTOUCH, HWLOC_MEMBIND_MIXED } enum hwloc_membind_flags_t { HWLOC_MEMBIND_PROCESS, HWLOC_MEMBIND_THREAD, HWLOC_MEMBIND_STRICT, HWLOC_MEMBIND_MIGRATE, HWLOC_MEMBIND_NOCPUBIND } Functionsint hwloc_set_membind_nodeset (hwloc_topology_t topology, hwloc_const_nodeset_t nodeset, hwloc_membind_policy_t policy, int flags) int hwloc_set_membind (hwloc_topology_t topology, hwloc_const_cpuset_t cpuset, hwloc_membind_policy_t policy, int flags) int hwloc_get_membind_nodeset (hwloc_topology_t topology, hwloc_nodeset_t nodeset, hwloc_membind_policy_t *policy, int flags) int…

  • |

    hwloc_get_api_version (3) Linux Manual Page

    hwlocality_api_version – API version Macros#define HWLOC_API_VERSION 0x00010b00 #define HWLOC_COMPONENT_ABI 4 Functionsunsigned hwloc_get_api_version (void) Detailed DescriptionMacro Definition Documentation#define HWLOC_API_VERSION 0x00010b00Indicate at build time which hwloc API version is being used. #define HWLOC_COMPONENT_ABI 4Current component and plugin ABI version (see hwloc/plugins.h) Function Documentationunsigned hwloc_get_api_version (void)Indicate at runtime which hwloc API version was used at build time. Should…

  • |

    hwloc_get_ancestor_obj_by_type (3) Linux Manual Page

    hwlocality_helper_ancestors – Looking at Ancestor and Child Objects Functionsstatic hwloc_obj_t hwloc_get_ancestor_obj_by_depth (hwloc_topology_t topology, unsigned depth, hwloc_obj_t obj) static hwloc_obj_t hwloc_get_ancestor_obj_by_type (hwloc_topology_t topology, hwloc_obj_type_t type, hwloc_obj_t obj) static hwloc_obj_t hwloc_get_common_ancestor_obj (hwloc_topology_t topology, hwloc_obj_t obj1, hwloc_obj_t obj2) static int hwloc_obj_is_in_subtree (hwloc_topology_t topology, hwloc_obj_t obj, hwloc_obj_t subtree_root) static hwloc_obj_t hwloc_get_next_child (hwloc_topology_t topology, hwloc_obj_t parent, hwloc_obj_t prev) Detailed DescriptionBe…

  • |

    hwloc_get_ancestor_obj_by_depth (3) Linux Manual Page

    hwlocality_helper_ancestors – Looking at Ancestor and Child Objects Functionsstatic hwloc_obj_t hwloc_get_ancestor_obj_by_depth (hwloc_topology_t topology, unsigned depth, hwloc_obj_t obj) static hwloc_obj_t hwloc_get_ancestor_obj_by_type (hwloc_topology_t topology, hwloc_obj_type_t type, hwloc_obj_t obj) static hwloc_obj_t hwloc_get_common_ancestor_obj (hwloc_topology_t topology, hwloc_obj_t obj1, hwloc_obj_t obj2) static int hwloc_obj_is_in_subtree (hwloc_topology_t topology, hwloc_obj_t obj, hwloc_obj_t subtree_root) static hwloc_obj_t hwloc_get_next_child (hwloc_topology_t topology, hwloc_obj_t parent, hwloc_obj_t prev) Detailed DescriptionBe…

  • |

    hwloc_free_xmlbuffer (3) Linux Manual Page

    hwlocality_xmlexport – Exporting Topologies to XML Functionsint hwloc_topology_export_xml (hwloc_topology_t topology, const char *xmlpath) int hwloc_topology_export_xmlbuffer (hwloc_topology_t topology, char **xmlbuffer, int *buflen) void hwloc_free_xmlbuffer (hwloc_topology_t topology, char *xmlbuffer) void hwloc_topology_set_userdata_export_callback (hwloc_topology_t topology, void(*export_cb)(void *reserved, hwloc_topology_t topology, hwloc_obj_t obj)) int hwloc_export_obj_userdata (void *reserved, hwloc_topology_t topology, hwloc_obj_t obj, const char *name, const void *buffer, size_t length) int hwloc_export_obj_userdata_base64…

  • |

    hwloc_free (3) Linux Manual Page

    hwlocality_membinding – Memory binding Enumerationsenum hwloc_membind_policy_t { HWLOC_MEMBIND_DEFAULT, HWLOC_MEMBIND_FIRSTTOUCH, HWLOC_MEMBIND_BIND, HWLOC_MEMBIND_INTERLEAVE, HWLOC_MEMBIND_REPLICATE, HWLOC_MEMBIND_NEXTTOUCH, HWLOC_MEMBIND_MIXED } enum hwloc_membind_flags_t { HWLOC_MEMBIND_PROCESS, HWLOC_MEMBIND_THREAD, HWLOC_MEMBIND_STRICT, HWLOC_MEMBIND_MIGRATE, HWLOC_MEMBIND_NOCPUBIND } Functionsint hwloc_set_membind_nodeset (hwloc_topology_t topology, hwloc_const_nodeset_t nodeset, hwloc_membind_policy_t policy, int flags) int hwloc_set_membind (hwloc_topology_t topology, hwloc_const_cpuset_t cpuset, hwloc_membind_policy_t policy, int flags) int hwloc_get_membind_nodeset (hwloc_topology_t topology, hwloc_nodeset_t nodeset, hwloc_membind_policy_t *policy, int flags) int…

  • |

    hwloc_export_obj_userdata_base64 (3) Linux Manual Page

    hwlocality_xmlexport – Exporting Topologies to XML Functionsint hwloc_topology_export_xml (hwloc_topology_t topology, const char *xmlpath) int hwloc_topology_export_xmlbuffer (hwloc_topology_t topology, char **xmlbuffer, int *buflen) void hwloc_free_xmlbuffer (hwloc_topology_t topology, char *xmlbuffer) void hwloc_topology_set_userdata_export_callback (hwloc_topology_t topology, void(*export_cb)(void *reserved, hwloc_topology_t topology, hwloc_obj_t obj)) int hwloc_export_obj_userdata (void *reserved, hwloc_topology_t topology, hwloc_obj_t obj, const char *name, const void *buffer, size_t length) int hwloc_export_obj_userdata_base64…

  • |

    hwloc_export_obj_userdata (3) Linux Manual Page

    hwlocality_xmlexport – Exporting Topologies to XML Functionsint hwloc_topology_export_xml (hwloc_topology_t topology, const char *xmlpath) int hwloc_topology_export_xmlbuffer (hwloc_topology_t topology, char **xmlbuffer, int *buflen) void hwloc_free_xmlbuffer (hwloc_topology_t topology, char *xmlbuffer) void hwloc_topology_set_userdata_export_callback (hwloc_topology_t topology, void(*export_cb)(void *reserved, hwloc_topology_t topology, hwloc_obj_t obj)) int hwloc_export_obj_userdata (void *reserved, hwloc_topology_t topology, hwloc_obj_t obj, const char *name, const void *buffer, size_t length) int hwloc_export_obj_userdata_base64…

  • |

    hwloc_distrib_flags_e (3) Linux Manual Page

    hwlocality_helper_distribute – Distributing items over a topology Enumerationsenum hwloc_distrib_flags_e { HWLOC_DISTRIB_FLAG_REVERSE } Functionsstatic int hwloc_distrib (hwloc_topology_t topology, hwloc_obj_t *roots, unsigned n_roots, hwloc_cpuset_t *set, unsigned n, unsigned until, unsigned long flags) Detailed DescriptionEnumeration Type Documentationenum hwloc_distrib_flags_eFlags to be given to hwloc_distrib(). Enumerator HWLOC_DISTRIB_FLAG_REVERSE Distrib in reverse order, starting from the last objects.Function Documentationstatic int hwloc_distrib (hwloc_topology_t…

  • |

    hwloc_distrib (3) Linux Manual Page

    hwlocality_helper_distribute – Distributing items over a topology Enumerationsenum hwloc_distrib_flags_e { HWLOC_DISTRIB_FLAG_REVERSE } Functionsstatic int hwloc_distrib (hwloc_topology_t topology, hwloc_obj_t *roots, unsigned n_roots, hwloc_cpuset_t *set, unsigned n, unsigned until, unsigned long flags) Detailed DescriptionEnumeration Type Documentationenum hwloc_distrib_flags_eFlags to be given to hwloc_distrib(). Enumerator HWLOC_DISTRIB_FLAG_REVERSE Distrib in reverse order, starting from the last objects.Function Documentationstatic int hwloc_distrib (hwloc_topology_t…

  • |

    hwloc_distances_s (3) Linux Manual Page

    hwloc_distances_s – Synopsis#include <hwloc.h> Data Fieldsunsigned relative_depth unsigned nbobjs float * latency float latency_max float latency_base Detailed DescriptionDistances between objects. One object may contain a distance structure describing distances between all its descendants at a given relative depth. If the containing object is the root object of the topology, then the distances are available for…

  • |

    hwloc_custom_insert_topology (3) Linux Manual Page

    hwlocality_custom – Building Custom Topologies Functionsint hwloc_custom_insert_topology (hwloc_topology_t newtopology, hwloc_obj_t newparent, hwloc_topology_t oldtopology, hwloc_obj_t oldroot) hwloc_obj_t hwloc_custom_insert_group_object_by_parent (hwloc_topology_t topology, hwloc_obj_t parent, int groupdepth) Detailed DescriptionA custom topology may be initialized by calling hwloc_topology_set_custom() after hwloc_topology_init(). It may then be modified by inserting objects or entire topologies. Once done assembling, hwloc_topology_load() should be invoked as usual…

  • |

    hwloc_custom_insert_group_object_by_parent (3) Linux Manual Page

    hwlocality_custom – Building Custom Topologies Functionsint hwloc_custom_insert_topology (hwloc_topology_t newtopology, hwloc_obj_t newparent, hwloc_topology_t oldtopology, hwloc_obj_t oldroot) hwloc_obj_t hwloc_custom_insert_group_object_by_parent (hwloc_topology_t topology, hwloc_obj_t parent, int groupdepth) Detailed DescriptionA custom topology may be initialized by calling hwloc_topology_set_custom() after hwloc_topology_init(). It may then be modified by inserting objects or entire topologies. Once done assembling, hwloc_topology_load() should be invoked as usual…

  • |

    hwloc_cudart_get_device_pcidev (3) Linux Manual Page

    hwlocality_cudart – Interoperability with the CUDA Runtime API Functionsstatic int hwloc_cudart_get_device_pci_ids (hwloc_topology_t topology, int idx, int *domain, int *bus, int *dev) static int hwloc_cudart_get_device_cpuset (hwloc_topology_t topology, int idx, hwloc_cpuset_t set) static hwloc_obj_t hwloc_cudart_get_device_pcidev (hwloc_topology_t topology, int idx) static hwloc_obj_t hwloc_cudart_get_device_osdev_by_index (hwloc_topology_t topology, unsigned idx) Detailed DescriptionThis interface offers ways to retrieve topology information about CUDA…

  • |

    hwloc_cudart_get_device_pci_ids (3) Linux Manual Page

    hwlocality_cudart – Interoperability with the CUDA Runtime API Functionsstatic int hwloc_cudart_get_device_pci_ids (hwloc_topology_t topology, int idx, int *domain, int *bus, int *dev) static int hwloc_cudart_get_device_cpuset (hwloc_topology_t topology, int idx, hwloc_cpuset_t set) static hwloc_obj_t hwloc_cudart_get_device_pcidev (hwloc_topology_t topology, int idx) static hwloc_obj_t hwloc_cudart_get_device_osdev_by_index (hwloc_topology_t topology, unsigned idx) Detailed DescriptionThis interface offers ways to retrieve topology information about CUDA…