Chandler Carruth | 2946cd7 | 2019-01-19 08:50:56 +0000 | [diff] [blame] | 1 | .\" Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
| 2 | .\" See https://llvm.org/LICENSE.txt for license information. |
| 3 | .\" SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
Ed Maste | 894385d | 2018-12-19 01:26:55 +0000 | [diff] [blame] | 4 | .\" |
| 5 | .Dd December 19, 2018 |
| 6 | .Dt LLVM-OBJDUMP 1 |
| 7 | .Os |
| 8 | .Sh NAME |
| 9 | .Nm llvm-objdump |
| 10 | .Nd LLVM object file dumper |
| 11 | .Sh SYNOPSIS |
| 12 | .Nm llvm-objdump |
| 13 | .Op Ar options |
| 14 | .Ar objfile ... |
| 15 | .Sh DESCRIPTION |
| 16 | .Nm |
| 17 | prints the contents of object files and final linked images named on the |
| 18 | command line. |
| 19 | If no file name is specified, |
| 20 | .Nm |
| 21 | will attempt to read from |
| 22 | .Pa a.out . |
| 23 | If |
| 24 | .Pa - |
| 25 | is used as a file name, |
| 26 | .Nm |
| 27 | will process a file on its standard input stream. |
| 28 | .Nm |
| 29 | accepts many of the same command line arguments as GNU objdump. |
| 30 | .Sh OPTIONS |
| 31 | .Ss General Options |
| 32 | .Bl -tag -width indent |
| 33 | .It Fl -aarch64-neon-syntax Ns = Ns Ar value |
| 34 | Choose style of NEON code to emit from AArch64 backend. |
| 35 | .Ar value |
| 36 | may be one of: |
| 37 | .Bl -tag -width indent |
| 38 | .It generic |
| 39 | Generic NEON assembly |
| 40 | .It apple |
| 41 | Apple-style NEON assembly |
| 42 | .El |
| 43 | .It Fl -arch Ns = Ns Ar value |
| 44 | Choose architecture(s) from a Mach-O file to dump |
| 45 | .It Fl -arch-name Ns = Ns ar arch |
| 46 | Target arch to disassemble for. |
| 47 | See |
| 48 | .Fl -version |
| 49 | for available targets. |
| 50 | .It Fl -bind |
| 51 | Display mach-o binding info. |
| 52 | .It Fl -color |
| 53 | Use colored syntax highlighting. |
| 54 | Default autodetect. |
| 55 | .It Fl -disassemble |
| 56 | Display assembler mnemonics for machine instructions. |
| 57 | .It Fl -disassemble-all |
| 58 | Display assembler mnemonics for the machine instruction in all sections. |
| 59 | .It Fl -dsym Ns = Ns Ar file |
| 60 | Use |
| 61 | .Ar file |
| 62 | for debug info. |
| 63 | .It Fl -dwarf Ns = Ns Ar sections |
| 64 | Dump of dwarf debug sections. |
| 65 | .Bl -tag -width indent |
| 66 | .It frames |
| 67 | .Dv .debug_frame |
| 68 | .El |
| 69 | .It Fl -exports-trie |
| 70 | Display mach-o exported symbols. |
| 71 | .It Fl -fault-map-section |
| 72 | Display contents of faultmap section. |
| 73 | .It Fl -filter-print-funcs Ns = Ns Ar functions |
| 74 | Only print IR for functions whose name match |
| 75 | .Ar functions |
| 76 | for all print-[before|after][-all] options. |
| 77 | .It Fl -full-leading-addr |
| 78 | Print full leading address. |
| 79 | .It Fl g |
| 80 | Print line information from debug info if available. |
| 81 | .It Fl h , -headers , -section-headers |
| 82 | Display summaries of the headers for each section. |
| 83 | .It Fl -help |
| 84 | Display available options. |
| 85 | Use |
| 86 | .Fl -help-hidden |
| 87 | for more. |
| 88 | .It Fl -lazy-bind |
| 89 | Display mach-o lazy binding info. |
| 90 | .It Fl -line-numbers |
| 91 | Display source line numbers with disassembly. |
| 92 | Implies disassemble object. |
| 93 | .It Fl -macho |
| 94 | Use MachO specific object file parser. |
| 95 | .It Fl -mattr Ns = Ns Ar attribute ... |
| 96 | Target specific attributes. |
| 97 | .It Fl -mcpu Ns = Ns Ar CPU |
| 98 | Target a specific cpu type. |
| 99 | Use |
| 100 | .Fl mcpu Ns = Ns help |
| 101 | for details. |
| 102 | .It Fl -no-leading-addr |
| 103 | Print no leading address. |
| 104 | .It Fl -no-leading-headers |
| 105 | Print no leading headers. |
| 106 | .It Fl -no-show-raw-insn |
| 107 | When disassembling instructions, do not print the instruction bytes. |
| 108 | .It Fl -print-imm-hex |
| 109 | Use hex format for immediate values. |
| 110 | .It Fl -private-header |
| 111 | Display only the first format specific file header. |
| 112 | .It Fl -private-headers |
| 113 | Display format specific file headers. |
| 114 | .It Fl r |
| 115 | Display the relocation entries in the file. |
| 116 | .It Fl -raw-clang-ast |
| 117 | Dump the raw binary contents of the clang AST section. |
| 118 | .It Fl -rebase |
| 119 | Display mach-o rebasing info. |
| 120 | .It Fl -reverse-iterate |
| 121 | Reverse iterate. |
| 122 | .It Fl s |
| 123 | Display the content of each section. |
| 124 | .It Fl -section Ns = Ns Ar section |
| 125 | Operate on the specified sections only. |
| 126 | With |
| 127 | .Fl -macho |
| 128 | dump segment,section. |
| 129 | .It Fl -source |
| 130 | Display source inline with disassembly. |
| 131 | Implies disassmble object. |
| 132 | .It Fl -start-address Ns = Ns Ar address |
| 133 | Disassemble beginning at |
| 134 | .Ar address . |
| 135 | .It Fl -stop-address Ns = Ns Ar address |
| 136 | Stop disassembly at |
| 137 | .Ar address . |
| 138 | .It Fl t |
| 139 | Display the symbol table. |
| 140 | .It Fl -triple Ns = Ns Ar triple |
| 141 | Target triple to disassemble for. |
| 142 | See |
| 143 | .Fl -version |
| 144 | for available targets. |
| 145 | .It Fl -unwind-info |
| 146 | Display unwind information. |
| 147 | .It Fl -version |
| 148 | Display the version of this program. |
| 149 | .It Fl -weak-bind |
| 150 | Display mach-o weak binding info. |
| 151 | .It Fl -x86-asm-syntax Ns = Ns Ar syntax |
| 152 | Choose style of code to emit from X86 backend. |
| 153 | .Bl -tag -width indent |
| 154 | .It att |
| 155 | Emit AT&T-style assembly. |
| 156 | .It intel |
| 157 | Emit Intel-style assembly. |
| 158 | .El |
| 159 | .El |
| 160 | .Ss Mach-O Options |
| 161 | There are a number of options specific to the Mach-O format. |
| 162 | These are used in combination with the |
| 163 | .Fl -macho |
| 164 | option. |
| 165 | .Bl -tag -width indent |
| 166 | .It Fl -archive-headers |
| 167 | Print archive headers for Mach-O archives. |
| 168 | .It Fl -archive-member-offsets |
| 169 | Print the offset to each archive member for Mach-O archives. |
| 170 | Requires |
| 171 | .Fl -macho |
| 172 | and |
| 173 | .Fl -archive-headers . |
| 174 | .It Fl -data-in-code |
| 175 | Print the data in code table for Mach-O objects. |
| 176 | .It Fl -dis-symname Ns = Ns Ar symbol |
| 177 | Disassemble just |
| 178 | .Ar symbol 's |
| 179 | instructions. |
| 180 | .It Fl -dylib-id |
| 181 | Print the shared library's id for the dylib Mach-O file. |
| 182 | .It Fl -dylibs-used |
| 183 | Print the shared libraries used for linked Mach-O files. |
| 184 | .It Fl -indirect-symbols |
| 185 | Print indirect symbol table for Mach-O objects. |
| 186 | .It Fl -info-plist |
| 187 | Print the info plist section as strings for Mach-O objects. |
| 188 | .It Fl -link-opt-hints |
| 189 | Print the linker optimization hints for Mach-O objects. |
| 190 | .It Fl -no-symbolic-operands |
| 191 | do not symbolic operands when disassembling. |
| 192 | .It Fl -non-verbose |
| 193 | Print the info for Mach-O objects in non-verbose or numeric form. |
| 194 | .It Fl -objc-meta-data |
| 195 | Print the Objective-C runtime meta data for Mach-O files. |
| 196 | .It Fl -universal-headers |
| 197 | Print Mach-O universal headers. |
| 198 | .El |