LLVM-OTOOL(1)

πŸ’… LLVM-OTOOL (like, the Mach-O dumping tool bestie)

okay so real quick before we dive in β€” this whole page is from the LLVM manual suite, section 1. that's the vibe. ✨

🌸 NAME

llvm-otool β€” a Mach-O dumping tool. literally what it says on the tin, no cap.

πŸŽ€ SYNOPSIS

llvm-otool [option...] [file...]

πŸ¦‹ DESCRIPTION

so llvm-otool is a tool for dumping Mach-O files. that's the whole assignment πŸ’…

and here's the slay part: it attempts to be command-line-compatible and output-compatible with macOS's otool. like, it's giving "i can sit at the same table as the original." 🫢

✨ OPTIONS ✨

okay buckle up, there's a lot, but every single one is here so don't skip:

  • -arch <value> β€” picks which slice of a universal Mach-O file you wanna look at. universal files are like a little friend group of architectures, and this is you choosing who to talk to πŸŽ€
  • -chained_fixups β€” prints chained fixup information. fancy internal stuff, very demure ✨
  • -C β€” prints linker optimization hints.
  • -dyld_info β€” prints bind and rebase information. dyld said "let me explain myself" 😭
  • -D β€” prints the shared library id.
  • -d β€” prints the data section.
  • -f β€” prints universal headers.
  • -G β€” prints the data-in-code table.
  • --help-hidden β€” prints help for the hidden flags. yeah there's a secret menu πŸ’€
  • --help β€” prints help. the normal menu, no secrets.
  • -h β€” prints the mach header.
  • -I β€” prints the indirect symbol table.
  • -j β€” prints opcode bytes.
  • -L β€” prints the used shared libraries.
  • -l β€” prints load commands. lowercase L, uppercase vibes πŸ‘‘
  • -mcpu=<value> β€” selects the cpu for disassembly. yes, you tell it which brain to use 🧠
  • -o β€” prints the Objective-C segment.
  • -P β€” prints the __TEXT,__info_plist section as strings. plist info but make it readable πŸ“
  • -p <function name> β€” starts disassembly at <function name>. like dropping a pin πŸ“
  • -r β€” prints relocation entries.
  • -s <segname> <sectname> β€” prints the contents of a section. you give it a segment name and a section name, both, don't be shy 🫢
  • -t β€” prints the text section.
  • --version β€” prints the version. hi what's your sign, it's --version πŸ’…
  • -V β€” symbolizes disassembled operands (and yes, this implies -v β€” it comes with a plus-one, iconic πŸ’–)
  • -v β€” verbose output / disassemble when printing text sections. it's giving "tell me everything" 😭
  • -X β€” omits leading addresses or headers. minimalism era πŸŽ€
  • -x β€” prints all text sections. all of them. the whole timeline.
  • @<FILE> β€” reads command-line options and commands from the response file <FILE>. it's like a little note you pass to your bestie instead of shouting every flag out loud πŸ“

πŸ’€ EXIT STATUS

llvm-otool exits with a non-zero exit code if there is an error. otherwise, it exits with code 0. so like β€” 0 means we're good, anything else means something went sideways. periodt. πŸ¦‹

πŸ™ˆ BUGS

gotta report a bug? be my guest, go here:

https://github.com/llvm/llvm-project/labels/tools:llvm-objdump/

(the original page breaks that URL across a line with a hyphen β€” it's one URL, promise 🫢)

🌈 SEE ALSO

go read those too, they're also iconic in their own way ✨

πŸ‘‘ AUTHOR

maintained by the LLVM Team at https://llvm.org/. they're the main characters here fr fr πŸ’œ

2003-2023, LLVM Project β€” that's the whole copyright notice, keep it sacred πŸŽ€


so yeah, that's the page πŸ’– it's LLVM version 17, dated 2023-12-01, and it's LLVM-OTOOL(1) β€” go dump some Mach-O files bestie, you're gonna slay πŸ¦‹βœ¨

πŸ“¦ where this page comes from