LLVM-OBJDUMP(1)

๐Ÿฆ‹ llvm-objdump โ€” LLVM's object file dumper ๐Ÿฆ‹

okay bestie, welcome to the LLVM-OBJDUMP(1) manual page โ€” this is the one where we dump object files and look at what's inside, and honestly it's giving main-character energy for binary inspection ๐Ÿ’…โœจ


๐Ÿ’– NAME ๐Ÿ’–

llvm-objdump โ€” LLVM's object file dumper


โœจ SYNOPSIS โœจ

llvm-objdump [commands] [options] [filenames...]

๐ŸŒธ DESCRIPTION ๐ŸŒธ

The llvm-objdump utility prints the contents of object files and final linked images named on the command line. If no file name is specified, llvm-objdump will attempt to read from a.out. If - is used as a file name, llvm-objdump will process a file on its standard input stream. ๐Ÿซถ


๐Ÿ’… COMMANDS ๐Ÿ’…

At least one of the following commands are required, and some commands can be combined with other commands:

  • -a, --archive-headers โ€” display the information contained within an archive's headers. ๐ŸŽ€
  • -d, --disassemble โ€” disassemble all executable sections found in the input files. On some architectures (AArch64, PowerPC, x86), all known instructions are disassembled by default. On the others, --mcpu or --mattr is needed to enable some instruction sets. Disabled instructions are displayed as <unknown>. ๐Ÿ˜ญ
  • -D, --disassemble-all โ€” disassemble all sections found in the input files. ๐Ÿ”ฅ
  • --disassemble-symbols=<symbol1[,symbol2,...]> and --disassemble=symbol1 --disassemble=symbol2 ... โ€” disassemble only the specified symbols. Takes demangled symbol names when --demangle is specified, otherwise takes mangled symbol names. Implies --disassemble. ๐Ÿ‘‘
  • --dwarf=<value> โ€” dump the specified DWARF debug sections. The supported values are:
    • frames - .debug_frame ๐Ÿงš
  • -f, --file-headers โ€” display the contents of the overall file header. ๐ŸŒˆ
  • --fault-map-section โ€” display the content of the fault map section. โญ
  • -h, --headers, --section-headers โ€” display summaries of the headers for each section. ๐Ÿ’œ
  • --help โ€” display usage information and exit. Does not stack with other commands. ๐Ÿ’€
  • -p, --private-headers โ€” display format-specific file headers. ๐Ÿ“
  • -r, --reloc โ€” display the relocation entries in the file. ๐ŸŽ€
  • -R, --dynamic-reloc โ€” display the dynamic relocation entries in the file. โœจ
  • --raw-clang-ast โ€” dump the raw binary contents of the clang AST section. ๐Ÿฆ‹
  • -s, --full-contents โ€” display the contents of each section. ๐ŸŒธ
  • -t, --syms โ€” display the symbol table. ๐Ÿ’–
  • -T, --dynamic-syms โ€” display the contents of the dynamic symbol table. ๐Ÿ”ฅ
  • -u, --unwind-info โ€” display the unwind info of the input(s). This operation is only currently supported for COFF and Mach-O object files. ๐Ÿซถ
  • -v, --version โ€” display the version of the llvm-objdump executable. Does not stack with other commands. ๐Ÿ‘‘
  • -x, --all-headers โ€” display all available header information. Equivalent to specifying --archive-headers, --file-headers, --private-headers, --reloc, --section-headers, and --syms. ๐ŸŒŸ

โœจ OPTIONS โœจ

