Changeset View
Changeset View
Standalone View
Standalone View
usr.bin/clang/llvm-objdump/llvm-objdump.1
.\" This file is distributed under the University of Illinois Open Source | .\" This file is distributed under the University of Illinois Open Source | ||||
.\" License. See LICENSE.TXT for details. | .\" License. See LICENSE.TXT for details. | ||||
.\" | .\" | ||||
.Dd November 23, 2018 | .Dd November 23, 2018 | ||||
.Dt LLVM-OBJDUMP 1 | .Dt LLVM-OBJDUMP 1 | ||||
.Os | .Os | ||||
.Sh NAME | .Sh NAME | ||||
.Nm llvm-objdump | .Nm llvm-objdump | ||||
.Nd LLVM object file dumper | .Nd LLVM object file dumper | ||||
.Sh SYNOPSIS | .Sh SYNOPSIS | ||||
.Nm llvm-objdump | .Nm llvm-objdump | ||||
yuripv: Just IMO: listing all the long options in the synopsis section makes it unreadable (see diff(1)… | |||||
Done Inline ActionsThere are a mix of long and short options, some short ones not documented. I had this discussion with Ingo Schwarze about the ld.lld.1 man page as well; he does not like eliminating the options in the synopsis, but also does not like long options at all. I think you're right that the giant collection of long options is not that helpful, although note that GNU objdump does list all of its options in the synopsis. emaste: There are a mix of long and short options, some short ones not documented.
I had this… | |||||
.Op Fl -aarch64-neon-syntax Ns = Ns Ar value | .Op Fl -aarch64-neon-syntax Ns = Ns Ar value | ||||
.Op Fl -arch Ns = Ns Ar value | .Op Fl -arch Ns = Ns Ar value | ||||
.Op Fl -archive-headers | .Op Fl -archive-headers | ||||
.Op Fl -archive-member-offsets | .Op Fl -archive-member-offsets | ||||
.Op Fl -bind | .Op Fl -bind | ||||
.Op Fl -color | .Op Fl -color | ||||
.Op Fl -data-in-code | .Op Fl -data-in-code | ||||
.Op Fl -dis-symname Ns = Ns Ar symbol | .Op Fl -dis-symname Ns = Ns Ar symbol | ||||
▲ Show 20 Lines • Show All 63 Lines • ▼ Show 20 Lines | |||||
If | If | ||||
.Pa - | .Pa - | ||||
is used as a file name, | is used as a file name, | ||||
.Nm | .Nm | ||||
will process a file on its standard input stream. | will process a file on its standard input stream. | ||||
.Nm | .Nm | ||||
accepts many of the same command line arguments as GNU objdump. | accepts many of the same command line arguments as GNU objdump. | ||||
.Sh OPTIONS | .Sh OPTIONS | ||||
.Ss General Options | |||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It Fl -aarch64-neon-syntax Ns = Ns Ar value | .It Fl -aarch64-neon-syntax Ns = Ns Ar value | ||||
Choose style of NEON code to emit from AArch64 backend. | Choose style of NEON code to emit from AArch64 backend. | ||||
.Ar value | .Ar value | ||||
may be one of: | may be one of: | ||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It generic | .It generic | ||||
Generic NEON assembly | Generic NEON assembly | ||||
.It apple | .It apple | ||||
Apple-style NEON assembly | Apple-style NEON assembly | ||||
.El | .El | ||||
.It Fl -arch Ns = Ns Ar value | .It Fl -arch Ns = Ns Ar value | ||||
Choose architecture(s) from a Mach-O file to dump | Choose architecture(s) from a Mach-O file to dump | ||||
.It Fl -arch-name Ns = Ns ar arch | .It Fl -arch-name Ns = Ns ar arch | ||||
Target arch to disassemble for. | Target arch to disassemble for. | ||||
See | See | ||||
.Fl -version | .Fl -version | ||||
for available targets. | for available targets. | ||||
.It Fl -archive-headers | |||||
Print archive headers for Mach-O archives. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -archive-member-offsets | |||||
Print the offset to each archive member for Mach-O archives. | |||||
Requires | |||||
.Fl -macho | |||||
and | |||||
.Fl -archive-headers. | |||||
.It Fl -bind | .It Fl -bind | ||||
Display mach-o binding info. | Display mach-o binding info. | ||||
.It Fl -color | .It Fl -color | ||||
Use colored syntax highlighting. | Use colored syntax highlighting. | ||||
Default autodetect. | Default autodetect. | ||||
.It Fl -data-in-code | |||||
Print the data in code table for Mach-O objects. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -dis-symname Ns = Ns Ar symbol | |||||
Disassemble just | |||||
.Ar symbol 's | |||||
instructions. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -disassemble | .It Fl -disassemble | ||||
Display assembler mnemonics for machine instructions. | Display assembler mnemonics for machine instructions. | ||||
.It Fl -disassemble-all | .It Fl -disassemble-all | ||||
Display assembler mnemonics for the machine instruction in all sections. | Display assembler mnemonics for the machine instruction in all sections. | ||||
.It Fl -dsym Ns = Ns Ar file | .It Fl -dsym Ns = Ns Ar file | ||||
Use | Use | ||||
.Ar file | .Ar file | ||||
for debug info. | for debug info. | ||||
.It Fl -dwarf Ns = Ns Ar sections | .It Fl -dwarf Ns = Ns Ar sections | ||||
Dump of dwarf debug sections. | Dump of dwarf debug sections. | ||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It frames | .It frames | ||||
.Dv .debug_frame | .Dv .debug_frame | ||||
.El | .El | ||||
.It Fl -dylib-id | |||||
Print the shared library's id for the dylib Mach-O file. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -dylibs-used | |||||
Print the shared libraries used for linked Mach-O files. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -exports-trie | .It Fl -exports-trie | ||||
Display mach-o exported symbols. | Display mach-o exported symbols. | ||||
.It Fl -fault-map-section | .It Fl -fault-map-section | ||||
Display contents of faultmap section. | Display contents of faultmap section. | ||||
.It Fl -filter-print-funcs Ns = Ns Ar functions | .It Fl -filter-print-funcs Ns = Ns Ar functions | ||||
Only print IR for functions whose name match | Only print IR for functions whose name match | ||||
.Ar functions | .Ar functions | ||||
for all print-[before|after][-all] options. | for all print-[before|after][-all] options. | ||||
.It Fl -full-leading-addr | .It Fl -full-leading-addr | ||||
Print full leading address. | Print full leading address. | ||||
.It Fl g | .It Fl g | ||||
Print line information from debug info if available. | Print line information from debug info if available. | ||||
.It Fl h , -headers , -section-headers | .It Fl h , -headers , -section-headers | ||||
Display summaries of the headers for each section. | Display summaries of the headers for each section. | ||||
.It Fl -help | .It Fl -help | ||||
Display available options. | Display available options. | ||||
Use | Use | ||||
.Fl -help-hidden | .Fl -help-hidden | ||||
for more. | for more. | ||||
.It Fl -indirect-symbols | |||||
Print indirect symbol table for Mach-O objects. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -info-plist | |||||
Print the info plist section as strings for Mach-O objects. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -lazy-bind | .It Fl -lazy-bind | ||||
Display mach-o lazy binding info. | Display mach-o lazy binding info. | ||||
.It Fl -line-numbers | .It Fl -line-numbers | ||||
Display source line numbers with disassembly. Implies disassemble object. | Display source line numbers with disassembly. | ||||
.It Fl -link-opt-hints | Implies disassemble object. | ||||
Not Done Inline ActionsLine break after the sentence stop. bcr: Line break after the sentence stop. | |||||
Print the linker optimization hints for Mach-O objects. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -macho | .It Fl -macho | ||||
Use MachO specific object file parser. | Use MachO specific object file parser. | ||||
.It Fl -mattr Ns = Ns Ar attribute ... | .It Fl -mattr Ns = Ns Ar attribute ... | ||||
Target specific attributes. | Target specific attributes. | ||||
.It Fl -mcpu Ns = Ns Ar CPU | .It Fl -mcpu Ns = Ns Ar CPU | ||||
Target a specific cpu type. | Target a specific cpu type. | ||||
Use | Use | ||||
.Fl mcpu Ns = Ns help | .Fl mcpu Ns = Ns help | ||||
for details. | for details. | ||||
.It Fl -no-leading-addr | .It Fl -no-leading-addr | ||||
Print no leading address. | Print no leading address. | ||||
.It Fl -no-leading-headers | .It Fl -no-leading-headers | ||||
Print no leading headers. | Print no leading headers. | ||||
.It Fl -no-show-raw-insn | .It Fl -no-show-raw-insn | ||||
When disassembling instructions, do not print the instruction bytes. | When disassembling instructions, do not print the instruction bytes. | ||||
.It Fl -no-symbolic-operands | |||||
do not symbolic operands when disassembling. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -non-verbose | |||||
Print the info for Mach-O objects in non-verbose or numeric form. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -objc-meta-data | |||||
Print the Objective-C runtime meta data for Mach-O files. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -print-after-all | .It Fl -print-after-all | ||||
Print IR after each pass. | Print IR after each pass. | ||||
.It Fl -print-before-all | .It Fl -print-before-all | ||||
Print IR before each pass. | Print IR before each pass. | ||||
.It Fl -print-imm-hex | .It Fl -print-imm-hex | ||||
Use hex format for immediate values. | Use hex format for immediate values. | ||||
.It Fl -private-header | .It Fl -private-header | ||||
Display only the first format specific file header. | Display only the first format specific file header. | ||||
Show All 34 Lines | |||||
Display the symbol table. | Display the symbol table. | ||||
.It Fl -time-passes | .It Fl -time-passes | ||||
Time each pass, printing elapsed time for each on exit | Time each pass, printing elapsed time for each on exit | ||||
.It Fl -triple Ns = Ns Ar triple | .It Fl -triple Ns = Ns Ar triple | ||||
Target triple to disassemble for. | Target triple to disassemble for. | ||||
See | See | ||||
.Fl -version | .Fl -version | ||||
for available targets. | for available targets. | ||||
.It Fl -universal-headers | |||||
Print Mach-O universal headers. | |||||
Requires | |||||
.Fl -macho . | |||||
.It Fl -unwind-info | .It Fl -unwind-info | ||||
Display unwind information. | Display unwind information. | ||||
.It Fl -verify-debug-info | .It Fl -verify-debug-info | ||||
Verify debug info. | Verify debug info. | ||||
.It Fl -verify-dom-info | .It Fl -verify-dom-info | ||||
Verify dominator info (time consuming). | Verify dominator info (time consuming). | ||||
.It Fl -version | .It Fl -version | ||||
Display the version of this program. | Display the version of this program. | ||||
.It Fl -weak-bind | .It Fl -weak-bind | ||||
Display mach-o weak binding info. | Display mach-o weak binding info. | ||||
.It Fl -x86-asm-syntax Ns = Ns Ar syntax | .It Fl -x86-asm-syntax Ns = Ns Ar syntax | ||||
Choose style of code to emit from X86 backend. | Choose style of code to emit from X86 backend. | ||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It att | .It att | ||||
Emit AT&T-style assembly. | Emit AT&T-style assembly. | ||||
.It intel | .It intel | ||||
Emit Intel-style assembly. | Emit Intel-style assembly. | ||||
.El | .El | ||||
.El | |||||
.Ss Mach-O Options | |||||
There are a number of options specific to the Mach-O format. | |||||
These are used in combination with the | |||||
.Fl -macho | |||||
option. | |||||
.Bl -tag -width indent | |||||
.It Fl -archive-headers | |||||
Print archive headers for Mach-O archives. | |||||
.It Fl -archive-member-offsets | |||||
Print the offset to each archive member for Mach-O archives. | |||||
Requires | |||||
.Fl -macho | |||||
and | |||||
.Fl -archive-headers . | |||||
.It Fl -data-in-code | |||||
Print the data in code table for Mach-O objects. | |||||
.It Fl -dis-symname Ns = Ns Ar symbol | |||||
Disassemble just | |||||
.Ar symbol 's | |||||
instructions. | |||||
.It Fl -dylib-id | |||||
Print the shared library's id for the dylib Mach-O file. | |||||
.It Fl -dylibs-used | |||||
Print the shared libraries used for linked Mach-O files. | |||||
.It Fl -indirect-symbols | |||||
Print indirect symbol table for Mach-O objects. | |||||
.It Fl -info-plist | |||||
Print the info plist section as strings for Mach-O objects. | |||||
.It Fl -link-opt-hints | |||||
Print the linker optimization hints for Mach-O objects. | |||||
.It Fl -no-symbolic-operands | |||||
do not symbolic operands when disassembling. | |||||
.It Fl -non-verbose | |||||
Print the info for Mach-O objects in non-verbose or numeric form. | |||||
.It Fl -objc-meta-data | |||||
Print the Objective-C runtime meta data for Mach-O files. | |||||
.It Fl -universal-headers | |||||
Print Mach-O universal headers. | |||||
.El | .El |
Just IMO: listing all the long options in the synopsis section makes it unreadable (see diff(1), for example); if there are no short ones, just say llvm-objdump [OPTIONS] objfile ... like some of gnu utilities do (yeah, I know...), e.g., gnugrep(1).