Hardware Locality (hwloc)  v2.2-20200401.0300.gitd2f52ab
export.h
00001 /*
00002  * Copyright © 2009-2018 Inria.  All rights reserved.
00003  * Copyright © 2009-2012 Université Bordeaux
00004  * Copyright © 2009-2011 Cisco Systems, Inc.  All rights reserved.
00005  * See COPYING in top-level directory.
00006  */
00007 
00012 #ifndef HWLOC_EXPORT_H
00013 #define HWLOC_EXPORT_H
00014 
00015 #ifndef HWLOC_H
00016 #error Please include the main hwloc.h instead
00017 #endif
00018 
00019 
00020 #ifdef __cplusplus
00021 extern "C" {
00022 #elif 0
00023 }
00024 #endif
00025 
00026 
00035 enum hwloc_topology_export_xml_flags_e {
00040  HWLOC_TOPOLOGY_EXPORT_XML_FLAG_V1 = (1UL<<0)
00041 };
00042 
00071 HWLOC_DECLSPEC int hwloc_topology_export_xml(hwloc_topology_t topology, const char *xmlpath, unsigned long flags);
00072 
00105 HWLOC_DECLSPEC int hwloc_topology_export_xmlbuffer(hwloc_topology_t topology, char **xmlbuffer, int *buflen, unsigned long flags);
00106 
00108 HWLOC_DECLSPEC void hwloc_free_xmlbuffer(hwloc_topology_t topology, char *xmlbuffer);
00109 
00128 HWLOC_DECLSPEC void hwloc_topology_set_userdata_export_callback(hwloc_topology_t topology,
00129                                                                 void (*export_cb)(void *reserved, hwloc_topology_t topology, hwloc_obj_t obj));
00130 
00156 HWLOC_DECLSPEC int hwloc_export_obj_userdata(void *reserved, hwloc_topology_t topology, hwloc_obj_t obj, const char *name, const void *buffer, size_t length);
00157 
00171 HWLOC_DECLSPEC int hwloc_export_obj_userdata_base64(void *reserved, hwloc_topology_t topology, hwloc_obj_t obj, const char *name, const void *buffer, size_t length);
00172 
00195 HWLOC_DECLSPEC void hwloc_topology_set_userdata_import_callback(hwloc_topology_t topology,
00196                                                                 void (*import_cb)(hwloc_topology_t topology, hwloc_obj_t obj, const char *name, const void *buffer, size_t length));
00197 
00209 enum hwloc_topology_export_synthetic_flags_e {
00215  HWLOC_TOPOLOGY_EXPORT_SYNTHETIC_FLAG_NO_EXTENDED_TYPES = (1UL<<0),
00216 
00223  HWLOC_TOPOLOGY_EXPORT_SYNTHETIC_FLAG_NO_ATTRS = (1UL<<1),
00224 
00233  HWLOC_TOPOLOGY_EXPORT_SYNTHETIC_FLAG_V1 = (1UL<<2),
00234 
00243  HWLOC_TOPOLOGY_EXPORT_SYNTHETIC_FLAG_IGNORE_MEMORY = (1UL<<3)
00244 };
00245 
00267   HWLOC_DECLSPEC int hwloc_topology_export_synthetic(hwloc_topology_t topology, char *buffer, size_t buflen, unsigned long flags);
00268 
00273 #ifdef __cplusplus
00274 } /* extern "C" */
00275 #endif
00276 
00277 
00278 #endif /* HWLOC_EXPORT_H */