llvm-objdump ships with the whole buffet of options, bestie. Here's the full menu, nothing skipped, not one crumb:

  • --adjust-vma=<offset> โ€” bumps the address shown in disassembly (or in section header printing) up by offset. Basically "shift everything, I said so." ๐Ÿ’ซ
  • --arch-name=<string> โ€” tells it which target architecture to disassemble for. Wanna know what's on the list? Run --version, it'll tell you. ๐ŸŽฏ
  • --build-id=<string> โ€” finds the object using the build ID you give it, as a hex string. Whatever object it finds gets treated exactly like it was an input filename. Iconic lookup behavior fr.
  • -C, --demangle โ€” demangles symbol names in the output. No more mangled gobbledygook, we're getting readable names. ๐Ÿ’…
  • --debug-file-directory <path> โ€” hands over a path to a directory containing a .build-id subdirectory, which it'll search for debug info for stripped binaries. You can pass this more than once, and they get searched in the order you gave 'em.
  • --debug-indent=<width> โ€” how far to indent the source-level variable / inlined function display, measured from the start of the disassembly. Defaults to 52 characters. Yes, a very specific number, and yes it's the default. ๐ŸŽ€
  • --debug-inlined-funcs[=<format>] โ€” prints where inlined functions live, right there alongside the disassembly. format can be ascii, limits-only, or unicode, and it defaults to unicode if you just leave it blank. ๐Ÿฆ‹
  • --debug-vars[=<format>] โ€” prints the locations (registers or memory, no cap) of source-level variables alongside the disassembly. format is ascii or unicode, defaulting to unicode when omitted. ๐ŸŒธ
  • --debuginfod, --no-debuginfod โ€” toggles whether it tries debuginfod lookups for debug binaries. Heads up though: unless you say otherwise, debuginfod is only enabled if libcurl was compiled in (LLVM_ENABLE_CURL) and at least one server URL came from the environment variable DEBUGINFOD_URLS. Both conditions, no shortcuts. โญ
  • -j, --section=<section1[,section2,...]> โ€” only runs commands on the sections you name, and nothing else. For Mach-O, write it as segment,section to specify the section name. ๐Ÿซถ
  • -l, --line-numbers โ€” while disassembling, shows source line numbers. Also implies --disassemble, so it comes with a friend. ๐Ÿ˜Œ
  • -M, --disassembler-options=<opt1[,opt2,...]> โ€” passes target-specific disassembler options through. Here's what's available:
    • reg-names-std: ARM only, and it's the default. Prints using ARM's instruction set documentation, with r13/r14/r15 swapped out for sp/lr/pc.
    • reg-names-raw: ARM only. Uses r followed by the register number.
    • no-aliases: AArch64 and RISC-V only. Prints the raw instruction mnemonic instead of the pseudo instruction mnemonic.
    • numeric: RISC-V only. Prints raw register names instead of the ABI mnemonic โ€” like printing x1 instead of ra.
    • att: x86 only, and it's the default. Prints in the AT&T syntax.
    • intel: x86 only. Prints in the intel syntax.
  • --disassembler-color=<mode> โ€” turns disassembler color output on or off. Your choices:
    • off: disassembler color output off. simple as that.
    • on: disassembler color output on. slay.
    • terminal: on only if the terminal supports it โ€” and this is the default. ๐ŸŒˆ
  • --mcpu=<cpu-name> โ€” targets a specific CPU type for disassembly. Wanna see the list? --mcpu=help will dump the available CPUs for you. ๐Ÿ“
  • --mattr=<a1,+a2,-a3,...> โ€” enables/disables target-specific attributes. Same deal: --mattr=help shows you the available attributes.
  • -mllvm <arg> โ€” passes an argument straight along to LLVM's CommandLine library. Forwarded, untouched. ๐Ÿ’Œ
  • --no-leading-addr, --no-addresses โ€” while disassembling, don't print the leading addresses for instructions or inline relocations. Minimalist era.
  • --no-print-imm-hex โ€” don't use hex format for immediate values in the disassembly output. ngl sometimes you just want the other format.
  • --no-show-raw-insn โ€” while disassembling, don't print the raw bytes of each instruction. Just the instruction, thanks. โœจ
  • --offloading โ€” shows the content of the LLVM offloading sections plus HIP offload bundles. ๐Ÿ‘‘
  • --prefix=<prefix> โ€” when you're disassembling with the --source option, this prepends prefix to absolute paths.
  • --prefix-strip=<level> โ€” when disassembling with --source, strips out level initial directories from absolute paths. Warning bestie: this option does nothing without --prefix. Zero effect. ๐Ÿ’€
  • --source-dir <dir> โ€” when disassembling with --source, adds dir to the front of the source search path when it's looking up source files. For each source file, llvm-objdump tries the path from the debug info first, then each search directory with the full path appended, then each search directory with only the file name. You can hand it this option multiple times; every --source-dir adds one directory. Options on the command line are searched in first-to-last order. ๐ŸŽ€
  • --substitute-path <from> <to> โ€” when disassembling with --source, replaces from with to at the start of the directory part of source file paths while looking up sources. A rule only gets applied if from ends at a directory separator in the path. This can be specified multiple times; rules are evaluated in the order given and the first matching rule wins โ€” same as GDB set substitute-path. ๐ŸŒธ
  • --print-imm-hex โ€” uses hex format when printing immediate values in disassembly output. It's the default, so this is the "on purpose, explicitly" version. ๐Ÿงš
  • -S, --source โ€” while disassembling, shows source interleaved with the disassembly. Implies --disassemble. best of both worlds fr fr ๐Ÿซถ
  • --show-all-symbols โ€” shows every symbol during disassembly, even when multiple symbols are defined at the same location. No hiding, no picking favorites. ๐Ÿ’–
  • --show-lma โ€” displays the LMA column when dumping ELF section headers. Off by default โ€” unless any section has different VMA and LMAs, in which case it kicks in on its own.
  • --start-address=<address> โ€” depends what you're doing, so listen up:
    • When disassembling: only disassemble from the specified address onward.
    • When printing relocations: only print relocations patching offsets from at least address.
    • When printing symbols: only print symbols with a value of at least address.
  • --stop-address=<address> โ€” the other end of the range:
    • When disassembling: only disassemble up to, but not including, the specified address.
    • When printing relocations: only print relocations patching offsets up to address.
    • When printing symbols: only print symbols with a value up to address.
  • --symbolize-operands, --no-symbolize-operands โ€” this one's a whole moment, so buckle up:
    • While disassembling, it symbolizes a branch target operand so it prints a label instead of a real address.
    • When printing a PC-relative global symbol reference, it prints it as an offset from the leading symbol.
    • When a bb-address-map section is present (i.e., the object file is built with -fbasic-block-address-map), labels are retrieved from that section instead. And if a pgo-analysis-map is present alongside the bb-address-map, any available analyses get printed after the relevant block label. By default, any analysis with a special representation (i.e. BlockFrequency, BranchProbability, etc) gets printed as raw hex values.
    • Only supported for AArch64, BPF, PowerPC, RISC-V, and X86. It's enabled by default for BPF โ€” use --no-symbolize-operands to turn it off. ๐Ÿฆ‹

