This is an archive of the discontinued LLVM Phabricator instance.

Add MachO MH_FILESET support to objdump
ClosedPublic

Authored by pete on Aug 15 2022, 11:10 AM.

Details

Summary

On macOS, the kernel and kexts are linked in to a file known as a kernel collection. This is a new kind of mach-o, with a filetype of MH_FILESET.

Prior to this PR, llvm-objdump would say "not an object file" if you tried to read from an MH_FILESET. Now it understands enough to print the mach header.

Diff Detail

Event Timeline

pete created this revision.Aug 15 2022, 11:10 AM
Herald added a reviewer: MaskRay. · View Herald Transcript
Herald added a project: Restricted Project. · View Herald Transcript
pete requested review of this revision.Aug 15 2022, 11:10 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 15 2022, 11:10 AM
beanz accepted this revision.Aug 16 2022, 12:07 PM

Looks reasonable and straight forward to me.

This revision is now accepted and ready to land.Aug 16 2022, 12:07 PM
JDevlieghere accepted this revision.Aug 24 2022, 10:01 AM
JDevlieghere added a subscriber: JDevlieghere.

LGTM

JDevlieghere closed this revision.Aug 26 2022, 10:47 AM