Debian Codegraph @

upstream/fedora-rawhide/man1/objdump.1

raw
1 .\" -*- mode: troff; coding: utf-8 -*-
2 .\" Automatically generated by Pod::Man v6.0.2 (Pod::Simple 3.48)
3 .\"
4 .\" Standard preamble:
5 .\" ========================================================================
6 .de Sp \" Vertical space (when we can't use .PP)
7 .if t .sp .5v
8 .if n .sp
9 ..
10 .de Vb \" Begin verbatim text
11 .ft CW
12 .nf
13 .ne \\$1
14 ..
15 .de Ve \" End verbatim text
16 .ft R
17 .fi
18 ..
19 .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
20 .ie n \{\
21 . ds C` ""
22 . ds C' ""
23 'br\}
24 .el\{\
25 . ds C`
26 . ds C'
27 'br\}
28 .\"
29 .\" Escape single quotes in literal strings from groff's Unicode transform.
30 .ie \n(.g .ds Aq \(aq
31 .el .ds Aq '
32 .\"
33 .\" If the F register is >0, we'll generate index entries on stderr for
34 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
35 .\" entries marked with X<> in POD. Of course, you'll have to process the
36 .\" output yourself in some meaningful fashion.
37 .\"
38 .\" Avoid warning from groff about undefined register 'F'.
39 .de IX
40 ..
41 .nr rF 0
42 .if \n(.g .if rF .nr rF 1
43 .if (\n(rF:(\n(.g==0)) \{\
44 . if \nF \{\
45 . de IX
46 . tm Index:\\$1\t\\n%\t"\\$2"
47 ..
48 . if !\nF==2 \{\
49 . nr % 0
50 . nr F 2
51 . \}
52 . \}
53 .\}
54 .rr rF
55 .\"
56 .\" Required to disable full justification in groff 1.23.0.
57 .if n .ds AD l
58 .\" ========================================================================
59 .\"
60 .IX Title "OBJDUMP 1"
61 .TH OBJDUMP 1 2026-05-14 binutils-2.46.50 "GNU Development Tools"
62 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
63 .\" way too many mistakes in technical documents.
64 .if n .ad l
65 .nh
66 .SH NAME
67 objdump \- display information from object files
68 .SH SYNOPSIS
69 .IX Header "SYNOPSIS"
70 objdump [\fB\-a\fR|\fB\-\-archive\-headers\fR]
71 [\fB\-b\fR \fIbfdname\fR|\fB\-\-target=\fR\fIbfdname\fR]
72 [\fB\-C\fR|\fB\-\-demangle\fR[=\fIstyle\fR] ]
73 [\fB\-d\fR|\fB\-\-disassemble\fR[=\fIsymbol\fR]]
74 [\fB\-D\fR|\fB\-\-disassemble\-all\fR]
75 [\fB\-z\fR|\fB\-\-disassemble\-zeroes\fR]
76 [\fB\-EB\fR|\fB\-EL\fR|\fB\-\-endian=\fR{big | little }]
77 [\fB\-f\fR|\fB\-\-file\-headers\fR]
78 [\fB\-F\fR|\fB\-\-file\-offsets\fR]
79 [\fB\-\-file\-start\-context\fR]
80 [\fB\-g\fR|\fB\-\-debugging\fR]
81 [\fB\-e\fR|\fB\-\-debugging\-tags\fR]
82 [\fB\-h\fR|\fB\-\-section\-headers\fR|\fB\-\-headers\fR]
83 [\fB\-i\fR|\fB\-\-info\fR]
84 [\fB\-j\fR \fIsection\fR|\fB\-\-section=\fR\fIsection\fR]
85 [\fB\-l\fR|\fB\-\-line\-numbers\fR]
86 [\fB\-S\fR|\fB\-\-source\fR]
87 [\fB\-\-source\-comment\fR[=\fItext\fR]]
88 [\fB\-m\fR \fImachine\fR|\fB\-\-architecture=\fR\fImachine\fR]
89 [\fB\-M\fR \fIoptions\fR|\fB\-\-disassembler\-options=\fR\fIoptions\fR]
90 [\fB\-p\fR|\fB\-\-private\-headers\fR]
91 [\fB\-P\fR \fIoptions\fR|\fB\-\-private=\fR\fIoptions\fR]
92 [\fB\-r\fR|\fB\-\-reloc\fR]
93 [\fB\-R\fR|\fB\-\-dynamic\-reloc\fR]
94 [\fB\-s\fR|\fB\-\-full\-contents\fR]
95 [\fB\-Z\fR|\fB\-\-decompress\fR]
96 [\fB\-W\fR|\fB\-\-dwarf\fR]
97 [\fB\-Wa\fR|\fB\-\-dwarf=abbrev\fR]
98 [\fB\-WA\fR|\fB\-\-dwarf=addr\fR]
99 [\fB\-Wr\fR|\fB\-\-dwarf=aranges\fR]
100 [\fB\-Wc\fR|\fB\-\-dwarf=cu_index\fR]
101 [\fB\-WL\fR|\fB\-\-dwarf=decodedline\fR]
102 [\fB\-Wf\fR|\fB\-\-dwarf=frames\fR]
103 [\fB\-WF\fR|\fB\-\-dwarf=frames\-interp\fR]
104 [\fB\-Wg\fR|\fB\-\-dwarf=gdb_index\fR]
105 [\fB\-Wi\fR|\fB\-\-dwarf=info\fR]
106 [\fB\-Wk\fR|\fB\-\-dwarf=links\fR]
107 [\fB\-Wo\fR|\fB\-\-dwarf=loc\fR]
108 [\fB\-Wm\fR|\fB\-\-dwarf=macro\fR]
109 [\fB\-Wp\fR|\fB\-\-dwarf=pubnames\fR]
110 [\fB\-Wt\fR|\fB\-\-dwarf=pubtypes\fR]
111 [\fB\-WR\fR|\fB\-\-dwarf=Ranges\fR]
112 [\fB\-Wl\fR|\fB\-\-dwarf=rawline\fR]
113 [\fB\-Ws\fR|\fB\-\-dwarf=str\fR]
114 [\fB\-WO\fR|\fB\-\-dwarf=str\-offsets\fR]
115 [\fB\-Wu\fR|\fB\-\-dwarf=trace_abbrev\fR]
116 [\fB\-WT\fR|\fB\-\-dwarf=trace_aranges\fR]
117 [\fB\-WU\fR|\fB\-\-dwarf=trace_info\fR]
118 [\fB\-WK\fR|\fB\-\-dwarf=follow\-links\fR]
119 [\fB\-WN\fR|\fB\-\-dwarf=no\-follow\-links\fR]
120 [\fB\-WD\fR|\fB\-\-dwarf=use\-debuginfod\fR]
121 [\fB\-WE\fR|\fB\-\-dwarf=do\-not\-use\-debuginfod\fR]
122 [\fB\-\-debug\-dir=\fR\f(BIdir\fR]
123 [\fB\-\-map\-global\-vars\fR]
124 [\fB\-L\fR|\fB\-\-process\-links\fR]
125 [\fB\-\-ctf=\fR\fIsection\fR]
126 [\fB\-\-sframe=\fR\fIsection\fR]
127 [\fB\-G\fR|\fB\-\-stabs\fR]
128 [\fB\-t\fR|\fB\-\-syms\fR]
129 [\fB\-T\fR|\fB\-\-dynamic\-syms\fR]
130 [\fB\-x\fR|\fB\-\-all\-headers\fR]
131 [\fB\-w\fR|\fB\-\-wide\fR]
132 [\fB\-\-start\-address=\fR\fIaddress\fR]
133 [\fB\-\-stop\-address=\fR\fIaddress\fR]
134 [\fB\-\-no\-addresses\fR]
135 [\fB\-\-prefix\-addresses\fR]
136 [\fB\-\-[no\-]show\-raw\-insn\fR]
137 [\fB\-\-adjust\-vma=\fR\fIoffset\fR]
138 [\fB\-\-show\-all\-symbols\fR]
139 [\fB\-\-dwarf\-depth=\fR\fIn\fR]
140 [\fB\-\-dwarf\-start=\fR\fIn\fR]
141 [\fB\-\-ctf\-parent=\fR\fIsection\fR]
142 [\fB\-\-no\-recurse\-limit\fR|\fB\-\-recurse\-limit\fR]
143 [\fB\-\-special\-syms\fR]
144 [\fB\-\-prefix=\fR\fIprefix\fR]
145 [\fB\-\-prefix\-strip=\fR\fIlevel\fR]
146 [\fB\-\-insn\-width=\fR\fIwidth\fR]
147 [\fB\-\-visualize\-jumps[=color|=extended\-color|=off]\fR
148 [\fB\-\-disassembler\-color=[off|terminal|on|extended]\fR
149 [\fB\-U\fR \fImethod\fR] [\fB\-\-unicode=\fR\fImethod\fR]
150 [\fB\-V\fR|\fB\-\-version\fR]
151 [\fB\-H\fR|\fB\-\-help\fR]
152 \fIobjfile\fR...
153 .SH DESCRIPTION
154 .IX Header "DESCRIPTION"
155 \&\fBobjdump\fR displays information about one or more object files.
156 The options control what particular information to display. This
157 information is mostly useful to programmers who are working on the
158 compilation tools, as opposed to programmers who just want their
159 program to compile and work.
160 .PP
161 \&\fIobjfile\fR... are the object files to be examined. When you
162 specify archives, \fBobjdump\fR shows information on each of the member
163 object files.
164 .SH OPTIONS
165 .IX Header "OPTIONS"
166 The long and short forms of options, shown here as alternatives, are
167 equivalent. At least one option from the list
168 \&\fB\-a,\-d,\-D,\-e,\-f,\-g,\-G,\-h,\-H,\-p,\-P,\-r,\-R,\-s,\-S,\-t,\-T,\-V,\-x\fR must be given.
169 .IP \fB\-a\fR 4
170 .IX Item "-a"
171 .PD 0
172 .IP \fB\-\-archive\-header\fR 4
173 .IX Item "--archive-header"
174 .PD
175 If any of the \fIobjfile\fR files are archives, display the archive
176 header information (in a format similar to \fBls \-l\fR). Besides the
177 information you could list with \fBar tv\fR, \fBobjdump \-a\fR shows
178 the object file format of each archive member.
179 .IP \fB\-\-adjust\-vma=\fR\fIoffset\fR 4
180 .IX Item "--adjust-vma=offset"
181 When dumping information, first add \fIoffset\fR to all the section
182 addresses. This is useful if the section addresses do not correspond to
183 the symbol table, which can happen when putting sections at particular
184 addresses when using a format which can not represent section addresses,
185 such as a.out.
186 .IP "\fB\-b\fR \fIbfdname\fR" 4
187 .IX Item "-b bfdname"
188 .PD 0
189 .IP \fB\-\-target=\fR\fIbfdname\fR 4
190 .IX Item "--target=bfdname"
191 .PD
192 Specify that the object\-code format for the object files is
193 \&\fIbfdname\fR. This option may not be necessary; \fIobjdump\fR can
194 automatically recognize many formats.
195 .Sp
196 For example,
197 .Sp
198 .Vb 1
199 \& objdump \-b oasys \-m vax \-h fu.o
200 .Ve
201 .Sp
202 displays summary information from the section headers (\fB\-h\fR) of
203 \&\fIfu.o\fR, which is explicitly identified (\fB\-m\fR) as a VAX object
204 file in the format produced by Oasys compilers. You can list the
205 formats available with the \fB\-i\fR option.
206 .IP \fB\-C\fR 4
207 .IX Item "-C"
208 .PD 0
209 .IP \fB\-\-demangle[=\fR\fIstyle\fR\fB]\fR 4
210 .IX Item "--demangle[=style]"
211 .PD
212 Decode (\fIdemangle\fR) low\-level symbol names into user\-level names.
213 Besides removing any initial underscore prepended by the system, this
214 makes C++ function names readable. Different compilers have different
215 mangling styles. The optional demangling style argument can be used to
216 choose an appropriate demangling style for your compiler.
217 .IP \fB\-\-recurse\-limit\fR 4
218 .IX Item "--recurse-limit"
219 .PD 0
220 .IP \fB\-\-no\-recurse\-limit\fR 4
221 .IX Item "--no-recurse-limit"
222 .IP \fB\-\-recursion\-limit\fR 4
223 .IX Item "--recursion-limit"
224 .IP \fB\-\-no\-recursion\-limit\fR 4
225 .IX Item "--no-recursion-limit"
226 .PD
227 Enables or disables a limit on the amount of recursion performed
228 whilst demangling strings. Since the name mangling formats allow for
229 an infinite level of recursion it is possible to create strings whose
230 decoding will exhaust the amount of stack space available on the host
231 machine, triggering a memory fault. The limit tries to prevent this
232 from happening by restricting recursion to 2048 levels of nesting.
233 .Sp
234 The default is for this limit to be enabled, but disabling it may be
235 necessary in order to demangle truly complicated names. Note however
236 that if the recursion limit is disabled then stack exhaustion is
237 possible and any bug reports about such an event will be rejected.
238 .IP \fB\-g\fR 4
239 .IX Item "-g"
240 .PD 0
241 .IP \fB\-\-debugging\fR 4
242 .IX Item "--debugging"
243 .PD
244 Display debugging information. This attempts to parse STABS
245 debugging format information stored in the file and print it out using
246 a C like syntax. If no STABS debugging was found this option
247 falls back on the \fB\-W\fR option to print any DWARF information in
248 the file.
249 .IP \fB\-e\fR 4
250 .IX Item "-e"
251 .PD 0
252 .IP \fB\-\-debugging\-tags\fR 4
253 .IX Item "--debugging-tags"
254 .PD
255 Like \fB\-g\fR, but the information is generated in a format compatible
256 with ctags tool.
257 .IP \fB\-d\fR 4
258 .IX Item "-d"
259 .PD 0
260 .IP \fB\-\-disassemble\fR 4
261 .IX Item "--disassemble"
262 .IP \fB\-\-disassemble=\fR\fIsymbol\fR 4
263 .IX Item "--disassemble=symbol"
264 .PD
265 Display the assembler mnemonics for the machine instructions from the
266 input file. This option only disassembles those sections which are
267 expected to contain instructions. If the optional \fIsymbol\fR
268 argument is given (perhaps multiple times), then display the assembler
269 mnemonics starting at (all the) \fIsymbol\fR. If \fIsymbol\fR is a
270 function name then disassembly will stop at the end of the function,
271 otherwise it will stop when the next symbol is encountered. If there
272 are no matches for any \fIsymbol\fR then nothing will be displayed.
273 .Sp
274 Note if the \fB\-\-dwarf=follow\-links\fR option is enabled
275 then any symbol tables in linked debug info files will be read in and
276 used when disassembling.
277 .IP \fB\-D\fR 4
278 .IX Item "-D"
279 .PD 0
280 .IP \fB\-\-disassemble\-all\fR 4
281 .IX Item "--disassemble-all"
282 .PD
283 Like \fB\-d\fR, but disassemble the contents of all non\-empty
284 non\-bss sections, not just those expected to contain instructions.
285 \&\fB\-j\fR may be used to select specific sections.
286 .Sp
287 This option also has a subtle effect on the disassembly of
288 instructions in code sections. When option \fB\-d\fR is in effect
289 objdump will assume that any symbols present in a code section occur
290 on the boundary between instructions and it will refuse to disassemble
291 across such a boundary. When option \fB\-D\fR is in effect however
292 this assumption is supressed. This means that it is possible for the
293 output of \fB\-d\fR and \fB\-D\fR to differ if, for example, data
294 is stored in code sections.
295 .Sp
296 If the target is an ARM architecture this switch also has the effect
297 of forcing the disassembler to decode pieces of data found in code
298 sections as if they were instructions.
299 .Sp
300 Note if the \fB\-\-dwarf=follow\-links\fR option is enabled
301 then any symbol tables in linked debug info files will be read in and
302 used when disassembling.
303 .IP \fB\-\-no\-addresses\fR 4
304 .IX Item "--no-addresses"
305 When disassembling, don\*(Aqt print addresses on each line or for symbols
306 and relocation offsets. In combination with \fB\-\-no\-show\-raw\-insn\fR
307 this may be useful for comparing compiler output.
308 .IP \fB\-\-prefix\-addresses\fR 4
309 .IX Item "--prefix-addresses"
310 When disassembling, print the complete address on each line. This is
311 the older disassembly format.
312 .IP \fB\-EB\fR 4
313 .IX Item "-EB"
314 .PD 0
315 .IP \fB\-EL\fR 4
316 .IX Item "-EL"
317 .IP \fB\-\-endian={big|little}\fR 4
318 .IX Item "--endian={big|little}"
319 .PD
320 Specify the endianness of the object files. This only affects
321 disassembly. This can be useful when disassembling a file format which
322 does not describe endianness information, such as S\-records.
323 .IP \fB\-f\fR 4
324 .IX Item "-f"
325 .PD 0
326 .IP \fB\-\-file\-headers\fR 4
327 .IX Item "--file-headers"
328 .PD
329 Display summary information from the overall header of
330 each of the \fIobjfile\fR files.
331 .IP \fB\-F\fR 4
332 .IX Item "-F"
333 .PD 0
334 .IP \fB\-\-file\-offsets\fR 4
335 .IX Item "--file-offsets"
336 .PD
337 When disassembling sections, whenever a symbol is displayed, also
338 display the file offset of the region of data that is about to be
339 dumped. If zeroes are being skipped, then when disassembly resumes,
340 tell the user how many zeroes were skipped and the file offset of the
341 location from where the disassembly resumes. When dumping sections,
342 display the file offset of the location from where the dump starts.
343 .IP \fB\-\-file\-start\-context\fR 4
344 .IX Item "--file-start-context"
345 Specify that when displaying interlisted source code/disassembly
346 (assumes \fB\-S\fR) from a file that has not yet been displayed, extend the
347 context to the start of the file.
348 .IP \fB\-h\fR 4
349 .IX Item "-h"
350 .PD 0
351 .IP \fB\-\-section\-headers\fR 4
352 .IX Item "--section-headers"
353 .IP \fB\-\-headers\fR 4
354 .IX Item "--headers"
355 .PD
356 Display summary information from the section headers of the
357 object file.
358 .Sp
359 File segments may be relocated to nonstandard addresses, for example by
360 using the \fB\-Ttext\fR, \fB\-Tdata\fR, or \fB\-Tbss\fR options to
361 \&\fBld\fR. However, some object file formats, such as a.out, do not
362 store the starting address of the file segments. In those situations,
363 although \fBld\fR relocates the sections correctly, using \fBobjdump
364 \&\-h\fR to list the file section headers cannot show the correct addresses.
365 Instead, it shows the usual addresses, which are implicit for the
366 target.
367 .Sp
368 Note, in some cases it is possible for a section to have both the
369 READONLY and the NOREAD attributes set. In such cases the NOREAD
370 attribute takes precedence, but \fBobjdump\fR will report both
371 since the exact setting of the flag bits might be important.
372 .IP \fB\-H\fR 4
373 .IX Item "-H"
374 .PD 0
375 .IP \fB\-\-help\fR 4
376 .IX Item "--help"
377 .PD
378 Print a summary of the options to \fBobjdump\fR and exit.
379 .IP \fB\-i\fR 4
380 .IX Item "-i"
381 .PD 0
382 .IP \fB\-\-info\fR 4
383 .IX Item "--info"
384 .PD
385 Display a list showing all architectures and object formats available
386 for specification with \fB\-b\fR or \fB\-m\fR.
387 .IP "\fB\-j\fR \fIname\fR" 4
388 .IX Item "-j name"
389 .PD 0
390 .IP \fB\-\-section=\fR\fIname\fR 4
391 .IX Item "--section=name"
392 .PD
393 Display information for section \fIname\fR. This option may be
394 specified multiple times.
395 .IP \fB\-\-map\-global\-vars\fR 4
396 .IX Item "--map-global-vars"
397 Display global variable information. This option only works when the object
398 file is compiled with the debug option. More precisely, it relies on DWARF2
399 debug information entries. It is useful for tracking the location and type of
400 all global variables in the given object file.
401 .IP \fB\-L\fR 4
402 .IX Item "-L"
403 .PD 0
404 .IP \fB\-\-process\-links\fR 4
405 .IX Item "--process-links"
406 .PD
407 Display the contents of non\-debug sections found in separate debuginfo
408 files that are linked to the main file. This option automatically
409 implies the \fB\-WK\fR option, and only sections requested by other
410 command line options will be displayed.
411 .IP \fB\-l\fR 4
412 .IX Item "-l"
413 .PD 0
414 .IP \fB\-\-line\-numbers\fR 4
415 .IX Item "--line-numbers"
416 .PD
417 Label the display (using debugging information) with the filename and
418 source line numbers corresponding to the object code or relocs shown.
419 Only useful with \fB\-d\fR, \fB\-D\fR, or \fB\-r\fR.
420 .IP "\fB\-m\fR \fImachine\fR" 4
421 .IX Item "-m machine"
422 .PD 0
423 .IP \fB\-\-architecture=\fR\fImachine\fR 4
424 .IX Item "--architecture=machine"
425 .PD
426 Specify the architecture to use when disassembling object files. This
427 can be useful when disassembling object files which do not describe
428 architecture information, such as S\-records. You can list the available
429 architectures with the \fB\-i\fR option.
430 .Sp
431 For most architectures it is possible to supply an architecture
432 name and a machine name, separated by a colon. For example
433 \&\fBfoo:bar\fR would refer to the \fBbar\fR machine type in the
434 \&\fBfoo\fR architecture. This can be helpful if objdump has been
435 configured to support multiple architectures.
436 .Sp
437 If the target is an ARM architecture then this switch has an
438 additional effect. It restricts the disassembly to only those
439 instructions supported by the architecture specified by \fImachine\fR.
440 If it is necessary to use this switch because the input file does not
441 contain any architecture information, but it is also desired to
442 disassemble all the instructions use \fB\-marm\fR.
443 .IP "\fB\-M\fR \fIoptions\fR" 4
444 .IX Item "-M options"
445 .PD 0
446 .IP \fB\-\-disassembler\-options=\fR\fIoptions\fR 4
447 .IX Item "--disassembler-options=options"
448 .PD
449 Pass target specific information to the disassembler. Only supported on
450 some targets. If it is necessary to specify more than one
451 disassembler option then multiple \fB\-M\fR options can be used or
452 can be placed together into a comma separated list.
453 .Sp
454 For ARC, \fBdsp\fR controls the printing of DSP instructions,
455 \&\fBspfp\fR selects the printing of FPX single precision FP
456 instructions, \fBdpfp\fR selects the printing of FPX double
457 precision FP instructions, \fBquarkse_em\fR selects the printing of
458 special QuarkSE\-EM instructions, \fBfpuda\fR selects the printing
459 of double precision assist instructions, \fBfpus\fR selects the
460 printing of FPU single precision FP instructions, while \fBfpud\fR
461 selects the printing of FPU double precision FP instructions.
462 Additionally, one can choose to have all the immediates printed in
463 hexadecimal using \fBhex\fR. By default, the short immediates are
464 printed using the decimal representation, while the long immediate
465 values are printed as hexadecimal.
466 .Sp
467 \&\fBcpu=...\fR allows one to enforce a particular ISA when disassembling
468 instructions, overriding the \fB\-m\fR value or whatever is in the ELF file.
469 This might be useful to select ARC EM or HS ISA, because architecture is same
470 for those and disassembler relies on private ELF header data to decide if code
471 is for EM or HS. This option might be specified multiple times \- only the
472 latest value will be used. Valid values are same as for the assembler
473 \&\fB\-mcpu=...\fR option.
474 .Sp
475 If the target is an ARM architecture then this switch can be used to
476 select which register name set is used during disassembler. Specifying
477 \&\fB\-M reg\-names\-std\fR (the default) will select the register names as
478 used in ARM\*(Aqs instruction set documentation, but with register 13 called
479 \&\*(Aqsp\*(Aq, register 14 called \*(Aqlr\*(Aq and register 15 called \*(Aqpc\*(Aq. Specifying
480 \&\fB\-M reg\-names\-apcs\fR will select the name set used by the ARM
481 Procedure Call Standard, whilst specifying \fB\-M reg\-names\-raw\fR will
482 just use \fBr\fR followed by the register number.
483 .Sp
484 There are also two variants on the APCS register naming scheme enabled
485 by \fB\-M reg\-names\-atpcs\fR and \fB\-M reg\-names\-special\-atpcs\fR which
486 use the ARM/Thumb Procedure Call Standard naming conventions. (Either
487 with the normal register names or the special register names).
488 .Sp
489 This option can also be used for ARM architectures to force the
490 disassembler to interpret all instructions as Thumb instructions by
491 using the switch \fB\-\-disassembler\-options=force\-thumb\fR. This can be
492 useful when attempting to disassemble thumb code produced by other
493 compilers.
494 .Sp
495 For AArch64 targets this switch can be used to set whether instructions are
496 disassembled as the most general instruction using the \fB\-M no\-aliases\fR
497 option or whether instruction notes should be generated as comments in the
498 disasssembly using \fB\-M notes\fR. In addition the \fB\-M
499 annotate\fR option can be used to customise the handling of undefined
500 instructions when disassembling executables and shared libraries.
501 Normally the disassembler will just show the hexadecimal value of tge
502 undefined instruction, but if annotation is enabled it will first try
503 to find a symbol whose value matches the instruction\*(Aqs encoding. If
504 there is a match then the symbol name will be displayed instead. This
505 can be useful when disassembling non\-code sections which may contain
506 function and data addresses.
507 .Sp
508 For the x86, some of the options duplicate functions of the \fB\-m\fR
509 switch, but allow finer grained control.
510 .RS 4
511 .ie n .IP """x86\-64""" 4
512 .el .IP \f(CWx86\-64\fR 4
513 .IX Item "x86-64"
514 .PD 0
515 .ie n .IP """i386""" 4
516 .el .IP \f(CWi386\fR 4
517 .IX Item "i386"
518 .ie n .IP """i8086""" 4
519 .el .IP \f(CWi8086\fR 4
520 .IX Item "i8086"
521 .PD
522 Select disassembly for the given architecture.
523 .ie n .IP """intel""" 4
524 .el .IP \f(CWintel\fR 4
525 .IX Item "intel"
526 .PD 0
527 .ie n .IP """att""" 4
528 .el .IP \f(CWatt\fR 4
529 .IX Item "att"
530 .PD
531 Select between intel syntax mode and AT&T syntax mode.
532 .ie n .IP """amd64""" 4
533 .el .IP \f(CWamd64\fR 4
534 .IX Item "amd64"
535 .PD 0
536 .ie n .IP """intel64""" 4
537 .el .IP \f(CWintel64\fR 4
538 .IX Item "intel64"
539 .PD
540 Select between AMD64 ISA and Intel64 ISA.
541 .ie n .IP """intel\-mnemonic""" 4
542 .el .IP \f(CWintel\-mnemonic\fR 4
543 .IX Item "intel-mnemonic"
544 .PD 0
545 .ie n .IP """att\-mnemonic""" 4
546 .el .IP \f(CWatt\-mnemonic\fR 4
547 .IX Item "att-mnemonic"
548 .PD
549 Select between intel mnemonic mode and AT&T mnemonic mode.
550 Note: \f(CW\*(C`intel\-mnemonic\*(C'\fR implies \f(CW\*(C`intel\*(C'\fR and
551 \&\f(CW\*(C`att\-mnemonic\*(C'\fR implies \f(CW\*(C`att\*(C'\fR.
552 .ie n .IP """addr64""" 4
553 .el .IP \f(CWaddr64\fR 4
554 .IX Item "addr64"
555 .PD 0
556 .ie n .IP """addr32""" 4
557 .el .IP \f(CWaddr32\fR 4
558 .IX Item "addr32"
559 .ie n .IP """addr16""" 4
560 .el .IP \f(CWaddr16\fR 4
561 .IX Item "addr16"
562 .ie n .IP """data32""" 4
563 .el .IP \f(CWdata32\fR 4
564 .IX Item "data32"
565 .ie n .IP """data16""" 4
566 .el .IP \f(CWdata16\fR 4
567 .IX Item "data16"
568 .PD
569 Specify the default address size and operand size. These five options
570 will be overridden if \f(CW\*(C`x86\-64\*(C'\fR, \f(CW\*(C`i386\*(C'\fR or \f(CW\*(C`i8086\*(C'\fR
571 appear later in the option string.
572 .ie n .IP """suffix""" 4
573 .el .IP \f(CWsuffix\fR 4
574 .IX Item "suffix"
575 When in AT&T mode and also for a limited set of instructions when in Intel
576 mode, instructs the disassembler to print a mnemonic suffix even when the
577 suffix could be inferred by the operands or, for certain instructions, the
578 execution mode\*(Aqs defaults.
579 .ie n .IP """annotate\-immediates""" 4
580 .el .IP \f(CWannotate\-immediates\fR 4
581 .IX Item "annotate-immediates"
582 Display the symbol associated with immediate values, should there be
583 one. Only works on executable binaries and shared libraries, not
584 static object files.
585 .RE
586 .RS 4
587 .Sp
588 For PowerPC, the \fB\-M\fR argument \fBraw\fR selects
589 disasssembly of hardware insns rather than aliases. For example, you
590 will see \f(CW\*(C`rlwinm\*(C'\fR rather than \f(CW\*(C`clrlwi\*(C'\fR, and \f(CW\*(C`addi\*(C'\fR
591 rather than \f(CW\*(C`li\*(C'\fR. All of the \fB\-m\fR arguments for
592 \&\fBgas\fR that select a CPU are supported. These are:
593 \&\fB403\fR, \fB405\fR, \fB440\fR, \fB464\fR, \fB476\fR,
594 \&\fB601\fR, \fB603\fR, \fB604\fR, \fB620\fR, \fB7400\fR,
595 \&\fB7410\fR, \fB7450\fR, \fB7455\fR, \fB750cl\fR,
596 \&\fB821\fR, \fB850\fR, \fB860\fR, \fBa2\fR, \fBbooke\fR,
597 \&\fBbooke32\fR, \fBcell\fR, \fBcom\fR, \fBe200z2\fR, \fBe200z4\fR,
598 \&\fBe300\fR, \fBe500\fR, \fBe500mc\fR, \fBe500mc64\fR,
599 \&\fBe500x2\fR, \fBe5500\fR, \fBe6500\fR, \fBefs\fR,
600 \&\fBpower4\fR, \fBpower5\fR, \fBpower6\fR, \fBpower7\fR,
601 \&\fBpower8\fR, \fBpower9\fR, \fBpower10\fR, \fBpower11\fR,
602 \&\fBppc\fR, \fBppc32\fR, \fBppc64\fR, \fBppc64bridge\fR,
603 \&\fBppcps\fR, \fBpwr\fR, \fBpwr2\fR, \fBpwr4\fR, \fBpwr5\fR,
604 \&\fBpwr5x\fR, \fBpwr6\fR, \fBpwr7\fR, \fBpwr8\fR, \fBpwr9\fR,
605 \&\fBpwr10\fR, \fBpwr11\fR, \fBpwrx\fR, \fBtitan\fR, \fBvle\fR,
606 and \fBfuture\fR.
607 \&\fB32\fR and \fB64\fR modify the default or a prior CPU
608 selection, disabling and enabling 64\-bit insns respectively. In
609 addition, \fBaltivec\fR, \fBany\fR, \fBlsp\fR, \fBhtm\fR,
610 \&\fBvsx\fR, \fBspe\fR and \fBspe2\fR add capabilities to a
611 previous \fIor later\fR CPU selection.
612 \&\fBany\fR will disassemble any opcode known to
613 binutils, but in cases where an opcode has two different meanings or
614 different arguments, you may not see the disassembly you expect.
615 If you disassemble without giving a CPU selection, a default will be
616 chosen from information gleaned by BFD from the object files headers,
617 but the result again may not be as you expect.
618 .Sp
619 For RISC\-V, the following options are supported:
620 .ie n .IP """max""" 4
621 .el .IP \f(CWmax\fR 4
622 .IX Item "max"
623 Disassemble without checking architecture string. This is a best effort mode, so
624 for overlapping ISA extensions the first match (possibly incorrect in a given
625 context) will be used to decode the instruction. It\*(Aqs useful, if the ELF file
626 doesn\*(Aqt expose ISA string, preventing automatic ISA subset deduction, and the
627 default fallback ISA string (\f(CW\*(C`rv64gc\*(C'\fR) doesn\*(Aqt cover all instructions in
628 the binary.
629 .ie n .IP """numeric""" 4
630 .el .IP \f(CWnumeric\fR 4
631 .IX Item "numeric"
632 Print numeric register names, rather than ABI names (e.g., print \f(CW\*(C`x2\*(C'\fR
633 instead of \f(CW\*(C`sp\*(C'\fR).
634 .ie n .IP """no\-aliases""" 4
635 .el .IP \f(CWno\-aliases\fR 4
636 .IX Item "no-aliases"
637 Disassemble only into canonical instructions. For example, compressed
638 instructions will be represented as such (\f(CW\*(C`addi sp,sp,\-128\*(C'\fR will be
639 \&\f(CW\*(C`c.addi16sp sp,\-128\*(C'\fR).
640 .ie n .IP """priv\-spec=\fISPEC\fR""" 4
641 .el .IP \f(CWpriv\-spec=\fR\f(CISPEC\fR\f(CW\fR 4
642 .IX Item "priv-spec=SPEC"
643 Print the CSR according to the chosen privilege spec version (e.g.,
644 \&\f(CW1.10\fR, \f(CW1.11\fR, \f(CW1.12\fR, \f(CW1.13\fR).
645 .RE
646 .RS 4
647 .Sp
648 For MIPS, this option controls the printing of instruction mnemonic
649 names and register names in disassembled instructions. Multiple
650 selections from the following may be specified as a comma separated
651 string, and invalid options are ignored:
652 .ie n .IP """no\-aliases""" 4
653 .el .IP \f(CWno\-aliases\fR 4
654 .IX Item "no-aliases"
655 Print the \*(Aqraw\*(Aq instruction mnemonic instead of some pseudo
656 instruction mnemonic. I.e., print \*(Aqdaddu\*(Aq or \*(Aqor\*(Aq instead of \*(Aqmove\*(Aq,
657 \&\*(Aqsll\*(Aq instead of \*(Aqnop\*(Aq, etc.
658 .ie n .IP """msa""" 4
659 .el .IP \f(CWmsa\fR 4
660 .IX Item "msa"
661 Disassemble MSA instructions.
662 .ie n .IP """virt""" 4
663 .el .IP \f(CWvirt\fR 4
664 .IX Item "virt"
665 Disassemble the virtualization ASE instructions.
666 .ie n .IP """xpa""" 4
667 .el .IP \f(CWxpa\fR 4
668 .IX Item "xpa"
669 Disassemble the eXtended Physical Address (XPA) ASE instructions.
670 .ie n .IP """gpr\-names=\fIABI\fR""" 4
671 .el .IP \f(CWgpr\-names=\fR\f(CIABI\fR\f(CW\fR 4
672 .IX Item "gpr-names=ABI"
673 Print GPR (general\-purpose register) names as appropriate
674 for the specified ABI. By default, GPR names are selected according to
675 the ABI of the binary being disassembled.
676 .ie n .IP """fpr\-names=\fIABI\fR""" 4
677 .el .IP \f(CWfpr\-names=\fR\f(CIABI\fR\f(CW\fR 4
678 .IX Item "fpr-names=ABI"
679 Print FPR (floating\-point register) names as
680 appropriate for the specified ABI. By default, FPR numbers are printed
681 rather than names.
682 .ie n .IP """cp0\-names=\fIARCH\fR""" 4
683 .el .IP \f(CWcp0\-names=\fR\f(CIARCH\fR\f(CW\fR 4
684 .IX Item "cp0-names=ARCH"
685 Print CP0 (system control coprocessor; coprocessor 0) register names
686 as appropriate for the CPU or architecture specified by
687 \&\fIARCH\fR. By default, CP0 register names are selected according to
688 the architecture and CPU of the binary being disassembled.
689 .ie n .IP """hwr\-names=\fIARCH\fR""" 4
690 .el .IP \f(CWhwr\-names=\fR\f(CIARCH\fR\f(CW\fR 4
691 .IX Item "hwr-names=ARCH"
692 Print HWR (hardware register, used by the \f(CW\*(C`rdhwr\*(C'\fR instruction) names
693 as appropriate for the CPU or architecture specified by
694 \&\fIARCH\fR. By default, HWR names are selected according to
695 the architecture and CPU of the binary being disassembled.
696 .ie n .IP """reg\-names=\fIABI\fR""" 4
697 .el .IP \f(CWreg\-names=\fR\f(CIABI\fR\f(CW\fR 4
698 .IX Item "reg-names=ABI"
699 Print GPR and FPR names as appropriate for the selected ABI.
700 .ie n .IP """reg\-names=\fIARCH\fR""" 4
701 .el .IP \f(CWreg\-names=\fR\f(CIARCH\fR\f(CW\fR 4
702 .IX Item "reg-names=ARCH"
703 Print CPU\-specific register names (CP0 register and HWR names)
704 as appropriate for the selected CPU or architecture.
705 .RE
706 .RS 4
707 .Sp
708 For any of the options listed above, \fIABI\fR or
709 \&\fIARCH\fR may be specified as \fBnumeric\fR to have numbers printed
710 rather than names, for the selected types of registers.
711 You can list the available values of \fIABI\fR and \fIARCH\fR using
712 the \fB\-\-help\fR option.
713 .Sp
714 For VAX, you can specify function entry addresses with \fB\-M
715 entry:0xf00ba\fR. You can use this multiple times to properly
716 disassemble VAX binary files that don\*(Aqt contain symbol tables (like
717 ROM dumps). In these cases, the function entry mask would otherwise
718 be decoded as VAX instructions, which would probably lead the rest
719 of the function being wrongly disassembled.
720 .RE
721 .IP \fB\-p\fR 4
722 .IX Item "-p"
723 .PD 0
724 .IP \fB\-\-private\-headers\fR 4
725 .IX Item "--private-headers"
726 .PD
727 Print information that is specific to the object file format. The exact
728 information printed depends upon the object file format. For some
729 object file formats, no additional information is printed.
730 .IP "\fB\-P\fR \fIoptions\fR" 4
731 .IX Item "-P options"
732 .PD 0
733 .IP \fB\-\-private=\fR\fIoptions\fR 4
734 .IX Item "--private=options"
735 .PD
736 Print information that is specific to the object file format. The
737 argument \fIoptions\fR is a comma separated list that depends on the
738 format (the lists of options is displayed with the help).
739 .Sp
740 For XCOFF, the available options are:
741 .RS 4
742 .ie n .IP """header""" 4
743 .el .IP \f(CWheader\fR 4
744 .IX Item "header"
745 .PD 0
746 .ie n .IP """aout""" 4
747 .el .IP \f(CWaout\fR 4
748 .IX Item "aout"
749 .ie n .IP """sections""" 4
750 .el .IP \f(CWsections\fR 4
751 .IX Item "sections"
752 .ie n .IP """syms""" 4
753 .el .IP \f(CWsyms\fR 4
754 .IX Item "syms"
755 .ie n .IP """relocs""" 4
756 .el .IP \f(CWrelocs\fR 4
757 .IX Item "relocs"
758 .ie n .IP """lineno,""" 4
759 .el .IP \f(CWlineno,\fR 4
760 .IX Item "lineno,"
761 .ie n .IP """loader""" 4
762 .el .IP \f(CWloader\fR 4
763 .IX Item "loader"
764 .ie n .IP """except""" 4
765 .el .IP \f(CWexcept\fR 4
766 .IX Item "except"
767 .ie n .IP """typchk""" 4
768 .el .IP \f(CWtypchk\fR 4
769 .IX Item "typchk"
770 .ie n .IP """traceback""" 4
771 .el .IP \f(CWtraceback\fR 4
772 .IX Item "traceback"
773 .ie n .IP """toc""" 4
774 .el .IP \f(CWtoc\fR 4
775 .IX Item "toc"
776 .ie n .IP """ldinfo""" 4
777 .el .IP \f(CWldinfo\fR 4
778 .IX Item "ldinfo"
779 .PD
780 .RE
781 .RS 4
782 .Sp
783 For PE, the available options are:
784 .ie n .IP """header""" 4
785 .el .IP \f(CWheader\fR 4
786 .IX Item "header"
787 .PD 0
788 .ie n .IP """sections""" 4
789 .el .IP \f(CWsections\fR 4
790 .IX Item "sections"
791 .PD
792 .RE
793 .RS 4
794 .Sp
795 Not all object formats support this option. In particular the ELF
796 format does not use it.
797 .RE
798 .IP \fB\-r\fR 4
799 .IX Item "-r"
800 .PD 0
801 .IP \fB\-\-reloc\fR 4
802 .IX Item "--reloc"
803 .PD
804 Print the relocation entries of the file. If used with \fB\-d\fR or
805 \&\fB\-D\fR, the relocations are printed interspersed with the
806 disassembly.
807 .IP \fB\-R\fR 4
808 .IX Item "-R"
809 .PD 0
810 .IP \fB\-\-dynamic\-reloc\fR 4
811 .IX Item "--dynamic-reloc"
812 .PD
813 Print the dynamic relocation entries of the file. This is only
814 meaningful for dynamic objects, such as certain types of shared
815 libraries. As for \fB\-r\fR, if used with \fB\-d\fR or
816 \&\fB\-D\fR, the relocations are printed interspersed with the
817 disassembly.
818 .Sp
819 Note: \fBobjdump\fR does not support displaying RELR type
820 relocations. These can be displayed by the \fBreadelf\fR program.
821 .IP \fB\-s\fR 4
822 .IX Item "-s"
823 .PD 0
824 .IP \fB\-\-full\-contents\fR 4
825 .IX Item "--full-contents"
826 .PD
827 Display the full contents of sections, often used in combination with
828 \&\fB\-j\fR to request specific sections. By default all non\-empty
829 non\-bss sections are displayed. By default any compressed section
830 will be displayed in its compressed form. In order to see the
831 contents in a decompressed form add the \fB\-Z\fR option to the
832 command line.
833 .IP \fB\-S\fR 4
834 .IX Item "-S"
835 .PD 0
836 .IP \fB\-\-source\fR 4
837 .IX Item "--source"
838 .PD
839 Display source code intermixed with disassembly, if possible. Implies
840 \&\fB\-d\fR.
841 .IP \fB\-\-show\-all\-symbols\fR 4
842 .IX Item "--show-all-symbols"
843 When disassembling, show all the symbols that match a given address,
844 not just the first one.
845 .IP \fB\-\-source\-comment[=\fR\fItxt\fR\fB]\fR 4
846 .IX Item "--source-comment[=txt]"
847 Like the \fB\-S\fR option, but all source code lines are displayed
848 with a prefix of \fItxt\fR. Typically \fItxt\fR will be a comment
849 string which can be used to distinguish the assembler code from the
850 source code. If \fItxt\fR is not provided then a default string of
851 \&\fI"# "\fR (hash followed by a space), will be used.
852 .IP \fB\-\-prefix=\fR\fIprefix\fR 4
853 .IX Item "--prefix=prefix"
854 Specify \fIprefix\fR to add to the absolute paths when used with
855 \&\fB\-S\fR.
856 .IP \fB\-\-prefix\-strip=\fR\fIlevel\fR 4
857 .IX Item "--prefix-strip=level"
858 Indicate how many initial directory names to strip off the hardwired
859 absolute paths. It has no effect without \fB\-\-prefix=\fR\fIprefix\fR.
860 .IP \fB\-\-show\-raw\-insn\fR 4
861 .IX Item "--show-raw-insn"
862 When disassembling instructions, print the instruction in hex as well as
863 in symbolic form. This is the default except when
864 \&\fB\-\-prefix\-addresses\fR is used.
865 .IP \fB\-\-no\-show\-raw\-insn\fR 4
866 .IX Item "--no-show-raw-insn"
867 When disassembling instructions, do not print the instruction bytes.
868 This is the default when \fB\-\-prefix\-addresses\fR is used.
869 .IP \fB\-\-insn\-width=\fR\fIwidth\fR 4
870 .IX Item "--insn-width=width"
871 Display \fIwidth\fR bytes on a single line when disassembling
872 instructions.
873 .IP \fB\-\-visualize\-jumps[=color|=extended\-color|=off]\fR 4
874 .IX Item "--visualize-jumps[=color|=extended-color|=off]"
875 Visualize jumps that stay inside a function by drawing ASCII art between
876 the start and target addresses. The optional \fB=color\fR argument
877 adds color to the output using simple terminal colors. Alternatively
878 the \fB=extended\-color\fR argument will add color using 8bit
879 colors, but these might not work on all terminals.
880 .Sp
881 If it is necessary to disable the \fBvisualize\-jumps\fR option
882 after it has previously been enabled then use
883 \&\fBvisualize\-jumps=off\fR.
884 .IP \fB\-\-disassembler\-color=off\fR 4
885 .IX Item "--disassembler-color=off"
886 .PD 0
887 .IP \fB\-\-disassembler\-color=terminal\fR 4
888 .IX Item "--disassembler-color=terminal"
889 .IP \fB\-\-disassembler\-color=on|color|colour\fR 4
890 .IX Item "--disassembler-color=on|color|colour"
891 .IP \fB\-\-disassembler\-color=extended|extended\-color|extended\-colour\fR 4
892 .IX Item "--disassembler-color=extended|extended-color|extended-colour"
893 .PD
894 Enables or disables the use of colored syntax highlighting in
895 disassembly output. The default behaviour is determined via a
896 configure time option. Note, not all architectures support colored
897 syntax highlighting, and depending upon the terminal used, colored
898 output may not actually be legible.
899 .Sp
900 The \fBon\fR argument adds colors using simple terminal colors.
901 .Sp
902 The \fBterminal\fR argument does the same, but only if the output
903 device is a terminal.
904 .Sp
905 The \fBextended\-color\fR argument is similar to the \fBon\fR
906 argument, but it uses 8\-bit colors. These may not work on all
907 terminals.
908 .Sp
909 The \fBoff\fR argument disables colored disassembly.
910 .IP \fB\-W[lLiaprmfFsoORtUuTgAckK]\fR 4
911 .IX Item "-W[lLiaprmfFsoORtUuTgAckK]"
912 .PD 0
913 .IP \fB\-\-dwarf[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames\-interp,=str,=str\-offsets,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index,=addr,=cu_index,=links,=follow\-links]\fR 4
914 .IX Item "--dwarf[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames-interp,=str,=str-offsets,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index,=addr,=cu_index,=links,=follow-links]"
915 .PD
916 Displays the contents of the DWARF debug sections in the file, if any
917 are present. Compressed debug sections are automatically decompressed
918 (temporarily) before they are displayed. If one or more of the
919 optional letters or words follows the switch then only those type(s)
920 of data will be dumped. The letters and words refer to the following
921 information:
922 .RS 4
923 .ie n .IP """a""" 4
924 .el .IP \f(CWa\fR 4
925 .IX Item "a"
926 .PD 0
927 .ie n .IP """=abbrev""" 4
928 .el .IP \f(CW=abbrev\fR 4
929 .IX Item "=abbrev"
930 .PD
931 Displays the contents of the \fB.debug_abbrev\fR section.
932 .ie n .IP """A""" 4
933 .el .IP \f(CWA\fR 4
934 .IX Item "A"
935 .PD 0
936 .ie n .IP """=addr""" 4
937 .el .IP \f(CW=addr\fR 4
938 .IX Item "=addr"
939 .PD
940 Displays the contents of the \fB.debug_addr\fR section.
941 .ie n .IP """c""" 4
942 .el .IP \f(CWc\fR 4
943 .IX Item "c"
944 .PD 0
945 .ie n .IP """=cu_index""" 4
946 .el .IP \f(CW=cu_index\fR 4
947 .IX Item "=cu_index"
948 .PD
949 Displays the contents of the \fB.debug_cu_index\fR and/or
950 \&\fB.debug_tu_index\fR sections.
951 .ie n .IP """f""" 4
952 .el .IP \f(CWf\fR 4
953 .IX Item "f"
954 .PD 0
955 .ie n .IP """=frames""" 4
956 .el .IP \f(CW=frames\fR 4
957 .IX Item "=frames"
958 .PD
959 Display the raw contents of a \fB.debug_frame\fR section.
960 .ie n .IP """F""" 4
961 .el .IP \f(CWF\fR 4
962 .IX Item "F"
963 .PD 0
964 .ie n .IP """=frames\-interp""" 4
965 .el .IP \f(CW=frames\-interp\fR 4
966 .IX Item "=frames-interp"
967 .PD
968 Display the interpreted contents of a \fB.debug_frame\fR section.
969 .ie n .IP """g""" 4
970 .el .IP \f(CWg\fR 4
971 .IX Item "g"
972 .PD 0
973 .ie n .IP """=gdb_index""" 4
974 .el .IP \f(CW=gdb_index\fR 4
975 .IX Item "=gdb_index"
976 .PD
977 Displays the contents of the \fB.gdb_index\fR and/or
978 \&\fB.debug_names\fR sections.
979 .ie n .IP """i""" 4
980 .el .IP \f(CWi\fR 4
981 .IX Item "i"
982 .PD 0
983 .ie n .IP """=info""" 4
984 .el .IP \f(CW=info\fR 4
985 .IX Item "=info"
986 .PD
987 Displays the contents of the \fB.debug_info\fR section. Note: the
988 output from this option can also be restricted by the use of the
989 \&\fB\-\-dwarf\-depth\fR and \fB\-\-dwarf\-start\fR options.
990 .ie n .IP """k""" 4
991 .el .IP \f(CWk\fR 4
992 .IX Item "k"
993 .PD 0
994 .ie n .IP """=links""" 4
995 .el .IP \f(CW=links\fR 4
996 .IX Item "=links"
997 .PD
998 Displays the contents of the \fB.gnu_debuglink\fR,
999 \&\fB.gnu_debugaltlink\fR and \fB.debug_sup\fR sections, if any of
1000 them are present. Also displays any links to separate dwarf object
1001 files (dwo), if they are specified by the DW_AT_GNU_dwo_name or
1002 DW_AT_dwo_name attributes in the \fB.debug_info\fR section.
1003 .ie n .IP """K""" 4
1004 .el .IP \f(CWK\fR 4
1005 .IX Item "K"
1006 .PD 0
1007 .ie n .IP """=follow\-links""" 4
1008 .el .IP \f(CW=follow\-links\fR 4
1009 .IX Item "=follow-links"
1010 .PD
1011 Display the contents of any selected debug sections that are found in
1012 linked, separate debug info file(s). This can result in multiple
1013 versions of the same debug section being displayed if it exists in
1014 more than one file.
1015 .Sp
1016 In addition, when displaying DWARF attributes, if a form is found that
1017 references the separate debug info file, then the referenced contents
1018 will also be displayed.
1019 .Sp
1020 Note \- in some distributions this option is enabled by default. It
1021 can be disabled via the \fBN\fR debug option. The default can be
1022 chosen when configuring the binutils via the
1023 \&\fB\-\-enable\-follow\-debug\-links=yes\fR or
1024 \&\fB\-\-enable\-follow\-debug\-links=no\fR options. If these are not
1025 used then the default is to enable the following of debug links.
1026 .Sp
1027 Note \- if support for the debuginfod protocol was enabled when the
1028 binutils were built then this option will also include an attempt to
1029 contact any debuginfod servers mentioned in the \fIDEBUGINFOD_URLS\fR
1030 environment variable. This could take some time to resolve. This
1031 behaviour can be disabled via the \fB=do\-not\-use\-debuginfod\fR debug
1032 option.
1033 .ie n .IP """N""" 4
1034 .el .IP \f(CWN\fR 4
1035 .IX Item "N"
1036 .PD 0
1037 .ie n .IP """=no\-follow\-links""" 4
1038 .el .IP \f(CW=no\-follow\-links\fR 4
1039 .IX Item "=no-follow-links"
1040 .PD
1041 Disables the following of links to separate debug info files.
1042 .ie n .IP """D""" 4
1043 .el .IP \f(CWD\fR 4
1044 .IX Item "D"
1045 .PD 0
1046 .ie n .IP """=use\-debuginfod""" 4
1047 .el .IP \f(CW=use\-debuginfod\fR 4
1048 .IX Item "=use-debuginfod"
1049 .PD
1050 Enables contacting debuginfod servers if there is a need to follow
1051 debug links. This is the default behaviour.
1052 .ie n .IP """E""" 4
1053 .el .IP \f(CWE\fR 4
1054 .IX Item "E"
1055 .PD 0
1056 .ie n .IP """=do\-not\-use\-debuginfod""" 4
1057 .el .IP \f(CW=do\-not\-use\-debuginfod\fR 4
1058 .IX Item "=do-not-use-debuginfod"
1059 .PD
1060 Disables contacting debuginfod servers when there is a need to follow
1061 debug links.
1062 .ie n .IP """l""" 4
1063 .el .IP \f(CWl\fR 4
1064 .IX Item "l"
1065 .PD 0
1066 .ie n .IP """=rawline""" 4
1067 .el .IP \f(CW=rawline\fR 4
1068 .IX Item "=rawline"
1069 .PD
1070 Displays the contents of the \fB.debug_line\fR section in a raw
1071 format.
1072 .ie n .IP """L""" 4
1073 .el .IP \f(CWL\fR 4
1074 .IX Item "L"
1075 .PD 0
1076 .ie n .IP """=decodedline""" 4
1077 .el .IP \f(CW=decodedline\fR 4
1078 .IX Item "=decodedline"
1079 .PD
1080 Displays the interpreted contents of the \fB.debug_line\fR section.
1081 .ie n .IP """m""" 4
1082 .el .IP \f(CWm\fR 4
1083 .IX Item "m"
1084 .PD 0
1085 .ie n .IP """=macro""" 4
1086 .el .IP \f(CW=macro\fR 4
1087 .IX Item "=macro"
1088 .PD
1089 Displays the contents of the \fB.debug_macro\fR and/or
1090 \&\fB.debug_macinfo\fR sections.
1091 .ie n .IP """o""" 4
1092 .el .IP \f(CWo\fR 4
1093 .IX Item "o"
1094 .PD 0
1095 .ie n .IP """=loc""" 4
1096 .el .IP \f(CW=loc\fR 4
1097 .IX Item "=loc"
1098 .PD
1099 Displays the contents of the \fB.debug_loc\fR and/or
1100 \&\fB.debug_loclists\fR sections.
1101 .ie n .IP """O""" 4
1102 .el .IP \f(CWO\fR 4
1103 .IX Item "O"
1104 .PD 0
1105 .ie n .IP """=str\-offsets""" 4
1106 .el .IP \f(CW=str\-offsets\fR 4
1107 .IX Item "=str-offsets"
1108 .PD
1109 Displays the contents of the \fB.debug_str_offsets\fR section.
1110 .ie n .IP """p""" 4
1111 .el .IP \f(CWp\fR 4
1112 .IX Item "p"
1113 .PD 0
1114 .ie n .IP """=pubnames""" 4
1115 .el .IP \f(CW=pubnames\fR 4
1116 .IX Item "=pubnames"
1117 .PD
1118 Displays the contents of the \fB.debug_pubnames\fR and/or
1119 \&\fB.debug_gnu_pubnames\fR sections.
1120 .ie n .IP """r""" 4
1121 .el .IP \f(CWr\fR 4
1122 .IX Item "r"
1123 .PD 0
1124 .ie n .IP """=aranges""" 4
1125 .el .IP \f(CW=aranges\fR 4
1126 .IX Item "=aranges"
1127 .PD
1128 Displays the contents of the \fB.debug_aranges\fR section.
1129 .ie n .IP """R""" 4
1130 .el .IP \f(CWR\fR 4
1131 .IX Item "R"
1132 .PD 0
1133 .ie n .IP """=Ranges""" 4
1134 .el .IP \f(CW=Ranges\fR 4
1135 .IX Item "=Ranges"
1136 .PD
1137 Displays the contents of the \fB.debug_ranges\fR and/or
1138 \&\fB.debug_rnglists\fR sections.
1139 .ie n .IP """s""" 4
1140 .el .IP \f(CWs\fR 4
1141 .IX Item "s"
1142 .PD 0
1143 .ie n .IP """=str""" 4
1144 .el .IP \f(CW=str\fR 4
1145 .IX Item "=str"
1146 .PD
1147 Displays the contents of the \fB.debug_str\fR, \fB.debug_line_str\fR
1148 and/or \fB.debug_str_offsets\fR sections.
1149 .ie n .IP """t""" 4
1150 .el .IP \f(CWt\fR 4
1151 .IX Item "t"
1152 .PD 0
1153 .ie n .IP """=pubtype""" 4
1154 .el .IP \f(CW=pubtype\fR 4
1155 .IX Item "=pubtype"
1156 .PD
1157 Displays the contents of the \fB.debug_pubtypes\fR and/or
1158 \&\fB.debug_gnu_pubtypes\fR sections.
1159 .ie n .IP """T""" 4
1160 .el .IP \f(CWT\fR 4
1161 .IX Item "T"
1162 .PD 0
1163 .ie n .IP """=trace_aranges""" 4
1164 .el .IP \f(CW=trace_aranges\fR 4
1165 .IX Item "=trace_aranges"
1166 .PD
1167 Displays the contents of the \fB.trace_aranges\fR section.
1168 .ie n .IP """u""" 4
1169 .el .IP \f(CWu\fR 4
1170 .IX Item "u"
1171 .PD 0
1172 .ie n .IP """=trace_abbrev""" 4
1173 .el .IP \f(CW=trace_abbrev\fR 4
1174 .IX Item "=trace_abbrev"
1175 .PD
1176 Displays the contents of the \fB.trace_abbrev\fR section.
1177 .ie n .IP """U""" 4
1178 .el .IP \f(CWU\fR 4
1179 .IX Item "U"
1180 .PD 0
1181 .ie n .IP """=trace_info""" 4
1182 .el .IP \f(CW=trace_info\fR 4
1183 .IX Item "=trace_info"
1184 .PD
1185 Displays the contents of the \fB.trace_info\fR section.
1186 .RE
1187 .RS 4
1188 .Sp
1189 Note: displaying the contents of \fB.debug_static_funcs\fR,
1190 \&\fB.debug_static_vars\fR and \fBdebug_weaknames\fR sections is not
1191 currently supported.
1192 .RE
1193 .IP \fB\-\-dwarf\-depth=\fR\fIn\fR 4
1194 .IX Item "--dwarf-depth=n"
1195 Limit the dump of the \f(CW\*(C`.debug_info\*(C'\fR section to \fIn\fR children.
1196 This is only useful with \fB\-\-debug\-dump=info\fR. The default is
1197 to print all DIEs; the special value 0 for \fIn\fR will also have this
1198 effect.
1199 .Sp
1200 With a non\-zero value for \fIn\fR, DIEs at or deeper than \fIn\fR
1201 levels will not be printed. The range for \fIn\fR is zero\-based.
1202 .IP \fB\-\-dwarf\-start=\fR\fIn\fR 4
1203 .IX Item "--dwarf-start=n"
1204 Print only DIEs beginning with the DIE numbered \fIn\fR. This is only
1205 useful with \fB\-\-debug\-dump=info\fR.
1206 .Sp
1207 If specified, this option will suppress printing of any header
1208 information and all DIEs before the DIE numbered \fIn\fR. Only
1209 siblings and children of the specified DIE will be printed.
1210 .Sp
1211 This can be used in conjunction with \fB\-\-dwarf\-depth\fR.
1212 .IP \fB\-\-dwarf\-check\fR 4
1213 .IX Item "--dwarf-check"
1214 Enable additional checks for consistency of Dwarf information.
1215 .IP \fB\-\-debug\-dir=\fR\f(BIdir\fR 4
1216 .IX Item "--debug-dir=dir"
1217 Search \fIdir\fR when looking for separate debug info files.
1218 .IP \fB\-\-ctf[=\fR\fIsection\fR\fB]\fR 4
1219 .IX Item "--ctf[=section]"
1220 Display the contents of the specified CTF section. CTF sections themselves
1221 contain many subsections, all of which are displayed in order.
1222 .Sp
1223 By default, display the name of the section named \fI.ctf\fR, which is the
1224 name emitted by \fBld\fR.
1225 .IP \fB\-\-ctf\-parent=\fR\fImember\fR 4
1226 .IX Item "--ctf-parent=member"
1227 If the CTF section contains ambiguously\-defined types, it will consist
1228 of an archive of many CTF dictionaries, all inheriting from one
1229 dictionary containing unambiguous types. This member is by default
1230 named \fI.ctf\fR, like the section containing it, but it is possible to
1231 change this name using the \f(CW\*(C`ctf_link_set_memb_name_changer\*(C'\fR
1232 function at link time. When looking at CTF archives that have been
1233 created by a linker that uses the name changer to rename the parent
1234 archive member, \fB\-\-ctf\-parent\fR can be used to specify the name
1235 used for the parent.
1236 .IP \fB\-\-ctf\-parent\-section=\fR\fIsection\fR 4
1237 .IX Item "--ctf-parent-section=section"
1238 This option lets you pick a completely different section for the CTF
1239 parent dictionary containing unambiguous types than for the child
1240 dictionaries that contain the ambiguous remainder. The linker does
1241 not emit ELF objects structured like this, but some third\-party linkers
1242 may. It\*(Aqs also convenient to inspect CTF written out as multiple raw
1243 files to compose them with objcopy, which can put them in different
1244 ELF sections but not in different members of a single CTF dict.
1245 .IP \fB\-\-sframe[=\fR\fIsection\fR\fB]\fR 4
1246 .IX Item "--sframe[=section]"
1247 Display the contents of the specified SFrame section.
1248 .Sp
1249 By default, display the name of the section named \fI.sframe\fR, which is the
1250 name emitted by \fBld\fR.
1251 .IP \fB\-G\fR 4
1252 .IX Item "-G"
1253 .PD 0
1254 .IP \fB\-\-stabs\fR 4
1255 .IX Item "--stabs"
1256 .PD
1257 Display the full contents of any sections requested. Display the
1258 contents of the .stab and .stab.index and .stab.excl sections from an
1259 ELF file. This is only useful on systems (such as Solaris 2.0) in which
1260 \&\f(CW\*(C`.stab\*(C'\fR debugging symbol\-table entries are carried in an ELF
1261 section. In most other file formats, debugging symbol\-table entries are
1262 interleaved with linkage symbols, and are visible in the \fB\-\-syms\fR
1263 output.
1264 .IP \fB\-\-start\-address=\fR\fIaddress\fR 4
1265 .IX Item "--start-address=address"
1266 Start displaying data at the specified address. This affects the output
1267 of the \fB\-d\fR, \fB\-r\fR and \fB\-s\fR options.
1268 .IP \fB\-\-stop\-address=\fR\fIaddress\fR 4
1269 .IX Item "--stop-address=address"
1270 Stop displaying data at the specified address. This affects the output
1271 of the \fB\-d\fR, \fB\-r\fR and \fB\-s\fR options.
1272 .IP \fB\-t\fR 4
1273 .IX Item "-t"
1274 .PD 0
1275 .IP \fB\-\-syms\fR 4
1276 .IX Item "--syms"
1277 .PD
1278 Print the symbol table entries of the file.
1279 This is similar to the information provided by the \fBnm\fR program,
1280 although the display format is different. The format of the output
1281 depends upon the format of the file being dumped, but there are two main
1282 types. One looks like this:
1283 .Sp
1284 .Vb 2
1285 \& [ 4](sec 3)(fl 0x00)(ty 0)(scl 3) (nx 1) 0x00000000 .bss
1286 \& [ 6](sec 1)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 fred
1287 .Ve
1288 .Sp
1289 where the number inside the square brackets is the number of the entry
1290 in the symbol table, the \fIsec\fR number is the section number, the
1291 \&\fIfl\fR value are the symbol\*(Aqs flag bits, the \fIty\fR number is the
1292 symbol\*(Aqs type, the \fIscl\fR number is the symbol\*(Aqs storage class and
1293 the \fInx\fR value is the number of auxiliary entries associated with
1294 the symbol. The last two fields are the symbol\*(Aqs value and its name.
1295 .Sp
1296 The other common output format, usually seen with ELF based files,
1297 looks like this:
1298 .Sp
1299 .Vb 2
1300 \& 00000000 l d .bss 00000000 .bss
1301 \& 00000000 g .text 00000000 fred
1302 .Ve
1303 .Sp
1304 Here the first number is the symbol\*(Aqs value (sometimes referred to as
1305 its address). The next field is actually a set of characters and
1306 spaces indicating the flag bits that are set on the symbol. These
1307 characters are described below. Next is the section with which the
1308 symbol is associated or \fI*ABS*\fR if the section is absolute (ie
1309 not connected with any section), or \fI*UND*\fR if the section is
1310 referenced in the file being dumped, but not defined there.
1311 .Sp
1312 After the section name comes another field, a number, which for common
1313 symbols is the alignment and for other symbol is the size. Finally
1314 the symbol\*(Aqs name is displayed.
1315 .Sp
1316 The flag characters are divided into 7 groups as follows:
1317 .RS 4
1318 .ie n .IP """l""" 4
1319 .el .IP \f(CWl\fR 4
1320 .IX Item "l"
1321 .PD 0
1322 .ie n .IP """g""" 4
1323 .el .IP \f(CWg\fR 4
1324 .IX Item "g"
1325 .ie n .IP """u""" 4
1326 .el .IP \f(CWu\fR 4
1327 .IX Item "u"
1328 .ie n .IP """!""" 4
1329 .el .IP \f(CW!\fR 4
1330 .IX Item "!"
1331 .PD
1332 The symbol is a local (l), global (g), unique global (u), neither
1333 global nor local (a space) or both global and local (!). A
1334 symbol can be neither local or global for a variety of reasons, e.g.,
1335 because it is used for debugging, but it is probably an indication of
1336 a bug if it is ever both local and global. Unique global symbols are
1337 a GNU extension to the standard set of ELF symbol bindings. For such
1338 a symbol the dynamic linker will make sure that in the entire process
1339 there is just one symbol with this name and type in use.
1340 .ie n .IP """w""" 4
1341 .el .IP \f(CWw\fR 4
1342 .IX Item "w"
1343 The symbol is weak (w) or strong (a space).
1344 .ie n .IP """C""" 4
1345 .el .IP \f(CWC\fR 4
1346 .IX Item "C"
1347 The symbol denotes a constructor (C) or an ordinary symbol (a space).
1348 .ie n .IP """W""" 4
1349 .el .IP \f(CWW\fR 4
1350 .IX Item "W"
1351 The symbol is a warning (W) or a normal symbol (a space). A warning
1352 symbol\*(Aqs name is a message to be displayed if the symbol following the
1353 warning symbol is ever referenced.
1354 .ie n .IP """I""" 4
1355 .el .IP \f(CWI\fR 4
1356 .IX Item "I"
1357 .PD 0
1358 .ie n .IP """i""" 4
1359 .el .IP \f(CWi\fR 4
1360 .IX Item "i"
1361 .PD
1362 The symbol is an indirect reference to another symbol (I), a function
1363 to be evaluated during reloc processing (i) or a normal symbol (a
1364 space).
1365 .ie n .IP """d""" 4
1366 .el .IP \f(CWd\fR 4
1367 .IX Item "d"
1368 .PD 0
1369 .ie n .IP """D""" 4
1370 .el .IP \f(CWD\fR 4
1371 .IX Item "D"
1372 .PD
1373 The symbol is a debugging symbol (d) or a dynamic symbol (D) or a
1374 normal symbol (a space).
1375 .ie n .IP """F""" 4
1376 .el .IP \f(CWF\fR 4
1377 .IX Item "F"
1378 .PD 0
1379 .ie n .IP """f""" 4
1380 .el .IP \f(CWf\fR 4
1381 .IX Item "f"
1382 .ie n .IP """O""" 4
1383 .el .IP \f(CWO\fR 4
1384 .IX Item "O"
1385 .PD
1386 The symbol is the name of a function (F) or a file (f) or an object
1387 (O) or just a normal symbol (a space).
1388 .RE
1389 .RS 4
1390 .RE
1391 .IP \fB\-T\fR 4
1392 .IX Item "-T"
1393 .PD 0
1394 .IP \fB\-\-dynamic\-syms\fR 4
1395 .IX Item "--dynamic-syms"
1396 .PD
1397 Print the dynamic symbol table entries of the file. This is only
1398 meaningful for dynamic objects, such as certain types of shared
1399 libraries. This is similar to the information provided by the \fBnm\fR
1400 program when given the \fB\-D\fR (\fB\-\-dynamic\fR) option.
1401 .Sp
1402 The output format is similar to that produced by the \fB\-\-syms\fR
1403 option, except that an extra field is inserted before the symbol\*(Aqs
1404 name, giving the version information associated with the symbol.
1405 If the version is the default version to be used when resolving
1406 unversioned references to the symbol then it\*(Aqs displayed as is,
1407 otherwise it\*(Aqs put into parentheses.
1408 .IP \fB\-\-special\-syms\fR 4
1409 .IX Item "--special-syms"
1410 When displaying symbols include those which the target considers to be
1411 special in some way and which would not normally be of interest to the
1412 user.
1413 .IP "\fB\-U\fR \fI[d|i|l|e|x|h]\fR" 4
1414 .IX Item "-U [d|i|l|e|x|h]"
1415 .PD 0
1416 .IP \fB\-\-unicode=\fR\fI[default|invalid|locale|escape|hex|highlight]\fR 4
1417 .IX Item "--unicode=[default|invalid|locale|escape|hex|highlight]"
1418 .PD
1419 Controls the display of UTF\-8 encoded multibyte characters in strings.
1420 The default (\fB\-\-unicode=default\fR) is to give them no special
1421 treatment. The \fB\-\-unicode=locale\fR option displays the sequence
1422 in the current locale, which may or may not support them. The options
1423 \&\fB\-\-unicode=hex\fR and \fB\-\-unicode=invalid\fR display them as
1424 hex byte sequences enclosed by either angle brackets or curly braces.
1425 .Sp
1426 The \fB\-\-unicode=escape\fR option displays them as escape sequences
1427 (\fI\euxxxx\fR) and the \fB\-\-unicode=highlight\fR option displays
1428 them as escape sequences highlighted in red (if supported by the
1429 output device). The colouring is intended to draw attention to the
1430 presence of unicode sequences where they might not be expected.
1431 .IP \fB\-V\fR 4
1432 .IX Item "-V"
1433 .PD 0
1434 .IP \fB\-\-version\fR 4
1435 .IX Item "--version"
1436 .PD
1437 Print the version number of \fBobjdump\fR and exit.
1438 .IP \fB\-x\fR 4
1439 .IX Item "-x"
1440 .PD 0
1441 .IP \fB\-\-all\-headers\fR 4
1442 .IX Item "--all-headers"
1443 .PD
1444 Display all available header information, including the symbol table and
1445 relocation entries. Using \fB\-x\fR is equivalent to specifying all of
1446 \&\fB\-a \-f \-h \-p \-r \-t\fR.
1447 .IP \fB\-w\fR 4
1448 .IX Item "-w"
1449 .PD 0
1450 .IP \fB\-\-wide\fR 4
1451 .IX Item "--wide"
1452 .PD
1453 Format some lines for output devices that have more than 80 columns.
1454 Also do not truncate symbol names when they are displayed.
1455 .IP \fB\-z\fR 4
1456 .IX Item "-z"
1457 .PD 0
1458 .IP \fB\-\-disassemble\-zeroes\fR 4
1459 .IX Item "--disassemble-zeroes"
1460 .PD
1461 Normally the disassembly output will skip blocks of zeroes. This
1462 option directs the disassembler to disassemble those blocks, just like
1463 any other data.
1464 .IP \fB\-Z\fR 4
1465 .IX Item "-Z"
1466 .PD 0
1467 .IP \fB\-\-decompress\fR 4
1468 .IX Item "--decompress"
1469 .PD
1470 The \fB\-Z\fR option is meant to be used in conunction with the
1471 \&\fB\-s\fR option. It instructs \fBobjdump\fR to decompress any
1472 compressed sections before displaying their contents.
1473 .IP \fB@\fR\fIfile\fR 4
1474 .IX Item "@file"
1475 Read command\-line options from \fIfile\fR. The options read are
1476 inserted in place of the original @\fIfile\fR option. If \fIfile\fR
1477 does not exist, or cannot be read, then the option will be treated
1478 literally, and not removed.
1479 .Sp
1480 Options in \fIfile\fR are separated by whitespace. A whitespace
1481 character may be included in an option by surrounding the entire
1482 option in either single or double quotes. Any character (including a
1483 backslash) may be included by prefixing the character to be included
1484 with a backslash. The \fIfile\fR may itself contain additional
1485 @\fIfile\fR options; any such options will be processed recursively.
1486 .SH "SEE ALSO"
1487 .IX Header "SEE ALSO"
1488 \&\fBnm\fR\|(1), \fBreadelf\fR\|(1), and the Info entries for \fIbinutils\fR.
1489 .SH COPYRIGHT
1490 .IX Header "COPYRIGHT"
1491 Copyright (c) 1991\-2026 Free Software Foundation, Inc.
1492 .PP
1493 Permission is granted to copy, distribute and/or modify this document
1494 under the terms of the GNU Free Documentation License, Version 1.3
1495 or any later version published by the Free Software Foundation;
1496 with no Invariant Sections, with no Front\-Cover Texts, and with no
1497 Back\-Cover Texts. A copy of the license is included in the
1498 section entitled "GNU Free Documentation License".