Print this page
6205 onbld manuals should be declared as 1onbld
Reviewed by: Dan McDonald <danmcd@omniti.com>
Reviewed by: Josef Sipek <jeffpc@josefsipek.net>
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/tools/scripts/wsdiff.1.man.txt
+++ new/usr/src/tools/scripts/wsdiff.1onbld.man.txt
1 -wsdiff(1) User Commands wsdiff(1)
1 +wsdiff(1ONBLD) illumos Build Tools wsdiff(1ONBLD)
2 2
3 3
4 4
5 5 wsdiff - report differences between proto area objects
6 6
7 7 SYNOPSIS
8 8 wsdiff [-dvVst] [-r results] [-i filelist] old new
9 9
10 10 DESCRIPTION
11 11 The wsdiff utility detects and reports on object differences found
12 12 between two proto areas constructed from the same workspace. This can
13 13 be useful when trying to understand which objects have changed as a
14 14 result of a particular source change.
15 15
16 16 old specifies the baseline proto area constructed without the source
17 17 change. new specifies the proto area constructed with the source
18 18 change. Both old and new should be constructed from the same workspace,
19 19 otherwise wsdiff will find object differences not associated with the
20 20 source change.
21 21
22 22 OPTIONS
23 23 -d Print debug information. The debug lines are prefixed with
24 24 ##.
25 25
26 26 -v Do not truncate the diffs logged to the results file. By
27 27 default wsdiff will truncate the length of a sufficiently
28 28 long set of object diffs to preserve the readability of the
29 29 results file. -v can be used to override this behaviour.
30 30
31 31 -V Log observed differences for all ELF sections, rather than
32 32 logging only the first difference found. When wsdiff
33 33 encounters an ELF section difference, by default it will log
34 34 the difference associated with that section only, and move
35 35 on. -V forces wsdiff to log all ELF section differences found
36 36 between two objects, rather than just the first. Because of
37 37 the extra work involved, this may slow wsdiff down
38 38 considerably.
39 39
40 40 -s Produce sorted lists. This is handy when comparing multiple
41 41 wsdiff outputs because wsdiff runs in multithreaded mode so
42 42 the list of differences is not sorted and can differ between
43 43 multiple runs.
44 44
45 45 -t Look for the onbld tools in $SRC/tools rather than
46 46 /opt/onbld/bin
47 47
48 48 -r Log results to the specified log file. The log file contains
49 49 a list of new, deleted, and changed objects, as well as diffs
50 50 signifying what wsdiff found to be different.
51 51
52 52 -i Specify which objects should be compared by wsdiff via an
53 53 input file list (See EXAMPLES).
54 54
55 55 OUTPUT
56 56 The list of objects appearing to differ between old and new is printed
57 57 to stdout. If -r was specified, the list of differing objects and their
58 58 differrences are logged to results.
59 59
60 60 EXAMPLES
61 61 Example 1: Using wsdiff to determine patch deliverables
62 62
63 63 The following example shows how to use wsdiff to determine the set of
64 64 objects requiring (re)delivery via patch as a result of a given source
65 65 change:
66 66
67 67 Starting with a built workspace, move the existing proto area aside:
68 68
69 69 user@example$ ls
70 70 Codemgr_wsdata/ proto/ usr/
71 71
72 72 user@example$ mv proto proto.old
73 73
74 74 Next, integrate the source changes, rebuild, and invoke wsdiff
75 75 specifying the old and new proto areas:
76 76
77 77 user@example$ ls
78 78 Codemgr_wsdata/ proto/ proto.old/ usr/
79 79
80 80 user@example$ wsdiff proto.old proto
81 81 platform/SUNW,SPARC-Enterprise/kernel/sparcv9/unix
82 82 platform/SUNW,Sun-Fire-15000/kernel/sparcv9/unix
83 83 platform/sun4v/kernel/sparcv9/unix
84 84 platform/sun4u/kernel/sparcv9/unix
85 85 platform/SUNW,Ultra-Enterprise-10000/kernel/sparcv9/unix
86 86 platform/SUNW,Sun-Fire/kernel/sparcv9/unix
87 87
88 88 Example 2: The wsdiff results file
89 89
90 90 With the -r option, wsdiff will log the list of objects that appear
91 91 different, as well as a set of diffs highlighting the observed
92 92 difference:
93 93
94 94 user@example$ wsdiff -r results proto.old proto
95 95 platform/SUNW,SPARC-Enterprise/kernel/sparcv9/unix
96 96 platform/SUNW,Sun-Fire-15000/kernel/sparcv9/unix
97 97 platform/sun4v/kernel/sparcv9/unix
98 98 platform/sun4u/kernel/sparcv9/unix
99 99 platform/SUNW,Ultra-Enterprise-10000/kernel/sparcv9/unix
100 100 platform/SUNW,Sun-Fire/kernel/sparcv9/unix
101 101
102 102 user@example$ cat results
103 103 # This file was produced by wsdiff
104 104 # 2006/7/10 at 18:28:56
105 105 Base proto area: proto.old/
106 106 Patch (new) proto area: proto/
107 107 Results file: results
108 108
109 109 platform/SUNW,SPARC-Enterprise/kernel/sparcv9/unix
110 110 NOTE: ELF .text difference detected.
111 111
112 112 89562,89567c89562,89567
113 113 < lgrp_cpu_init+0x158: 9e 10 20 01 mov 0x1, %o7
114 114 < lgrp_cpu_init+0x15c: b3 2b d0 1c sllx %o7, %i4, %i1
115 115 < lgrp_cpu_init+0x160: 9a 12 40 19 or %o1, %i1, %o5
116 116 < lgrp_cpu_init+0x164: da 76 a0 30 stx %o5, [%i2 + 0x30]
117 117 < lgrp_cpu_init+0x168: d8 04 e0 00 ld [%l3], %o4
118 118 < lgrp_cpu_init+0x16c: 80 a3 20 00 cmp %o4, 0x0
119 119 ---
120 120 > lgrp_cpu_init+0x158: 9a 10 20 01 mov 0x1, %o5
121 121 > lgrp_cpu_init+0x15c: b3 2b 50 1c sllx %o5, %i4, %i1
122 122 > lgrp_cpu_init+0x160: 98 12 00 19 or %o0, %i1, %o4
123 123 > lgrp_cpu_init+0x164: d8 76 a0 30 stx %o4, [%i2 + 0x30]
124 124 > lgrp_cpu_init+0x168: d6 04 e0 00 ld [%l3], %o3
125 125 > lgrp_cpu_init+0x16c: 80 a2 e0 00 cmp %o3, 0x0
126 126
127 127
128 128
129 129 Example 3: Using an input file list
130 130
131 131 The -i option tells wsdiff to compare a specific list of objects. This
132 132 can be useful in conjunction with other options that direct wsdiff to
↓ open down ↓ |
121 lines elided |
↑ open up ↑ |
133 133 log more verbosely, allowing one to "drill down" into a particular
134 134 object's differences:
135 135
136 136 user@example$ echo "usr/lib/mdb/kvm/sparcv9/genunix.so" > flist
137 137 user@example$ wsdiff -vV -r results -i flist proto.old proto
138 138 usr/lib/mdb/kvm/sparcv9/genunix.so
139 139
140 140 user@example$ cat results
141 141 <... verbose differences only for genunix.so ...>
142 142
143 - Example 4: Invoking wsdiff through nightly(1)
143 + Example 4: Invoking wsdiff through nightly(1ONBLD)
144 144
145 - By specifying -w in NIGHTLY_OPTIONS, nightly(1) will use wsdiff(1) to
146 - determine which objects look different, compared to the previous build.
147 - A pre-existing proto area must exist for wsdiff(1) to compare against.
148 - nightly(1) will move aside the pre-existing proto area (renaming it to
149 - $ROOT.prev under proto), and will invoke wsdiff at the end of the
150 - build. The list of changed objects will be reported in the nightly mail
151 - message, and a results file "wsdiff_results" will appear in the nightly
152 - log area.
145 + By specifying -w in NIGHTLY_OPTIONS, nightly(1ONBLD) will use
146 + wsdiff(1ONBLD) to determine which objects look different, compared to
147 + the previous build. A pre-existing proto area must exist for
148 + wsdiff(1ONBLD) to compare against. nightly(1ONBLD) will move aside the
149 + pre-existing proto area (renaming it to $ROOT.prev under proto), and
150 + will invoke wsdiff at the end of the build. The list of changed objects
151 + will be reported in the nightly mail message, and a results file
152 + "wsdiff_results" will appear in the nightly log area.
153 153
154 154 Example 5: Influencing the level of paralelism
155 155
156 156 wsdiff spawns a number of threads by default after it determines the
157 157 list of files for comparison. Default number of threads is based on the
158 158 number of on-line CPUs present in the system. To set the number of
159 159 threads for processing to some other value the DMAKE_MAX_JOBS
160 160 environment variable can be used:
161 161
162 162 $ DMAKE_MAX_JOBS=24 wsdiff proto_base proto_patch
163 163
164 - Note that this variable is also used for nightly(1) so when run from
165 - nightly(1), wsdiff will honor the setting.
164 + Note that this variable is also used for nightly(1ONBLD) so when run
165 + from nightly(1ONBLD), wsdiff will honor the setting.
166 166
167 167 SEE ALSO
168 - lintdump(1), nightly(1), elfdump(1),
168 + nightly(1ONBLD), elfdump(1),
169 169
170 170
171 171
172 - 15 Jul 2010 wsdiff(1)
172 + 15 Jul 2010 wsdiff(1ONBLD)
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX