Document Revision History

This table describes the changes to OS X ABI Mach-O File Format Reference.

2009-02-04Made minor changes.
2007-04-26Added details about Mach-O files targeted for the OS X x86-64 environment.

Added relocation details to “Relocation Data Structures.”


Updated the cputype field of the mach_header_64 structure.


Updated the r_type bit of the relocation_info structure.


Added DWARF debugging-format information to the introduction.

2006-10-03Added information about the uuid_command load command.

Added uuid_command and updated load_command.

2006-09-05Added information about IA-32-specific structures and the file type for dSYM files.
2006-03-08Corrected the mach_header_64 description.

Replaced cross-references to “Indirect Addressing” throughout to cross-references to “Position-Independent Code” in Mach-O Programming Topics.


Removed CPU_SUBTYPE_I386_ALL from the description for the cpusubtype field of mach_header_64.

2005-11-09 Changed title from "Mach-O File Format Reference."

Added the phrase “Mac app binary interface (ABI) to the introduction to raise this document’s visibility in searches.

2005-08-11 Clarified terminology for binaries that contain object files for more than one architecture.
2005-04-29 Added information on 64-bit support in the Mach-O file format. Removed the "Overview of the Runtime Architecture" and "Runtime Conventions for PowerPC" chapters. That content was placed in "OS X Runtime Overview" and "PowerPC Runtime Programming Guide," respectively.

Changed title to Mach-O File Format Reference.


Updated symbol declarations to match headers.


Added information on parameter passing, section names, dynamic linking of libraries, dead-code stripping flags, and GPR11. Removed dynamic linking functions reference. Minor technical and editorial corrections throughout.


Added information on MH_SUBSECTIONS_VIA_SYMBOLS flag to mach_header struct.


Added information on the S_ATTR_STRIP_STATIC_SYMS, S_ATTR_LIVE_SUPPORT, and S_ATTR_NO_DEAD_STRIP flags to section struct.


Added explanation of PPC_RELOC_LO14_SECTDIFF to scattered_relocation_info.


Added clarification on when callers put parameters in the stack, in addition to placing them in registers. See .


Added details on parameter passing for single-member structures. See 32-bit PowerPC Function Calling Conventions.


Refined description of GPR11. See 32-bit PowerPC Function Calling Conventions.


Specified correct sizes for composite parameters that are preceded by padding to make them 4 bytes in size. See 32-bit PowerPC Function Calling Conventions.


Added note to “Introduction” indicating that compilers can define additional section names that are not shown in Table 1.


Corrected example of a private external symbol. See Mach-O Programming Topics.


Corrected ranges for unsigned int, unsigned long, and unsigned long long, and vector unsigned int. See 32-bit PowerPC Function Calling Conventions.


Corrected framework-building example. See Mach-O Programming Topics.


Removed “Mach-O Dynamic Linking Functions Reference” chapter and placed its content in Mach-O Runtime Reference.


Added description of new API for OS X version 10.3.


Incorporated developer feedback. Updated code-generation examples.


Fixed bugs 2462895, 2749339, 2909989, 2910422, 2921574.


More developer feedback. Document weak definitions and weak references (new for 10.2). Substantially update the glossary. Other tweaks and additional material. Clarify common vs. coalesced symbol definitions.


ABI: Rewrote position-independent and indirect code section, incorporating correct examples and separating PIC and indirect code generation. Add C99 _Bool data type. See “32-bit PowerPC Function Calling Conventions”.


Fixed bugs 2909989, 2910422, and 2921574.


This was a preliminary draft distributed with the WWDC 2002 developer tools.


Incorporated many corrections from developer review. More to come.


By popular demand, added some common usage scenarios to map runtime features to the options in the standard OS X tools that implement those features. To satisfy a related popular demand, this information is collected in a separate chapter, which allows users of third-party tool sets to ignore it. This chapter is currently unfinished, and the overview chapter is yet to be modified to cross-reference it.


Updated umbrella framework description to better match reality.


Added long double and long long return value information. Removed last vestiges of CFM. Rewrote data alignment section, incorporating the correct rules (inherited from IBM’s xlc compiler) for power alignment mode, and adding new natural alignment mode.


This was a preliminary draft distributed with the April 2002 Developer Tools CD.