Example: a non-symbolized branch instruction with a local target and pc-relative memory access, like

cmp eax, dword ptr [rip + 4112]
jge 0x20117e <_start+0x25>

might become

<L0>:
  cmp eax, dword ptr <g>
  jge      <L0>
  • --pretty-pgo-analysis-map โ€” when you're using --symbolize-operands with bb-address-map and pgo-analysis-map, this prints analyses using the same format as their analysis passes would. An example of pretty format would be printing block frequencies relative to the entry block, the same as BFI. ๐Ÿ’…
Careful! This only works when --symbolize-operands is enabled. Otherwise it's just sitting there doing nothing.
  • --triple=<string> โ€” the target triple to disassemble for. Peep --version for the available targets. โญ
  • -w, --wide โ€” ignored, purely for compatibility with GNU objdump. It's there, it's vibing, it does nothing. ๐Ÿ™ˆ
  • --x86-asm-syntax=<style> โ€” deprecated, so heads up. When used with --disassemble, it chooses the style of code emitted from the X86 backend. Supported values:
    • att โ€” AT&T-style assembly
    • intel โ€” Intel-style assembly

The default disassembly style is att. ๐Ÿ”ฅ

  • -z, --disassemble-zeroes โ€” does not skip blocks of zeroes when disassembling. Every zero gets its moment.
  • @<FILE> โ€” reads command-line options and commands from the response file <FILE>. ๐ŸŽ€

๐Ÿ’… MACH-O ONLY OPTIONS AND COMMANDS ๐Ÿ’…

