1OBJDUMP(1) GNU Development Tools OBJDUMP(1)
2
3
4
6 objdump - display information from object files
7
9 objdump [-a|--archive-headers]
10 [-b bfdname|--target=bfdname]
11 [-C|--demangle[=style] ]
12 [-d|--disassemble[=symbol]]
13 [-D|--disassemble-all]
14 [-z|--disassemble-zeroes]
15 [-EB|-EL|--endian={big | little }]
16 [-f|--file-headers]
17 [-F|--file-offsets]
18 [--file-start-context]
19 [-g|--debugging]
20 [-e|--debugging-tags]
21 [-h|--section-headers|--headers]
22 [-i|--info]
23 [-j section|--section=section]
24 [-l|--line-numbers]
25 [-S|--source]
26 [--source-comment[=text]]
27 [-m machine|--architecture=machine]
28 [-M options|--disassembler-options=options]
29 [-p|--private-headers]
30 [-P options|--private=options]
31 [-r|--reloc]
32 [-R|--dynamic-reloc]
33 [-s|--full-contents]
34 [-W[lLiaprmfFsoORtUuTgAck]|
35 --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]]
36 [-WK|--dwarf=follow-links]
37 [-WN|--dwarf=no-follow-links]
38 [-wD|--dwarf=use-debuginfod]
39 [-wE|--dwarf=do-not-use-debuginfod]
40 [-L|--process-links]
41 [--ctf=section]
42 [--sframe=section]
43 [-G|--stabs]
44 [-t|--syms]
45 [-T|--dynamic-syms]
46 [-x|--all-headers]
47 [-w|--wide]
48 [--start-address=address]
49 [--stop-address=address]
50 [--no-addresses]
51 [--prefix-addresses]
52 [--[no-]show-raw-insn]
53 [--adjust-vma=offset]
54 [--show-all-symbols]
55 [--dwarf-depth=n]
56 [--dwarf-start=n]
57 [--ctf-parent=section]
58 [--no-recurse-limit|--recurse-limit]
59 [--special-syms]
60 [--prefix=prefix]
61 [--prefix-strip=level]
62 [--insn-width=width]
63 [--visualize-jumps[=color|=extended-color|=off]
64 [--disassembler-color=[off|terminal|on|extended]
65 [-U method] [--unicode=method]
66 [-V|--version]
67 [-H|--help]
68 objfile...
69
71 objdump displays information about one or more object files. The
72 options control what particular information to display. This
73 information is mostly useful to programmers who are working on the
74 compilation tools, as opposed to programmers who just want their
75 program to compile and work.
76
77 objfile... are the object files to be examined. When you specify
78 archives, objdump shows information on each of the member object files.
79
81 The long and short forms of options, shown here as alternatives, are
82 equivalent. At least one option from the list
83 -a,-d,-D,-e,-f,-g,-G,-h,-H,-p,-P,-r,-R,-s,-S,-t,-T,-V,-x must be given.
84
85 -a
86 --archive-header
87 If any of the objfile files are archives, display the archive
88 header information (in a format similar to ls -l). Besides the
89 information you could list with ar tv, objdump -a shows the object
90 file format of each archive member.
91
92 --adjust-vma=offset
93 When dumping information, first add offset to all the section
94 addresses. This is useful if the section addresses do not
95 correspond to the symbol table, which can happen when putting
96 sections at particular addresses when using a format which can not
97 represent section addresses, such as a.out.
98
99 -b bfdname
100 --target=bfdname
101 Specify that the object-code format for the object files is
102 bfdname. This option may not be necessary; objdump can
103 automatically recognize many formats.
104
105 For example,
106
107 objdump -b oasys -m vax -h fu.o
108
109 displays summary information from the section headers (-h) of fu.o,
110 which is explicitly identified (-m) as a VAX object file in the
111 format produced by Oasys compilers. You can list the formats
112 available with the -i option.
113
114 -C
115 --demangle[=style]
116 Decode (demangle) low-level symbol names into user-level names.
117 Besides removing any initial underscore prepended by the system,
118 this makes C++ function names readable. Different compilers have
119 different mangling styles. The optional demangling style argument
120 can be used to choose an appropriate demangling style for your
121 compiler.
122
123 --recurse-limit
124 --no-recurse-limit
125 --recursion-limit
126 --no-recursion-limit
127 Enables or disables a limit on the amount of recursion performed
128 whilst demangling strings. Since the name mangling formats allow
129 for an infinite level of recursion it is possible to create strings
130 whose decoding will exhaust the amount of stack space available on
131 the host machine, triggering a memory fault. The limit tries to
132 prevent this from happening by restricting recursion to 2048 levels
133 of nesting.
134
135 The default is for this limit to be enabled, but disabling it may
136 be necessary in order to demangle truly complicated names. Note
137 however that if the recursion limit is disabled then stack
138 exhaustion is possible and any bug reports about such an event will
139 be rejected.
140
141 -g
142 --debugging
143 Display debugging information. This attempts to parse STABS
144 debugging format information stored in the file and print it out
145 using a C like syntax. If no STABS debugging was found this option
146 falls back on the -W option to print any DWARF information in the
147 file.
148
149 -e
150 --debugging-tags
151 Like -g, but the information is generated in a format compatible
152 with ctags tool.
153
154 -d
155 --disassemble
156 --disassemble=symbol
157 Display the assembler mnemonics for the machine instructions from
158 the input file. This option only disassembles those sections which
159 are expected to contain instructions. If the optional symbol
160 argument is given, then display the assembler mnemonics starting at
161 symbol. If symbol is a function name then disassembly will stop at
162 the end of the function, otherwise it will stop when the next
163 symbol is encountered. If there are no matches for symbol then
164 nothing will be displayed.
165
166 Note if the --dwarf=follow-links option is enabled then any symbol
167 tables in linked debug info files will be read in and used when
168 disassembling.
169
170 -D
171 --disassemble-all
172 Like -d, but disassemble the contents of all non-empty non-bss
173 sections, not just those expected to contain instructions. -j may
174 be used to select specific sections.
175
176 This option also has a subtle effect on the disassembly of
177 instructions in code sections. When option -d is in effect objdump
178 will assume that any symbols present in a code section occur on the
179 boundary between instructions and it will refuse to disassemble
180 across such a boundary. When option -D is in effect however this
181 assumption is supressed. This means that it is possible for the
182 output of -d and -D to differ if, for example, data is stored in
183 code sections.
184
185 If the target is an ARM architecture this switch also has the
186 effect of forcing the disassembler to decode pieces of data found
187 in code sections as if they were instructions.
188
189 Note if the --dwarf=follow-links option is enabled then any symbol
190 tables in linked debug info files will be read in and used when
191 disassembling.
192
193 --no-addresses
194 When disassembling, don't print addresses on each line or for
195 symbols and relocation offsets. In combination with
196 --no-show-raw-insn this may be useful for comparing compiler
197 output.
198
199 --prefix-addresses
200 When disassembling, print the complete address on each line. This
201 is the older disassembly format.
202
203 -EB
204 -EL
205 --endian={big|little}
206 Specify the endianness of the object files. This only affects
207 disassembly. This can be useful when disassembling a file format
208 which does not describe endianness information, such as S-records.
209
210 -f
211 --file-headers
212 Display summary information from the overall header of each of the
213 objfile files.
214
215 -F
216 --file-offsets
217 When disassembling sections, whenever a symbol is displayed, also
218 display the file offset of the region of data that is about to be
219 dumped. If zeroes are being skipped, then when disassembly
220 resumes, tell the user how many zeroes were skipped and the file
221 offset of the location from where the disassembly resumes. When
222 dumping sections, display the file offset of the location from
223 where the dump starts.
224
225 --file-start-context
226 Specify that when displaying interlisted source code/disassembly
227 (assumes -S) from a file that has not yet been displayed, extend
228 the context to the start of the file.
229
230 -h
231 --section-headers
232 --headers
233 Display summary information from the section headers of the object
234 file.
235
236 File segments may be relocated to nonstandard addresses, for
237 example by using the -Ttext, -Tdata, or -Tbss options to ld.
238 However, some object file formats, such as a.out, do not store the
239 starting address of the file segments. In those situations,
240 although ld relocates the sections correctly, using objdump -h to
241 list the file section headers cannot show the correct addresses.
242 Instead, it shows the usual addresses, which are implicit for the
243 target.
244
245 Note, in some cases it is possible for a section to have both the
246 READONLY and the NOREAD attributes set. In such cases the NOREAD
247 attribute takes precedence, but objdump will report both since the
248 exact setting of the flag bits might be important.
249
250 -H
251 --help
252 Print a summary of the options to objdump and exit.
253
254 -i
255 --info
256 Display a list showing all architectures and object formats
257 available for specification with -b or -m.
258
259 -j name
260 --section=name
261 Display information for section name. This option may be specified
262 multiple times.
263
264 -L
265 --process-links
266 Display the contents of non-debug sections found in separate
267 debuginfo files that are linked to the main file. This option
268 automatically implies the -WK option, and only sections requested
269 by other command line options will be displayed.
270
271 -l
272 --line-numbers
273 Label the display (using debugging information) with the filename
274 and source line numbers corresponding to the object code or relocs
275 shown. Only useful with -d, -D, or -r.
276
277 -m machine
278 --architecture=machine
279 Specify the architecture to use when disassembling object files.
280 This can be useful when disassembling object files which do not
281 describe architecture information, such as S-records. You can list
282 the available architectures with the -i option.
283
284 For most architectures it is possible to supply an architecture
285 name and a machine name, separated by a colon. For example foo:bar
286 would refer to the bar machine type in the foo architecture. This
287 can be helpful if objdump has been configured to support multiple
288 architectures.
289
290 If the target is an ARM architecture then this switch has an
291 additional effect. It restricts the disassembly to only those
292 instructions supported by the architecture specified by machine.
293 If it is necessary to use this switch because the input file does
294 not contain any architecture information, but it is also desired to
295 disassemble all the instructions use -marm.
296
297 -M options
298 --disassembler-options=options
299 Pass target specific information to the disassembler. Only
300 supported on some targets. If it is necessary to specify more than
301 one disassembler option then multiple -M options can be used or can
302 be placed together into a comma separated list.
303
304 For ARC, dsp controls the printing of DSP instructions, spfp
305 selects the printing of FPX single precision FP instructions, dpfp
306 selects the printing of FPX double precision FP instructions,
307 quarkse_em selects the printing of special QuarkSE-EM instructions,
308 fpuda selects the printing of double precision assist instructions,
309 fpus selects the printing of FPU single precision FP instructions,
310 while fpud selects the printing of FPU double precision FP
311 instructions. Additionally, one can choose to have all the
312 immediates printed in hexadecimal using hex. By default, the short
313 immediates are printed using the decimal representation, while the
314 long immediate values are printed as hexadecimal.
315
316 cpu=... allows one to enforce a particular ISA when disassembling
317 instructions, overriding the -m value or whatever is in the ELF
318 file. This might be useful to select ARC EM or HS ISA, because
319 architecture is same for those and disassembler relies on private
320 ELF header data to decide if code is for EM or HS. This option
321 might be specified multiple times - only the latest value will be
322 used. Valid values are same as for the assembler -mcpu=... option.
323
324 If the target is an ARM architecture then this switch can be used
325 to select which register name set is used during disassembler.
326 Specifying -M reg-names-std (the default) will select the register
327 names as used in ARM's instruction set documentation, but with
328 register 13 called 'sp', register 14 called 'lr' and register 15
329 called 'pc'. Specifying -M reg-names-apcs will select the name set
330 used by the ARM Procedure Call Standard, whilst specifying -M reg-
331 names-raw will just use r followed by the register number.
332
333 There are also two variants on the APCS register naming scheme
334 enabled by -M reg-names-atpcs and -M reg-names-special-atpcs which
335 use the ARM/Thumb Procedure Call Standard naming conventions.
336 (Either with the normal register names or the special register
337 names).
338
339 This option can also be used for ARM architectures to force the
340 disassembler to interpret all instructions as Thumb instructions by
341 using the switch --disassembler-options=force-thumb. This can be
342 useful when attempting to disassemble thumb code produced by other
343 compilers.
344
345 For AArch64 targets this switch can be used to set whether
346 instructions are disassembled as the most general instruction using
347 the -M no-aliases option or whether instruction notes should be
348 generated as comments in the disasssembly using -M notes.
349
350 For the x86, some of the options duplicate functions of the -m
351 switch, but allow finer grained control.
352
353 "x86-64"
354 "i386"
355 "i8086"
356 Select disassembly for the given architecture.
357
358 "intel"
359 "att"
360 Select between intel syntax mode and AT&T syntax mode.
361
362 "amd64"
363 "intel64"
364 Select between AMD64 ISA and Intel64 ISA.
365
366 "intel-mnemonic"
367 "att-mnemonic"
368 Select between intel mnemonic mode and AT&T mnemonic mode.
369 Note: "intel-mnemonic" implies "intel" and "att-mnemonic"
370 implies "att".
371
372 "addr64"
373 "addr32"
374 "addr16"
375 "data32"
376 "data16"
377 Specify the default address size and operand size. These five
378 options will be overridden if "x86-64", "i386" or "i8086"
379 appear later in the option string.
380
381 "suffix"
382 When in AT&T mode and also for a limited set of instructions
383 when in Intel mode, instructs the disassembler to print a
384 mnemonic suffix even when the suffix could be inferred by the
385 operands or, for certain instructions, the execution mode's
386 defaults.
387
388 For PowerPC, the -M argument raw selects disasssembly of hardware
389 insns rather than aliases. For example, you will see "rlwinm"
390 rather than "clrlwi", and "addi" rather than "li". All of the -m
391 arguments for gas that select a CPU are supported. These are: 403,
392 405, 440, 464, 476, 601, 603, 604, 620, 7400, 7410, 7450, 7455,
393 750cl, 821, 850, 860, a2, booke, booke32, cell, com, e200z2,
394 e200z4, e300, e500, e500mc, e500mc64, e500x2, e5500, e6500, efs,
395 power4, power5, power6, power7, power8, power9, power10, ppc,
396 ppc32, ppc64, ppc64bridge, ppcps, pwr, pwr2, pwr4, pwr5, pwr5x,
397 pwr6, pwr7, pwr8, pwr9, pwr10, pwrx, titan, vle, and future. 32
398 and 64 modify the default or a prior CPU selection, disabling and
399 enabling 64-bit insns respectively. In addition, altivec, any,
400 lsp, htm, vsx, spe and spe2 add capabilities to a previous or
401 later CPU selection. any will disassemble any opcode known to
402 binutils, but in cases where an opcode has two different meanings
403 or different arguments, you may not see the disassembly you expect.
404 If you disassemble without giving a CPU selection, a default will
405 be chosen from information gleaned by BFD from the object files
406 headers, but the result again may not be as you expect.
407
408 For MIPS, this option controls the printing of instruction mnemonic
409 names and register names in disassembled instructions. Multiple
410 selections from the following may be specified as a comma separated
411 string, and invalid options are ignored:
412
413 "no-aliases"
414 Print the 'raw' instruction mnemonic instead of some pseudo
415 instruction mnemonic. I.e., print 'daddu' or 'or' instead of
416 'move', 'sll' instead of 'nop', etc.
417
418 "msa"
419 Disassemble MSA instructions.
420
421 "virt"
422 Disassemble the virtualization ASE instructions.
423
424 "xpa"
425 Disassemble the eXtended Physical Address (XPA) ASE
426 instructions.
427
428 "gpr-names=ABI"
429 Print GPR (general-purpose register) names as appropriate for
430 the specified ABI. By default, GPR names are selected
431 according to the ABI of the binary being disassembled.
432
433 "fpr-names=ABI"
434 Print FPR (floating-point register) names as appropriate for
435 the specified ABI. By default, FPR numbers are printed rather
436 than names.
437
438 "cp0-names=ARCH"
439 Print CP0 (system control coprocessor; coprocessor 0) register
440 names as appropriate for the CPU or architecture specified by
441 ARCH. By default, CP0 register names are selected according to
442 the architecture and CPU of the binary being disassembled.
443
444 "hwr-names=ARCH"
445 Print HWR (hardware register, used by the "rdhwr" instruction)
446 names as appropriate for the CPU or architecture specified by
447 ARCH. By default, HWR names are selected according to the
448 architecture and CPU of the binary being disassembled.
449
450 "reg-names=ABI"
451 Print GPR and FPR names as appropriate for the selected ABI.
452
453 "reg-names=ARCH"
454 Print CPU-specific register names (CP0 register and HWR names)
455 as appropriate for the selected CPU or architecture.
456
457 For any of the options listed above, ABI or ARCH may be specified
458 as numeric to have numbers printed rather than names, for the
459 selected types of registers. You can list the available values of
460 ABI and ARCH using the --help option.
461
462 For VAX, you can specify function entry addresses with -M
463 entry:0xf00ba. You can use this multiple times to properly
464 disassemble VAX binary files that don't contain symbol tables (like
465 ROM dumps). In these cases, the function entry mask would
466 otherwise be decoded as VAX instructions, which would probably lead
467 the rest of the function being wrongly disassembled.
468
469 -p
470 --private-headers
471 Print information that is specific to the object file format. The
472 exact information printed depends upon the object file format. For
473 some object file formats, no additional information is printed.
474
475 -P options
476 --private=options
477 Print information that is specific to the object file format. The
478 argument options is a comma separated list that depends on the
479 format (the lists of options is displayed with the help).
480
481 For XCOFF, the available options are:
482
483 "header"
484 "aout"
485 "sections"
486 "syms"
487 "relocs"
488 "lineno,"
489 "loader"
490 "except"
491 "typchk"
492 "traceback"
493 "toc"
494 "ldinfo"
495
496 For PE, the available options are:
497
498 "header"
499 "sections"
500
501 Not all object formats support this option. In particular the ELF
502 format does not use it.
503
504 -r
505 --reloc
506 Print the relocation entries of the file. If used with -d or -D,
507 the relocations are printed interspersed with the disassembly.
508
509 -R
510 --dynamic-reloc
511 Print the dynamic relocation entries of the file. This is only
512 meaningful for dynamic objects, such as certain types of shared
513 libraries. As for -r, if used with -d or -D, the relocations are
514 printed interspersed with the disassembly.
515
516 -s
517 --full-contents
518 Display the full contents of sections, often used in combination
519 with -j to request specific sections. By default all non-empty
520 non-bss sections are displayed.
521
522 -S
523 --source
524 Display source code intermixed with disassembly, if possible.
525 Implies -d.
526
527 --show-all-symbols
528 When disassembling, show all the symbols that match a given
529 address, not just the first one.
530
531 --source-comment[=txt]
532 Like the -S option, but all source code lines are displayed with a
533 prefix of txt. Typically txt will be a comment string which can be
534 used to distinguish the assembler code from the source code. If
535 txt is not provided then a default string of "# " (hash followed by
536 a space), will be used.
537
538 --prefix=prefix
539 Specify prefix to add to the absolute paths when used with -S.
540
541 --prefix-strip=level
542 Indicate how many initial directory names to strip off the
543 hardwired absolute paths. It has no effect without --prefix=prefix.
544
545 --show-raw-insn
546 When disassembling instructions, print the instruction in hex as
547 well as in symbolic form. This is the default except when
548 --prefix-addresses is used.
549
550 --no-show-raw-insn
551 When disassembling instructions, do not print the instruction
552 bytes. This is the default when --prefix-addresses is used.
553
554 --insn-width=width
555 Display width bytes on a single line when disassembling
556 instructions.
557
558 --visualize-jumps[=color|=extended-color|=off]
559 Visualize jumps that stay inside a function by drawing ASCII art
560 between the start and target addresses. The optional =color
561 argument adds color to the output using simple terminal colors.
562 Alternatively the =extended-color argument will add color using
563 8bit colors, but these might not work on all terminals.
564
565 If it is necessary to disable the visualize-jumps option after it
566 has previously been enabled then use visualize-jumps=off.
567
568 --disassembler-color=off
569 --disassembler-color=terminal
570 --disassembler-color=on|color|colour
571 --disassembler-color=extened|extended-color|extened-colour
572 Enables or disables the use of colored syntax highlighting in
573 disassembly output. The default behaviour is determined via a
574 configure time option. Note, not all architectures support colored
575 syntax highlighting, and depending upon the terminal used, colored
576 output may not actually be legible.
577
578 The on argument adds colors using simple terminal colors.
579
580 The terminal argument does the same, but only if the output device
581 is a terminal.
582
583 The extended-color argument is similar to the on argument, but it
584 uses 8-bit colors. These may not work on all terminals.
585
586 The off argument disables colored disassembly.
587
588 -W[lLiaprmfFsoORtUuTgAckK]
589 --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]
590 Displays the contents of the DWARF debug sections in the file, if
591 any are present. Compressed debug sections are automatically
592 decompressed (temporarily) before they are displayed. If one or
593 more of the optional letters or words follows the switch then only
594 those type(s) of data will be dumped. The letters and words refer
595 to the following information:
596
597 "a"
598 "=abbrev"
599 Displays the contents of the .debug_abbrev section.
600
601 "A"
602 "=addr"
603 Displays the contents of the .debug_addr section.
604
605 "c"
606 "=cu_index"
607 Displays the contents of the .debug_cu_index and/or
608 .debug_tu_index sections.
609
610 "f"
611 "=frames"
612 Display the raw contents of a .debug_frame section.
613
614 "F"
615 "=frames-interp"
616 Display the interpreted contents of a .debug_frame section.
617
618 "g"
619 "=gdb_index"
620 Displays the contents of the .gdb_index and/or .debug_names
621 sections.
622
623 "i"
624 "=info"
625 Displays the contents of the .debug_info section. Note: the
626 output from this option can also be restricted by the use of
627 the --dwarf-depth and --dwarf-start options.
628
629 "k"
630 "=links"
631 Displays the contents of the .gnu_debuglink, .gnu_debugaltlink
632 and .debug_sup sections, if any of them are present. Also
633 displays any links to separate dwarf object files (dwo), if
634 they are specified by the DW_AT_GNU_dwo_name or DW_AT_dwo_name
635 attributes in the .debug_info section.
636
637 "K"
638 "=follow-links"
639 Display the contents of any selected debug sections that are
640 found in linked, separate debug info file(s). This can result
641 in multiple versions of the same debug section being displayed
642 if it exists in more than one file.
643
644 In addition, when displaying DWARF attributes, if a form is
645 found that references the separate debug info file, then the
646 referenced contents will also be displayed.
647
648 Note - in some distributions this option is enabled by default.
649 It can be disabled via the N debug option. The default can be
650 chosen when configuring the binutils via the
651 --enable-follow-debug-links=yes or
652 --enable-follow-debug-links=no options. If these are not used
653 then the default is to enable the following of debug links.
654
655 Note - if support for the debuginfod protocol was enabled when
656 the binutils were built then this option will also include an
657 attempt to contact any debuginfod servers mentioned in the
658 DEBUGINFOD_URLS environment variable. This could take some
659 time to resolve. This behaviour can be disabled via the
660 =do-not-use-debuginfod debug option.
661
662 "N"
663 "=no-follow-links"
664 Disables the following of links to separate debug info files.
665
666 "D"
667 "=use-debuginfod"
668 Enables contacting debuginfod servers if there is a need to
669 follow debug links. This is the default behaviour.
670
671 "E"
672 "=do-not-use-debuginfod"
673 Disables contacting debuginfod servers when there is a need to
674 follow debug links.
675
676 "l"
677 "=rawline"
678 Displays the contents of the .debug_line section in a raw
679 format.
680
681 "L"
682 "=decodedline"
683 Displays the interpreted contents of the .debug_line section.
684
685 "m"
686 "=macro"
687 Displays the contents of the .debug_macro and/or .debug_macinfo
688 sections.
689
690 "o"
691 "=loc"
692 Displays the contents of the .debug_loc and/or .debug_loclists
693 sections.
694
695 "O"
696 "=str-offsets"
697 Displays the contents of the .debug_str_offsets section.
698
699 "p"
700 "=pubnames"
701 Displays the contents of the .debug_pubnames and/or
702 .debug_gnu_pubnames sections.
703
704 "r"
705 "=aranges"
706 Displays the contents of the .debug_aranges section.
707
708 "R"
709 "=Ranges"
710 Displays the contents of the .debug_ranges and/or
711 .debug_rnglists sections.
712
713 "s"
714 "=str"
715 Displays the contents of the .debug_str, .debug_line_str and/or
716 .debug_str_offsets sections.
717
718 "t"
719 "=pubtype"
720 Displays the contents of the .debug_pubtypes and/or
721 .debug_gnu_pubtypes sections.
722
723 "T"
724 "=trace_aranges"
725 Displays the contents of the .trace_aranges section.
726
727 "u"
728 "=trace_abbrev"
729 Displays the contents of the .trace_abbrev section.
730
731 "U"
732 "=trace_info"
733 Displays the contents of the .trace_info section.
734
735 Note: displaying the contents of .debug_static_funcs,
736 .debug_static_vars and debug_weaknames sections is not currently
737 supported.
738
739 --dwarf-depth=n
740 Limit the dump of the ".debug_info" section to n children. This is
741 only useful with --debug-dump=info. The default is to print all
742 DIEs; the special value 0 for n will also have this effect.
743
744 With a non-zero value for n, DIEs at or deeper than n levels will
745 not be printed. The range for n is zero-based.
746
747 --dwarf-start=n
748 Print only DIEs beginning with the DIE numbered n. This is only
749 useful with --debug-dump=info.
750
751 If specified, this option will suppress printing of any header
752 information and all DIEs before the DIE numbered n. Only siblings
753 and children of the specified DIE will be printed.
754
755 This can be used in conjunction with --dwarf-depth.
756
757 --dwarf-check
758 Enable additional checks for consistency of Dwarf information.
759
760 --ctf[=section]
761 Display the contents of the specified CTF section. CTF sections
762 themselves contain many subsections, all of which are displayed in
763 order.
764
765 By default, display the name of the section named .ctf, which is
766 the name emitted by ld.
767
768 --ctf-parent=member
769 If the CTF section contains ambiguously-defined types, it will
770 consist of an archive of many CTF dictionaries, all inheriting from
771 one dictionary containing unambiguous types. This member is by
772 default named .ctf, like the section containing it, but it is
773 possible to change this name using the
774 "ctf_link_set_memb_name_changer" function at link time. When
775 looking at CTF archives that have been created by a linker that
776 uses the name changer to rename the parent archive member,
777 --ctf-parent can be used to specify the name used for the parent.
778
779 --sframe[=section]
780 Display the contents of the specified SFrame section.
781
782 By default, display the name of the section named .sframe, which is
783 the name emitted by ld.
784
785 -G
786 --stabs
787 Display the full contents of any sections requested. Display the
788 contents of the .stab and .stab.index and .stab.excl sections from
789 an ELF file. This is only useful on systems (such as Solaris 2.0)
790 in which ".stab" debugging symbol-table entries are carried in an
791 ELF section. In most other file formats, debugging symbol-table
792 entries are interleaved with linkage symbols, and are visible in
793 the --syms output.
794
795 --start-address=address
796 Start displaying data at the specified address. This affects the
797 output of the -d, -r and -s options.
798
799 --stop-address=address
800 Stop displaying data at the specified address. This affects the
801 output of the -d, -r and -s options.
802
803 -t
804 --syms
805 Print the symbol table entries of the file. This is similar to the
806 information provided by the nm program, although the display format
807 is different. The format of the output depends upon the format of
808 the file being dumped, but there are two main types. One looks
809 like this:
810
811 [ 4](sec 3)(fl 0x00)(ty 0)(scl 3) (nx 1) 0x00000000 .bss
812 [ 6](sec 1)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 fred
813
814 where the number inside the square brackets is the number of the
815 entry in the symbol table, the sec number is the section number,
816 the fl value are the symbol's flag bits, the ty number is the
817 symbol's type, the scl number is the symbol's storage class and the
818 nx value is the number of auxiliary entries associated with the
819 symbol. The last two fields are the symbol's value and its name.
820
821 The other common output format, usually seen with ELF based files,
822 looks like this:
823
824 00000000 l d .bss 00000000 .bss
825 00000000 g .text 00000000 fred
826
827 Here the first number is the symbol's value (sometimes referred to
828 as its address). The next field is actually a set of characters
829 and spaces indicating the flag bits that are set on the symbol.
830 These characters are described below. Next is the section with
831 which the symbol is associated or *ABS* if the section is absolute
832 (ie not connected with any section), or *UND* if the section is
833 referenced in the file being dumped, but not defined there.
834
835 After the section name comes another field, a number, which for
836 common symbols is the alignment and for other symbol is the size.
837 Finally the symbol's name is displayed.
838
839 The flag characters are divided into 7 groups as follows:
840
841 "l"
842 "g"
843 "u"
844 "!" The symbol is a local (l), global (g), unique global (u),
845 neither global nor local (a space) or both global and local
846 (!). A symbol can be neither local or global for a variety of
847 reasons, e.g., because it is used for debugging, but it is
848 probably an indication of a bug if it is ever both local and
849 global. Unique global symbols are a GNU extension to the
850 standard set of ELF symbol bindings. For such a symbol the
851 dynamic linker will make sure that in the entire process there
852 is just one symbol with this name and type in use.
853
854 "w" The symbol is weak (w) or strong (a space).
855
856 "C" The symbol denotes a constructor (C) or an ordinary symbol (a
857 space).
858
859 "W" The symbol is a warning (W) or a normal symbol (a space). A
860 warning symbol's name is a message to be displayed if the
861 symbol following the warning symbol is ever referenced.
862
863 "I"
864 "i" The symbol is an indirect reference to another symbol (I), a
865 function to be evaluated during reloc processing (i) or a
866 normal symbol (a space).
867
868 "d"
869 "D" The symbol is a debugging symbol (d) or a dynamic symbol (D) or
870 a normal symbol (a space).
871
872 "F"
873 "f"
874 "O" The symbol is the name of a function (F) or a file (f) or an
875 object (O) or just a normal symbol (a space).
876
877 -T
878 --dynamic-syms
879 Print the dynamic symbol table entries of the file. This is only
880 meaningful for dynamic objects, such as certain types of shared
881 libraries. This is similar to the information provided by the nm
882 program when given the -D (--dynamic) option.
883
884 The output format is similar to that produced by the --syms option,
885 except that an extra field is inserted before the symbol's name,
886 giving the version information associated with the symbol. If the
887 version is the default version to be used when resolving
888 unversioned references to the symbol then it's displayed as is,
889 otherwise it's put into parentheses.
890
891 --special-syms
892 When displaying symbols include those which the target considers to
893 be special in some way and which would not normally be of interest
894 to the user.
895
896 -U [d|i|l|e|x|h]
897 --unicode=[default|invalid|locale|escape|hex|highlight]
898 Controls the display of UTF-8 encoded multibyte characters in
899 strings. The default (--unicode=default) is to give them no
900 special treatment. The --unicode=locale option displays the
901 sequence in the current locale, which may or may not support them.
902 The options --unicode=hex and --unicode=invalid display them as hex
903 byte sequences enclosed by either angle brackets or curly braces.
904
905 The --unicode=escape option displays them as escape sequences
906 (\uxxxx) and the --unicode=highlight option displays them as escape
907 sequences highlighted in red (if supported by the output device).
908 The colouring is intended to draw attention to the presence of
909 unicode sequences where they might not be expected.
910
911 -V
912 --version
913 Print the version number of objdump and exit.
914
915 -x
916 --all-headers
917 Display all available header information, including the symbol
918 table and relocation entries. Using -x is equivalent to specifying
919 all of -a -f -h -p -r -t.
920
921 -w
922 --wide
923 Format some lines for output devices that have more than 80
924 columns. Also do not truncate symbol names when they are
925 displayed.
926
927 -z
928 --disassemble-zeroes
929 Normally the disassembly output will skip blocks of zeroes. This
930 option directs the disassembler to disassemble those blocks, just
931 like any other data.
932
933 @file
934 Read command-line options from file. The options read are inserted
935 in place of the original @file option. If file does not exist, or
936 cannot be read, then the option will be treated literally, and not
937 removed.
938
939 Options in file are separated by whitespace. A whitespace
940 character may be included in an option by surrounding the entire
941 option in either single or double quotes. Any character (including
942 a backslash) may be included by prefixing the character to be
943 included with a backslash. The file may itself contain additional
944 @file options; any such options will be processed recursively.
945
947 nm(1), readelf(1), and the Info entries for binutils.
948
950 Copyright (c) 1991-2023 Free Software Foundation, Inc.
951
952 Permission is granted to copy, distribute and/or modify this document
953 under the terms of the GNU Free Documentation License, Version 1.3 or
954 any later version published by the Free Software Foundation; with no
955 Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
956 Texts. A copy of the license is included in the section entitled "GNU
957 Free Documentation License".
958
959
960
961binutils-2.41 2023-08-16 OBJDUMP(1)