1HWLOC-PATCH(1) hwloc HWLOC-PATCH(1)
2
3
4
6 hwloc-patch - Apply a topology difference to an existing XML topology
7
9 hwloc-patch [options] [<topology.xml> | refname] [<diff.xml> | -] <out‐
10 put.xml>
11
12 hwloc-patch [options] [<topology.xml> | refname] [<diff.xml> | -]
13
15 -R --reverse
16 Reverse the sense the difference file.
17
18 --version Report version and exit.
19
21 hwloc-patch loads the difference between two topologies from a XML file
22 (or from the standard input) and applies it to an existing topology,
23 generating a new, modified one.
24
25 The XML difference may have been computed earlier with hwloc-diff or
26 hwloc-compress-dir.
27
28 If <output.xml> is given, the new, modified topology is stored in that
29 new file. Otherwise, <topology.xml> is modified in place.
30
31 If refname is given instead of <topology.xml>, the input topology file‐
32 name is automatically guessed by reading the refname field of the XML
33 diff file. By default hwloc-diff generates XML diffs with the right
34 reference topology filename (without any path prefix).
35
36 If - is given instead of <diff.xml>, the topology difference is read
37 from the standard input.
38
39 NOTE: If some application-specific userdata were been exported to the
40 input XMLs, they will be ignored and discarded from the output because
41 hwloc has no way to understand and patch them.
42
43 NOTE: It is highly recommended that you read the hwloc(7) overview page
44 before reading this man page. Most of the concepts described in
45 hwloc(7) directly apply to the hwloc-patch utility.
46
48 hwloc-patch's operation is best described through several examples.
49
50 Apply a XML topology difference file to an existing topology:
51
52 $ hwloc-patch fourmi023.xml diff.xml fourmi023-new.xml
53
54 Apply a XML topology difference file whole refname field contains the
55 right input topology:
56
57 $ hwloc-patch refname diff.xml fourmi023-new.xml
58
59 Apply a XML topology from the standard intput:
60
61 $ cat diff.xml | hwloc-patch fourmi023.xml - fourmi023-new.xml
62
63 Directly compute the difference between two topologies and apply it to
64 another one, in place:
65
66 $ hwloc-diff fourmi023.xml fourmi024.xml | hwloc-patch
67 fourmi025.xml -
68
69
71 Upon successful execution, hwloc-patch outputs the modified topology.
72 The return value is 0.
73
74 hwloc-patch also returns nonzero if any kind of error occurs, such as
75 (but not limited to) failure to parse the command line.
76
78 hwloc(7), lstopo(1), hwloc-diff(1), hwloc-compress-dir(1)
79
80
81
82
831.11.8 Sep 06, 2017 HWLOC-PATCH(1)