Merge branch 'vendor/GCC44'
[dragonfly.git] / contrib / binutils-2.22 / binutils / doc / objdump.1
CommitLineData
dfe305e9
JM
1.\" Automatically generated by Pod::Man 2.23 (Pod::Simple 3.14)
2.\"
3.\" Standard preamble:
4.\" ========================================================================
5.de Sp \" Vertical space (when we can't use .PP)
6.if t .sp .5v
7.if n .sp
8..
9.de Vb \" Begin verbatim text
10.ft CW
11.nf
12.ne \\$1
13..
14.de Ve \" End verbatim text
15.ft R
16.fi
17..
18.\" Set up some character translations and predefined strings. \*(-- will
19.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
20.\" double quote, and \*(R" will give a right double quote. \*(C+ will
21.\" give a nicer C++. Capital omega is used to do unbreakable dashes and
22.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,
23.\" nothing in troff, for use with C<>.
24.tr \(*W-
25.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
26.ie n \{\
27. ds -- \(*W-
28. ds PI pi
29. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
30. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
31. ds L" ""
32. ds R" ""
33. ds C` ""
34. ds C' ""
35'br\}
36.el\{\
37. ds -- \|\(em\|
38. ds PI \(*p
39. ds L" ``
40. ds R" ''
41'br\}
42.\"
43.\" Escape single quotes in literal strings from groff's Unicode transform.
44.ie \n(.g .ds Aq \(aq
45.el .ds Aq '
46.\"
47.\" If the F register is turned on, we'll generate index entries on stderr for
48.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
49.\" entries marked with X<> in POD. Of course, you'll have to process the
50.\" output yourself in some meaningful fashion.
51.ie \nF \{\
52. de IX
53. tm Index:\\$1\t\\n%\t"\\$2"
54..
55. nr % 0
56. rr F
57.\}
58.el \{\
59. de IX
60..
61.\}
62.\"
63.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
64.\" Fear. Run. Save yourself. No user-serviceable parts.
65. \" fudge factors for nroff and troff
66.if n \{\
67. ds #H 0
68. ds #V .8m
69. ds #F .3m
70. ds #[ \f1
71. ds #] \fP
72.\}
73.if t \{\
74. ds #H ((1u-(\\\\n(.fu%2u))*.13m)
75. ds #V .6m
76. ds #F 0
77. ds #[ \&
78. ds #] \&
79.\}
80. \" simple accents for nroff and troff
81.if n \{\
82. ds ' \&
83. ds ` \&
84. ds ^ \&
85. ds , \&
86. ds ~ ~
87. ds /
88.\}
89.if t \{\
90. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
91. ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
92. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
93. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
94. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
95. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
96.\}
97. \" troff and (daisy-wheel) nroff accents
98.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
99.ds 8 \h'\*(#H'\(*b\h'-\*(#H'
100.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
101.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
102.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
103.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
104.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
105.ds ae a\h'-(\w'a'u*4/10)'e
106.ds Ae A\h'-(\w'A'u*4/10)'E
107. \" corrections for vroff
108.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
109.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
110. \" for low resolution devices (crt and lpr)
111.if \n(.H>23 .if \n(.V>19 \
112\{\
113. ds : e
114. ds 8 ss
115. ds o a
116. ds d- d\h'-1'\(ga
117. ds D- D\h'-1'\(hy
118. ds th \o'bp'
119. ds Th \o'LP'
120. ds ae ae
121. ds Ae AE
122.\}
123.rm #[ #] #H #V #F C
124.\" ========================================================================
125.\"
126.IX Title "OBJDUMP 1"
127.TH OBJDUMP 1 "2011-11-21" "binutils-2.21.90" "GNU Development Tools"
128.\" For nroff, turn off justification. Always turn off hyphenation; it makes
129.\" way too many mistakes in technical documents.
130.if n .ad l
131.nh
132.SH "NAME"
133objdump \- display information from object files.
134.SH "SYNOPSIS"
135.IX Header "SYNOPSIS"
136objdump [\fB\-a\fR|\fB\-\-archive\-headers\fR]
137 [\fB\-b\fR \fIbfdname\fR|\fB\-\-target=\fR\fIbfdname\fR]
138 [\fB\-C\fR|\fB\-\-demangle\fR[=\fIstyle\fR] ]
139 [\fB\-d\fR|\fB\-\-disassemble\fR]
140 [\fB\-D\fR|\fB\-\-disassemble\-all\fR]
141 [\fB\-z\fR|\fB\-\-disassemble\-zeroes\fR]
142 [\fB\-EB\fR|\fB\-EL\fR|\fB\-\-endian=\fR{big | little }]
143 [\fB\-f\fR|\fB\-\-file\-headers\fR]
144 [\fB\-F\fR|\fB\-\-file\-offsets\fR]
145 [\fB\-\-file\-start\-context\fR]
146 [\fB\-g\fR|\fB\-\-debugging\fR]
147 [\fB\-e\fR|\fB\-\-debugging\-tags\fR]
148 [\fB\-h\fR|\fB\-\-section\-headers\fR|\fB\-\-headers\fR]
149 [\fB\-i\fR|\fB\-\-info\fR]
150 [\fB\-j\fR \fIsection\fR|\fB\-\-section=\fR\fIsection\fR]
151 [\fB\-l\fR|\fB\-\-line\-numbers\fR]
152 [\fB\-S\fR|\fB\-\-source\fR]
153 [\fB\-m\fR \fImachine\fR|\fB\-\-architecture=\fR\fImachine\fR]
154 [\fB\-M\fR \fIoptions\fR|\fB\-\-disassembler\-options=\fR\fIoptions\fR]
155 [\fB\-p\fR|\fB\-\-private\-headers\fR]
156 [\fB\-P\fR \fIoptions\fR|\fB\-\-private=\fR\fIoptions\fR]
157 [\fB\-r\fR|\fB\-\-reloc\fR]
158 [\fB\-R\fR|\fB\-\-dynamic\-reloc\fR]
159 [\fB\-s\fR|\fB\-\-full\-contents\fR]
160 [\fB\-W[lLiaprmfFsoRt]\fR|
161 \fB\-\-dwarf\fR[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames\-interp,=str,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index]]
162 [\fB\-G\fR|\fB\-\-stabs\fR]
163 [\fB\-t\fR|\fB\-\-syms\fR]
164 [\fB\-T\fR|\fB\-\-dynamic\-syms\fR]
165 [\fB\-x\fR|\fB\-\-all\-headers\fR]
166 [\fB\-w\fR|\fB\-\-wide\fR]
167 [\fB\-\-start\-address=\fR\fIaddress\fR]
168 [\fB\-\-stop\-address=\fR\fIaddress\fR]
169 [\fB\-\-prefix\-addresses\fR]
170 [\fB\-\-[no\-]show\-raw\-insn\fR]
171 [\fB\-\-adjust\-vma=\fR\fIoffset\fR]
172 [\fB\-\-special\-syms\fR]
173 [\fB\-\-prefix=\fR\fIprefix\fR]
174 [\fB\-\-prefix\-strip=\fR\fIlevel\fR]
175 [\fB\-\-insn\-width=\fR\fIwidth\fR]
176 [\fB\-V\fR|\fB\-\-version\fR]
177 [\fB\-H\fR|\fB\-\-help\fR]
178 \fIobjfile\fR...
179.SH "DESCRIPTION"
180.IX Header "DESCRIPTION"
181\&\fBobjdump\fR displays information about one or more object files.
182The options control what particular information to display. This
183information is mostly useful to programmers who are working on the
184compilation tools, as opposed to programmers who just want their
185program to compile and work.
186.PP
187\&\fIobjfile\fR... are the object files to be examined. When you
188specify archives, \fBobjdump\fR shows information on each of the member
189object files.
190.SH "OPTIONS"
191.IX Header "OPTIONS"
192The long and short forms of options, shown here as alternatives, are
193equivalent. At least one option from the list
194\&\fB\-a,\-d,\-D,\-e,\-f,\-g,\-G,\-h,\-H,\-p,\-P,\-r,\-R,\-s,\-S,\-t,\-T,\-V,\-x\fR must be given.
195.IP "\fB\-a\fR" 4
196.IX Item "-a"
197.PD 0
198.IP "\fB\-\-archive\-header\fR" 4
199.IX Item "--archive-header"
200.PD
201If any of the \fIobjfile\fR files are archives, display the archive
202header information (in a format similar to \fBls \-l\fR). Besides the
203information you could list with \fBar tv\fR, \fBobjdump \-a\fR shows
204the object file format of each archive member.
205.IP "\fB\-\-adjust\-vma=\fR\fIoffset\fR" 4
206.IX Item "--adjust-vma=offset"
207When dumping information, first add \fIoffset\fR to all the section
208addresses. This is useful if the section addresses do not correspond to
209the symbol table, which can happen when putting sections at particular
210addresses when using a format which can not represent section addresses,
211such as a.out.
212.IP "\fB\-b\fR \fIbfdname\fR" 4
213.IX Item "-b bfdname"
214.PD 0
215.IP "\fB\-\-target=\fR\fIbfdname\fR" 4
216.IX Item "--target=bfdname"
217.PD
218Specify that the object-code format for the object files is
219\&\fIbfdname\fR. This option may not be necessary; \fIobjdump\fR can
220automatically recognize many formats.
221.Sp
222For example,
223.Sp
224.Vb 1
225\& objdump \-b oasys \-m vax \-h fu.o
226.Ve
227.Sp
228displays summary information from the section headers (\fB\-h\fR) of
229\&\fIfu.o\fR, which is explicitly identified (\fB\-m\fR) as a \s-1VAX\s0 object
230file in the format produced by Oasys compilers. You can list the
231formats available with the \fB\-i\fR option.
232.IP "\fB\-C\fR" 4
233.IX Item "-C"
234.PD 0
235.IP "\fB\-\-demangle[=\fR\fIstyle\fR\fB]\fR" 4
236.IX Item "--demangle[=style]"
237.PD
238Decode (\fIdemangle\fR) low-level symbol names into user-level names.
239Besides removing any initial underscore prepended by the system, this
240makes \*(C+ function names readable. Different compilers have different
241mangling styles. The optional demangling style argument can be used to
242choose an appropriate demangling style for your compiler.
243.IP "\fB\-g\fR" 4
244.IX Item "-g"
245.PD 0
246.IP "\fB\-\-debugging\fR" 4
247.IX Item "--debugging"
248.PD
249Display debugging information. This attempts to parse \s-1STABS\s0 and \s-1IEEE\s0
250debugging format information stored in the file and print it out using
251a C like syntax. If neither of these formats are found this option
252falls back on the \fB\-W\fR option to print any \s-1DWARF\s0 information in
253the file.
254.IP "\fB\-e\fR" 4
255.IX Item "-e"
256.PD 0
257.IP "\fB\-\-debugging\-tags\fR" 4
258.IX Item "--debugging-tags"
259.PD
260Like \fB\-g\fR, but the information is generated in a format compatible
261with ctags tool.
262.IP "\fB\-d\fR" 4
263.IX Item "-d"
264.PD 0
265.IP "\fB\-\-disassemble\fR" 4
266.IX Item "--disassemble"
267.PD
268Display the assembler mnemonics for the machine instructions from
269\&\fIobjfile\fR. This option only disassembles those sections which are
270expected to contain instructions.
271.IP "\fB\-D\fR" 4
272.IX Item "-D"
273.PD 0
274.IP "\fB\-\-disassemble\-all\fR" 4
275.IX Item "--disassemble-all"
276.PD
277Like \fB\-d\fR, but disassemble the contents of all sections, not just
278those expected to contain instructions.
279.Sp
280If the target is an \s-1ARM\s0 architecture this switch also has the effect
281of forcing the disassembler to decode pieces of data found in code
282sections as if they were instructions.
283.IP "\fB\-\-prefix\-addresses\fR" 4
284.IX Item "--prefix-addresses"
285When disassembling, print the complete address on each line. This is
286the older disassembly format.
287.IP "\fB\-EB\fR" 4
288.IX Item "-EB"
289.PD 0
290.IP "\fB\-EL\fR" 4
291.IX Item "-EL"
292.IP "\fB\-\-endian={big|little}\fR" 4
293.IX Item "--endian={big|little}"
294.PD
295Specify the endianness of the object files. This only affects
296disassembly. This can be useful when disassembling a file format which
297does not describe endianness information, such as S\-records.
298.IP "\fB\-f\fR" 4
299.IX Item "-f"
300.PD 0
301.IP "\fB\-\-file\-headers\fR" 4
302.IX Item "--file-headers"
303.PD
304Display summary information from the overall header of
305each of the \fIobjfile\fR files.
306.IP "\fB\-F\fR" 4
307.IX Item "-F"
308.PD 0
309.IP "\fB\-\-file\-offsets\fR" 4
310.IX Item "--file-offsets"
311.PD
312When disassembling sections, whenever a symbol is displayed, also
313display the file offset of the region of data that is about to be
314dumped. If zeroes are being skipped, then when disassembly resumes,
315tell the user how many zeroes were skipped and the file offset of the
316location from where the disassembly resumes. When dumping sections,
317display the file offset of the location from where the dump starts.
318.IP "\fB\-\-file\-start\-context\fR" 4
319.IX Item "--file-start-context"
320Specify that when displaying interlisted source code/disassembly
321(assumes \fB\-S\fR) from a file that has not yet been displayed, extend the
322context to the start of the file.
323.IP "\fB\-h\fR" 4
324.IX Item "-h"
325.PD 0
326.IP "\fB\-\-section\-headers\fR" 4
327.IX Item "--section-headers"
328.IP "\fB\-\-headers\fR" 4
329.IX Item "--headers"
330.PD
331Display summary information from the section headers of the
332object file.
333.Sp
334File segments may be relocated to nonstandard addresses, for example by
335using the \fB\-Ttext\fR, \fB\-Tdata\fR, or \fB\-Tbss\fR options to
336\&\fBld\fR. However, some object file formats, such as a.out, do not
337store the starting address of the file segments. In those situations,
338although \fBld\fR relocates the sections correctly, using \fBobjdump
339\&\-h\fR to list the file section headers cannot show the correct addresses.
340Instead, it shows the usual addresses, which are implicit for the
341target.
342.IP "\fB\-H\fR" 4
343.IX Item "-H"
344.PD 0
345.IP "\fB\-\-help\fR" 4
346.IX Item "--help"
347.PD
348Print a summary of the options to \fBobjdump\fR and exit.
349.IP "\fB\-i\fR" 4
350.IX Item "-i"
351.PD 0
352.IP "\fB\-\-info\fR" 4
353.IX Item "--info"
354.PD
355Display a list showing all architectures and object formats available
356for specification with \fB\-b\fR or \fB\-m\fR.
357.IP "\fB\-j\fR \fIname\fR" 4
358.IX Item "-j name"
359.PD 0
360.IP "\fB\-\-section=\fR\fIname\fR" 4
361.IX Item "--section=name"
362.PD
363Display information only for section \fIname\fR.
364.IP "\fB\-l\fR" 4
365.IX Item "-l"
366.PD 0
367.IP "\fB\-\-line\-numbers\fR" 4
368.IX Item "--line-numbers"
369.PD
370Label the display (using debugging information) with the filename and
371source line numbers corresponding to the object code or relocs shown.
372Only useful with \fB\-d\fR, \fB\-D\fR, or \fB\-r\fR.
373.IP "\fB\-m\fR \fImachine\fR" 4
374.IX Item "-m machine"
375.PD 0
376.IP "\fB\-\-architecture=\fR\fImachine\fR" 4
377.IX Item "--architecture=machine"
378.PD
379Specify the architecture to use when disassembling object files. This
380can be useful when disassembling object files which do not describe
381architecture information, such as S\-records. You can list the available
382architectures with the \fB\-i\fR option.
383.Sp
384If the target is an \s-1ARM\s0 architecture then this switch has an
385additional effect. It restricts the disassembly to only those
386instructions supported by the architecture specified by \fImachine\fR.
387If it is necessary to use this switch because the input file does not
388contain any architecture information, but it is also desired to
389disassemble all the instructions use \fB\-marm\fR.
390.IP "\fB\-M\fR \fIoptions\fR" 4
391.IX Item "-M options"
392.PD 0
393.IP "\fB\-\-disassembler\-options=\fR\fIoptions\fR" 4
394.IX Item "--disassembler-options=options"
395.PD
396Pass target specific information to the disassembler. Only supported on
397some targets. If it is necessary to specify more than one
398disassembler option then multiple \fB\-M\fR options can be used or
399can be placed together into a comma separated list.
400.Sp
401If the target is an \s-1ARM\s0 architecture then this switch can be used to
402select which register name set is used during disassembler. Specifying
403\&\fB\-M reg-names-std\fR (the default) will select the register names as
404used in \s-1ARM\s0's instruction set documentation, but with register 13 called
405\&'sp', register 14 called 'lr' and register 15 called 'pc'. Specifying
406\&\fB\-M reg-names-apcs\fR will select the name set used by the \s-1ARM\s0
407Procedure Call Standard, whilst specifying \fB\-M reg-names-raw\fR will
408just use \fBr\fR followed by the register number.
409.Sp
410There are also two variants on the \s-1APCS\s0 register naming scheme enabled
411by \fB\-M reg-names-atpcs\fR and \fB\-M reg-names-special-atpcs\fR which
412use the ARM/Thumb Procedure Call Standard naming conventions. (Either
413with the normal register names or the special register names).
414.Sp
415This option can also be used for \s-1ARM\s0 architectures to force the
416disassembler to interpret all instructions as Thumb instructions by
417using the switch \fB\-\-disassembler\-options=force\-thumb\fR. This can be
418useful when attempting to disassemble thumb code produced by other
419compilers.
420.Sp
421For the x86, some of the options duplicate functions of the \fB\-m\fR
422switch, but allow finer grained control. Multiple selections from the
423following may be specified as a comma separated string.
424\&\fBx86\-64\fR, \fBi386\fR and \fBi8086\fR select disassembly for
425the given architecture. \fBintel\fR and \fBatt\fR select between
426intel syntax mode and \s-1AT&T\s0 syntax mode.
427\&\fBintel-mnemonic\fR and \fBatt-mnemonic\fR select between
428intel mnemonic mode and \s-1AT&T\s0 mnemonic mode. \fBintel-mnemonic\fR
429implies \fBintel\fR and \fBatt-mnemonic\fR implies \fBatt\fR.
430\&\fBaddr64\fR, \fBaddr32\fR,
431\&\fBaddr16\fR, \fBdata32\fR and \fBdata16\fR specify the default
432address size and operand size. These four options will be overridden if
433\&\fBx86\-64\fR, \fBi386\fR or \fBi8086\fR appear later in the
434option string. Lastly, \fBsuffix\fR, when in \s-1AT&T\s0 mode,
435instructs the disassembler to print a mnemonic suffix even when the
436suffix could be inferred by the operands.
437.Sp
438For PowerPC, \fBbooke\fR controls the disassembly of BookE
439instructions. \fB32\fR and \fB64\fR select PowerPC and
440PowerPC64 disassembly, respectively. \fBe300\fR selects
441disassembly for the e300 family. \fB440\fR selects disassembly for
442the PowerPC 440. \fBppcps\fR selects disassembly for the paired
443single instructions of the \s-1PPC750CL\s0.
444.Sp
445For \s-1MIPS\s0, this option controls the printing of instruction mnemonic
446names and register names in disassembled instructions. Multiple
447selections from the following may be specified as a comma separated
448string, and invalid options are ignored:
449.RS 4
450.ie n .IP """no\-aliases""" 4
451.el .IP "\f(CWno\-aliases\fR" 4
452.IX Item "no-aliases"
453Print the 'raw' instruction mnemonic instead of some pseudo
454instruction mnemonic. I.e., print 'daddu' or 'or' instead of 'move',
455\&'sll' instead of 'nop', etc.
456.ie n .IP """gpr\-names=\f(CIABI\f(CW""" 4
457.el .IP "\f(CWgpr\-names=\f(CIABI\f(CW\fR" 4
458.IX Item "gpr-names=ABI"
459Print \s-1GPR\s0 (general-purpose register) names as appropriate
460for the specified \s-1ABI\s0. By default, \s-1GPR\s0 names are selected according to
461the \s-1ABI\s0 of the binary being disassembled.
462.ie n .IP """fpr\-names=\f(CIABI\f(CW""" 4
463.el .IP "\f(CWfpr\-names=\f(CIABI\f(CW\fR" 4
464.IX Item "fpr-names=ABI"
465Print \s-1FPR\s0 (floating-point register) names as
466appropriate for the specified \s-1ABI\s0. By default, \s-1FPR\s0 numbers are printed
467rather than names.
468.ie n .IP """cp0\-names=\f(CIARCH\f(CW""" 4
469.el .IP "\f(CWcp0\-names=\f(CIARCH\f(CW\fR" 4
470.IX Item "cp0-names=ARCH"
471Print \s-1CP0\s0 (system control coprocessor; coprocessor 0) register names
472as appropriate for the \s-1CPU\s0 or architecture specified by
473\&\fI\s-1ARCH\s0\fR. By default, \s-1CP0\s0 register names are selected according to
474the architecture and \s-1CPU\s0 of the binary being disassembled.
475.ie n .IP """hwr\-names=\f(CIARCH\f(CW""" 4
476.el .IP "\f(CWhwr\-names=\f(CIARCH\f(CW\fR" 4
477.IX Item "hwr-names=ARCH"
478Print \s-1HWR\s0 (hardware register, used by the \f(CW\*(C`rdhwr\*(C'\fR instruction) names
479as appropriate for the \s-1CPU\s0 or architecture specified by
480\&\fI\s-1ARCH\s0\fR. By default, \s-1HWR\s0 names are selected according to
481the architecture and \s-1CPU\s0 of the binary being disassembled.
482.ie n .IP """reg\-names=\f(CIABI\f(CW""" 4
483.el .IP "\f(CWreg\-names=\f(CIABI\f(CW\fR" 4
484.IX Item "reg-names=ABI"
485Print \s-1GPR\s0 and \s-1FPR\s0 names as appropriate for the selected \s-1ABI\s0.
486.ie n .IP """reg\-names=\f(CIARCH\f(CW""" 4
487.el .IP "\f(CWreg\-names=\f(CIARCH\f(CW\fR" 4
488.IX Item "reg-names=ARCH"
489Print CPU-specific register names (\s-1CP0\s0 register and \s-1HWR\s0 names)
490as appropriate for the selected \s-1CPU\s0 or architecture.
491.RE
492.RS 4
493.Sp
494For any of the options listed above, \fI\s-1ABI\s0\fR or
495\&\fI\s-1ARCH\s0\fR may be specified as \fBnumeric\fR to have numbers printed
496rather than names, for the selected types of registers.
497You can list the available values of \fI\s-1ABI\s0\fR and \fI\s-1ARCH\s0\fR using
498the \fB\-\-help\fR option.
499.Sp
500For \s-1VAX\s0, you can specify function entry addresses with \fB\-M
501entry:0xf00ba\fR. You can use this multiple times to properly
502disassemble \s-1VAX\s0 binary files that don't contain symbol tables (like
503\&\s-1ROM\s0 dumps). In these cases, the function entry mask would otherwise
504be decoded as \s-1VAX\s0 instructions, which would probably lead the rest
505of the function being wrongly disassembled.
506.RE
507.IP "\fB\-p\fR" 4
508.IX Item "-p"
509.PD 0
510.IP "\fB\-\-private\-headers\fR" 4
511.IX Item "--private-headers"
512.PD
513Print information that is specific to the object file format. The exact
514information printed depends upon the object file format. For some
515object file formats, no additional information is printed.
516.IP "\fB\-P\fR \fIoptions\fR" 4
517.IX Item "-P options"
518.PD 0
519.IP "\fB\-\-private=\fR\fIoptions\fR" 4
520.IX Item "--private=options"
521.PD
522Print information that is specific to the object file format. The
523argument \fIoptions\fR is a comma separated list that depends on the
524format (the lists of options is displayed with the help).
525.Sp
526For \s-1XCOFF\s0, the available options are: \fBheader\fR, \fBaout\fR,
527\&\fBsections\fR, \fBsyms\fR, \fBrelocs\fR, \fBlineno\fR,
528\&\fBloader\fR, \fBexcept\fR, \fBtypchk\fR, \fBtraceback\fR
529and \fBtoc\fR.
530.IP "\fB\-r\fR" 4
531.IX Item "-r"
532.PD 0
533.IP "\fB\-\-reloc\fR" 4
534.IX Item "--reloc"
535.PD
536Print the relocation entries of the file. If used with \fB\-d\fR or
537\&\fB\-D\fR, the relocations are printed interspersed with the
538disassembly.
539.IP "\fB\-R\fR" 4
540.IX Item "-R"
541.PD 0
542.IP "\fB\-\-dynamic\-reloc\fR" 4
543.IX Item "--dynamic-reloc"
544.PD
545Print the dynamic relocation entries of the file. This is only
546meaningful for dynamic objects, such as certain types of shared
547libraries. As for \fB\-r\fR, if used with \fB\-d\fR or
548\&\fB\-D\fR, the relocations are printed interspersed with the
549disassembly.
550.IP "\fB\-s\fR" 4
551.IX Item "-s"
552.PD 0
553.IP "\fB\-\-full\-contents\fR" 4
554.IX Item "--full-contents"
555.PD
556Display the full contents of any sections requested. By default all
557non-empty sections are displayed.
558.IP "\fB\-S\fR" 4
559.IX Item "-S"
560.PD 0
561.IP "\fB\-\-source\fR" 4
562.IX Item "--source"
563.PD
564Display source code intermixed with disassembly, if possible. Implies
565\&\fB\-d\fR.
566.IP "\fB\-\-prefix=\fR\fIprefix\fR" 4
567.IX Item "--prefix=prefix"
568Specify \fIprefix\fR to add to the absolute paths when used with
569\&\fB\-S\fR.
570.IP "\fB\-\-prefix\-strip=\fR\fIlevel\fR" 4
571.IX Item "--prefix-strip=level"
572Indicate how many initial directory names to strip off the hardwired
573absolute paths. It has no effect without \fB\-\-prefix=\fR\fIprefix\fR.
574.IP "\fB\-\-show\-raw\-insn\fR" 4
575.IX Item "--show-raw-insn"
576When disassembling instructions, print the instruction in hex as well as
577in symbolic form. This is the default except when
578\&\fB\-\-prefix\-addresses\fR is used.
579.IP "\fB\-\-no\-show\-raw\-insn\fR" 4
580.IX Item "--no-show-raw-insn"
581When disassembling instructions, do not print the instruction bytes.
582This is the default when \fB\-\-prefix\-addresses\fR is used.
583.IP "\fB\-\-insn\-width=\fR\fIwidth\fR" 4
584.IX Item "--insn-width=width"
585Display \fIwidth\fR bytes on a single line when disassembling
586instructions.
587.IP "\fB\-W[lLiaprmfFsoRt]\fR" 4
588.IX Item "-W[lLiaprmfFsoRt]"
589.PD 0
590.IP "\fB\-\-dwarf[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames\-interp,=str,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index]\fR" 4
591.IX Item "--dwarf[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames-interp,=str,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index]"
592.PD
593Displays the contents of the debug sections in the file, if any are
594present. If one of the optional letters or words follows the switch
595then only data found in those specific sections will be dumped.
596.Sp
597Note that there is no single letter option to display the content of
598trace sections or .gdb_index.
599.Sp
600Note: the output from the \fB=info\fR option can also be affected
601by the options \fB\-\-dwarf\-depth\fR and \fB\-\-dwarf\-start\fR.
602.IP "\fB\-\-dwarf\-depth=\fR\fIn\fR" 4
603.IX Item "--dwarf-depth=n"
604Limit the dump of the \f(CW\*(C`.debug_info\*(C'\fR section to \fIn\fR children.
605This is only useful with \fB\-\-dwarf=info\fR. The default is
606to print all DIEs; the special value 0 for \fIn\fR will also have this
607effect.
608.Sp
609With a non-zero value for \fIn\fR, DIEs at or deeper than \fIn\fR
610levels will not be printed. The range for \fIn\fR is zero-based.
611.IP "\fB\-\-dwarf\-start=\fR\fIn\fR" 4
612.IX Item "--dwarf-start=n"
613Print only DIEs beginning with the \s-1DIE\s0 numbered \fIn\fR. This is only
614useful with \fB\-\-dwarf=info\fR.
615.Sp
616If specified, this option will suppress printing of any header
617information and all DIEs before the \s-1DIE\s0 numbered \fIn\fR. Only
618siblings and children of the specified \s-1DIE\s0 will be printed.
619.Sp
620This can be used in conjunction with \fB\-\-dwarf\-depth\fR.
621.IP "\fB\-G\fR" 4
622.IX Item "-G"
623.PD 0
624.IP "\fB\-\-stabs\fR" 4
625.IX Item "--stabs"
626.PD
627Display the full contents of any sections requested. Display the
628contents of the .stab and .stab.index and .stab.excl sections from an
629\&\s-1ELF\s0 file. This is only useful on systems (such as Solaris 2.0) in which
630\&\f(CW\*(C`.stab\*(C'\fR debugging symbol-table entries are carried in an \s-1ELF\s0
631section. In most other file formats, debugging symbol-table entries are
632interleaved with linkage symbols, and are visible in the \fB\-\-syms\fR
633output.
634.IP "\fB\-\-start\-address=\fR\fIaddress\fR" 4
635.IX Item "--start-address=address"
636Start displaying data at the specified address. This affects the output
637of the \fB\-d\fR, \fB\-r\fR and \fB\-s\fR options.
638.IP "\fB\-\-stop\-address=\fR\fIaddress\fR" 4
639.IX Item "--stop-address=address"
640Stop displaying data at the specified address. This affects the output
641of the \fB\-d\fR, \fB\-r\fR and \fB\-s\fR options.
642.IP "\fB\-t\fR" 4
643.IX Item "-t"
644.PD 0
645.IP "\fB\-\-syms\fR" 4
646.IX Item "--syms"
647.PD
648Print the symbol table entries of the file.
649This is similar to the information provided by the \fBnm\fR program,
650although the display format is different. The format of the output
651depends upon the format of the file being dumped, but there are two main
652types. One looks like this:
653.Sp
654.Vb 2
655\& [ 4](sec 3)(fl 0x00)(ty 0)(scl 3) (nx 1) 0x00000000 .bss
656\& [ 6](sec 1)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 fred
657.Ve
658.Sp
659where the number inside the square brackets is the number of the entry
660in the symbol table, the \fIsec\fR number is the section number, the
661\&\fIfl\fR value are the symbol's flag bits, the \fIty\fR number is the
662symbol's type, the \fIscl\fR number is the symbol's storage class and
663the \fInx\fR value is the number of auxilary entries associated with
664the symbol. The last two fields are the symbol's value and its name.
665.Sp
666The other common output format, usually seen with \s-1ELF\s0 based files,
667looks like this:
668.Sp
669.Vb 2
670\& 00000000 l d .bss 00000000 .bss
671\& 00000000 g .text 00000000 fred
672.Ve
673.Sp
674Here the first number is the symbol's value (sometimes refered to as
675its address). The next field is actually a set of characters and
676spaces indicating the flag bits that are set on the symbol. These
677characters are described below. Next is the section with which the
678symbol is associated or \fI*ABS*\fR if the section is absolute (ie
679not connected with any section), or \fI*UND*\fR if the section is
680referenced in the file being dumped, but not defined there.
681.Sp
682After the section name comes another field, a number, which for common
683symbols is the alignment and for other symbol is the size. Finally
684the symbol's name is displayed.
685.Sp
686The flag characters are divided into 7 groups as follows:
687.RS 4
688.ie n .IP """l""" 4
689.el .IP "\f(CWl\fR" 4
690.IX Item "l"
691.PD 0
692.ie n .IP """g""" 4
693.el .IP "\f(CWg\fR" 4
694.IX Item "g"
695.ie n .IP """u""" 4
696.el .IP "\f(CWu\fR" 4
697.IX Item "u"
698.ie n .IP """!""" 4
699.el .IP "\f(CW!\fR" 4
700.IX Item "!"
701.PD
702The symbol is a local (l), global (g), unique global (u), neither
703global nor local (a space) or both global and local (!). A
704symbol can be neither local or global for a variety of reasons, e.g.,
705because it is used for debugging, but it is probably an indication of
706a bug if it is ever both local and global. Unique global symbols are
707a \s-1GNU\s0 extension to the standard set of \s-1ELF\s0 symbol bindings. For such
708a symbol the dynamic linker will make sure that in the entire process
709there is just one symbol with this name and type in use.
710.ie n .IP """w""" 4
711.el .IP "\f(CWw\fR" 4
712.IX Item "w"
713The symbol is weak (w) or strong (a space).
714.ie n .IP """C""" 4
715.el .IP "\f(CWC\fR" 4
716.IX Item "C"
717The symbol denotes a constructor (C) or an ordinary symbol (a space).
718.ie n .IP """W""" 4
719.el .IP "\f(CWW\fR" 4
720.IX Item "W"
721The symbol is a warning (W) or a normal symbol (a space). A warning
722symbol's name is a message to be displayed if the symbol following the
723warning symbol is ever referenced.
724.ie n .IP """I""" 4
725.el .IP "\f(CWI\fR" 4
726.IX Item "I"
727.PD 0
728.ie n .IP """i""" 4
729.el .IP "\f(CWi\fR" 4
730.IX Item "i"
731.PD
732The symbol is an indirect reference to another symbol (I), a function
733to be evaluated during reloc processing (i) or a normal symbol (a
734space).
735.ie n .IP """d""" 4
736.el .IP "\f(CWd\fR" 4
737.IX Item "d"
738.PD 0
739.ie n .IP """D""" 4
740.el .IP "\f(CWD\fR" 4
741.IX Item "D"
742.PD
743The symbol is a debugging symbol (d) or a dynamic symbol (D) or a
744normal symbol (a space).
745.ie n .IP """F""" 4
746.el .IP "\f(CWF\fR" 4
747.IX Item "F"
748.PD 0
749.ie n .IP """f""" 4
750.el .IP "\f(CWf\fR" 4
751.IX Item "f"
752.ie n .IP """O""" 4
753.el .IP "\f(CWO\fR" 4
754.IX Item "O"
755.PD
756The symbol is the name of a function (F) or a file (f) or an object
757(O) or just a normal symbol (a space).
758.RE
759.RS 4
760.RE
761.IP "\fB\-T\fR" 4
762.IX Item "-T"
763.PD 0
764.IP "\fB\-\-dynamic\-syms\fR" 4
765.IX Item "--dynamic-syms"
766.PD
767Print the dynamic symbol table entries of the file. This is only
768meaningful for dynamic objects, such as certain types of shared
769libraries. This is similar to the information provided by the \fBnm\fR
770program when given the \fB\-D\fR (\fB\-\-dynamic\fR) option.
771.IP "\fB\-\-special\-syms\fR" 4
772.IX Item "--special-syms"
773When displaying symbols include those which the target considers to be
774special in some way and which would not normally be of interest to the
775user.
776.IP "\fB\-V\fR" 4
777.IX Item "-V"
778.PD 0
779.IP "\fB\-\-version\fR" 4
780.IX Item "--version"
781.PD
782Print the version number of \fBobjdump\fR and exit.
783.IP "\fB\-x\fR" 4
784.IX Item "-x"
785.PD 0
786.IP "\fB\-\-all\-headers\fR" 4
787.IX Item "--all-headers"
788.PD
789Display all available header information, including the symbol table and
790relocation entries. Using \fB\-x\fR is equivalent to specifying all of
791\&\fB\-a \-f \-h \-p \-r \-t\fR.
792.IP "\fB\-w\fR" 4
793.IX Item "-w"
794.PD 0
795.IP "\fB\-\-wide\fR" 4
796.IX Item "--wide"
797.PD
798Format some lines for output devices that have more than 80 columns.
799Also do not truncate symbol names when they are displayed.
800.IP "\fB\-z\fR" 4
801.IX Item "-z"
802.PD 0
803.IP "\fB\-\-disassemble\-zeroes\fR" 4
804.IX Item "--disassemble-zeroes"
805.PD
806Normally the disassembly output will skip blocks of zeroes. This
807option directs the disassembler to disassemble those blocks, just like
808any other data.
809.IP "\fB@\fR\fIfile\fR" 4
810.IX Item "@file"
811Read command-line options from \fIfile\fR. The options read are
812inserted in place of the original @\fIfile\fR option. If \fIfile\fR
813does not exist, or cannot be read, then the option will be treated
814literally, and not removed.
815.Sp
816Options in \fIfile\fR are separated by whitespace. A whitespace
817character may be included in an option by surrounding the entire
818option in either single or double quotes. Any character (including a
819backslash) may be included by prefixing the character to be included
820with a backslash. The \fIfile\fR may itself contain additional
821@\fIfile\fR options; any such options will be processed recursively.
822.SH "SEE ALSO"
823.IX Header "SEE ALSO"
824\&\fInm\fR\|(1), \fIreadelf\fR\|(1), and the Info entries for \fIbinutils\fR.
825.SH "COPYRIGHT"
826.IX Header "COPYRIGHT"
827Copyright (c) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
8282000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
829Free Software Foundation, Inc.
830.PP
831Permission is granted to copy, distribute and/or modify this document
832under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.3
833or any later version published by the Free Software Foundation;
834with no Invariant Sections, with no Front-Cover Texts, and with no
835Back-Cover Texts. A copy of the license is included in the
836section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".