Skip to content

Commit c4457f0

Browse files
bgoglinndenoyelle
authored andcommitted
doxy: add entries about XML/synthetic/shmem compatibility between revisions
Signed-off-by: Brice Goglin <[email protected]>
1 parent 60f3132 commit c4457f0

File tree

2 files changed

+56
-3
lines changed

2 files changed

+56
-3
lines changed

NEWS

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,9 @@ Version 2.1.0
9898
+ hwloc-annotate may annotate multiple locations at once.
9999
+ Add a HTML/JS version of hwloc-ps. See contrib/hwloc-ps.www/README.
100100
+ Add bash completions.
101-
101+
* Misc
102+
+ Add several FAQ entries in "Compatibility between hwloc versions"
103+
about API version, ABI, XML, Synthetic strings, and shmem topologies.
102104

103105
Version 2.0.4 (also included in 1.11.13 when appropriate)
104106
-------------

doc/hwloc.doxy

Lines changed: 53 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2051,7 +2051,8 @@ libxml2 support as a plugin.
20512051
\section xml_errors XML import error management
20522052

20532053
Importing XML files can fail at least because of file access errors,
2054-
invalid XML syntax or non-hwloc-valid XML contents.
2054+
invalid XML syntax, non-hwloc-valid XML contents,
2055+
or incompatibilities between hwloc releases (see \ref faq_version_xml).
20552056

20562057
Both backend cannot detect all these errors when the input XML
20572058
file or buffer is selected (when hwloc_topology_set_xml() or
@@ -2217,7 +2218,7 @@ Package:1 L3Cache:1 L2Cache:2 L1dCache:1 L1iCache:1 Core:1 PU:2
22172218
\endverbatim
22182219

22192220
The exported string may be passed back to hwloc for recreating
2220-
another similar topology.
2221+
another similar topology (see also \ref faq_version_synthetic).
22212222
The entire tree will be similar, but some attributes such as
22222223
the processor model will be missing.
22232224

@@ -3733,6 +3734,56 @@ may be useful.
37333734

37343735

37353736

3737+
\subsection faq_version_xml Are XML topology files compatible between hwloc releases?
3738+
3739+
XML topology files are forward-compatible:
3740+
a XML file may be loaded by a hwloc library that is more recent
3741+
than the hwloc release that exported that file.
3742+
3743+
However, hwloc XMLs are not always backward-compatible:
3744+
Topologies exported by hwloc 2.x cannot be imported by 1.x by default
3745+
(see \ref upgrade_to_api_2x_xml for working around such issues).
3746+
There are also some corner cases where backward compatibility
3747+
is not guaranteed because of changes between major releases
3748+
(for instance 1.11 XMLs could not be imported in 1.10).
3749+
3750+
XMLs are exchanged at runtime between some components of the HPC software stack
3751+
(for instance the resource managers and MPI processes).
3752+
Building all these components on the same (cluster-wide)
3753+
hwloc installation is a good way to avoid such incompatibilities.
3754+
3755+
3756+
3757+
\subsection faq_version_synthetic Are synthetic strings compatible between hwloc releases?
3758+
3759+
Synthetic strings (see \ref synthetic) are forward-compatible:
3760+
a synthetic string generated by a release may be imported by future hwloc libraries.
3761+
3762+
However they are often not backward-compatible because new details may have been
3763+
added to synthetic descriptions in recent releases.
3764+
Some flags may be given to hwloc_topology_export_synthetic() to avoid such details
3765+
and stay backward compatible.
3766+
3767+
3768+
3769+
\subsection faq_version_shmem Is it possible to share a shared-memory topology between different hwloc releases?
3770+
3771+
Shared-memory topologies (see \ref hwlocality_shmem) have strong
3772+
requirements on compatibility between hwloc libraries.
3773+
Adopting a shared-memory topology fails
3774+
if it was exported by a non-compatible hwloc release.
3775+
Releases with same major revision are usually compatible
3776+
(e.g. hwloc 2.0.4 may adopt a topology exported by 2.0.3)
3777+
but different major revisions may be incompatible
3778+
(e.g. hwloc 2.1.0 cannot adopt from 2.0.x).
3779+
3780+
Topologies are shared at runtime between some components of the HPC software stack
3781+
(for instance the resource managers and MPI processes).
3782+
Building all these components on the same (system-wide) hwloc installation
3783+
is a good way to avoid such incompatibilities.
3784+
3785+
3786+
37363787
\page upgrade_to_api_2x Upgrading to the hwloc 2.0 API
37373788

37383789
\htmlonly

0 commit comments

Comments
 (0)