Okay bestie, this whole chunk is Apple-kid territory โ€” Mach-O is the file format macOS/iOS use, and these flags are the ones that only make sense there. Slay.

  • --arch=<architecture> โ€” tells it which architecture to disassemble. Not sure what you've got? Peek at --version for the list of available architectures, iykyk.
  • --archive-member-offsets โ€” prints the offset of each archive member for Mach-O archives. Heads up though: it requires --archive-headers. It won't vibe alone.
  • --bind โ€” shows binding info.
  • --data-in-code โ€” prints the data in code table.
  • --dis-symname=<name> โ€” disassembles just the instructions of the symbol you name. One symbol, main character energy, no entourage.
  • --chained-fixups โ€” prints chained fixup information.
  • --dyld-info โ€” prints the bind and rebase information dyld uses to resolve external references in a final linked binary.
  • --dylibs-used โ€” shows the shared libraries used for linked files.
  • --dsym=<string> โ€” uses a .dSYM file for debug info.
  • --dylib-id โ€” shows the shared library's ID for dylib files.
  • --exports-trie โ€” prints the exported symbols.
  • --function-starts [=<addrs|names|both>] โ€” prints the function starts table for Mach-O objects. You pick: addrs (the default) prints only function addresses, names prints only the function names (when they're available), and both prints the names right beside the addresses. Choose your fighter ๐Ÿซถ
  • -g โ€” prints line information from debug info, if it's there.
  • --full-leading-addr โ€” prints the full leading address when disassembling. No truncation, no shame.
  • --indirect-symbols โ€” shows the indirect symbol table.
  • --info-plist โ€” shows the info plist section as strings.
  • --lazy-bind โ€” shows lazy binding info.
  • --link-opt-hints โ€” shows the linker optimization hints.
  • -m, --macho โ€” use the Mach-O specific object file parser. Fair warning: commands and other options may behave differently when you use them with --macho. So like, don't come for me if the output looks different โ€” that's literally documented.
  • --no-leading-headers โ€” prints no leading headers at all.
  • --no-symbolic-operands โ€” doesn't print symbolic operands when disassembling.
  • --non-verbose โ€” displays info for Mach-O objects in non-verbose (numeric) form. Straight to the numbers, no small talk.
  • --objc-meta-data โ€” shows the Objective-C runtime meta data.
  • --private-header โ€” shows only the first format specific file header. That's it. That's the whole output. Minimalist queen.
  • --rebase โ€” shows rebasing information.
  • --rpaths โ€” shows runtime search paths for the binary.
  • --universal-headers โ€” shows universal headers.
  • --weak-bind โ€” shows weak binding information.

๐ŸŒˆ XCOFF ONLY OPTIONS AND COMMANDS ๐ŸŒˆ

Tiny section, but it ate โ€” XCOFF is the AIX crowd, and there are exactly two flags here:

  • --symbol-description โ€” adds a symbol description to the disassembly output.
  • --traceback-table โ€” decodes the traceback table in the disassembly output. And important: it implies --disassemble, so you don't gotta say it twice ๐Ÿ’œ

๐Ÿ› BUGS ๐Ÿ›

Found a bug? First of all, thank you for your service ๐Ÿซถ Please report it at <https://github.com/llvm/llvm-project/labels/tools:llvm-objdump/>. That's the spot, no cap.


๐Ÿ‘€ SEE ALSO ๐Ÿ‘€

Your other faves, all linked up:


๐Ÿ‘‘ Author ๐Ÿ‘‘

Maintained by the LLVM Team (<https://llvm.org/>). They're the ones keeping this whole thing alive, bless.

2003-2026, LLVM Project โ€” respect the legacy, periodt.


And that's the whole page, bestie!! ๐Ÿ’– This was page 23 of the manual, dated 2026-10-20, from the LLVM-OBJDUMP(1) source โ€” go forth and dump those objects, you absolute icon ๐Ÿฆ‹โœจ

๐Ÿ“ฆ where this page comes from
  • arch rolling: llvm 23.1.4-1 ยท Apache-2.0 WITH LLVM-exception
  • ๐Ÿ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms