Introduction The Executable and Linking Format (ELF) defines a linking interface for executables and shared objects in two parts. The first part is the generic System V ABI (http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/normativerefs.html#NORMATIVEREFSSECT). The second part is a processor-specific supplement. This document, the OpenPOWER ABI for Linux Supplement for the Power Architecture 64-bit ELF V2 ABI, is the OpenPOWER-compliant processor-specific supplement for use with ELF V2 on 64-bit IBM Power Architecture® systems. This is not a complete System V ABI supplement because it does not define any library interfaces. This document establishes both big-endian and little-endian application binary interfaces (see ). OpenPOWER-compliant processors in the 64-bit Power Architecture can execute in either big-endian or little-endian mode. Executables and executable-generated data (in general) that subscribe to either byte ordering are not portable to a system running in the other mode. Note: This ABI specification does not address little-endian byte ordering before Power ISA 2.03. The OpenPOWER ELF V2 ABI is not the same as either the Power Architecture 32-bit ABI supplement or the 64-bit IBM PowerPC® ELF ABI (ELF V1). The Power Architecture 64-bit OpenPOWER ELF V2 ABI supplement is intended to use the same structural layout now followed in practice by other processor-specific ABIs.
Reference Documentation The archetypal ELF ABI is described by the System V ABI. Supersessions and addenda that are specific to OpenPOWER ELF V2 Power Architecture (64-bit) processors are described in this document. The following documents are complementary to this document and equally binding: IBM Power Instruction Set Architecture, Versions 2.07, 3.0, and 3.1, IBM, 2013-2020. https://openpowerfoundation.org/technical/resource-catalog/ POWER Vector Intrinsics Programming Reference, Version 1.0.0, OpenPOWER Foundation, 2020. https://openpowerfoundation.org/technical/resource-catalog/ DWARF Debugging Information Format, Version 4, DWARF Debugging Information Format Workgroup, 2010. http://dwarfstd.org/Dwarf4Std.php ISO/IEC 9899:2011: Programming languages—C. http://www.iso.org/iso/home/store/catalogue_tc/catalogue_detail.htm?csnumber=57853 Itanium C++ ABI: Exception Handling. Rev 1.22, CodeSourcery, 2001. http://www.codesourcery.com/public/cxx-abi/abi-eh.html ISO/IEC TR 24732:2009 – Programming languages, their environments and system software interfaces – Extension for the programming language C to support decimal floating-point arithmetic, ISO/IEC, January 05, 2009. Available from ISO. http://www.iso.org/iso/home/store/catalogue_tc/catalogue_tc_browse.htm?commid=45202 ELF Handling for Thread-Local Storage, Version 0.20, Ulrich Drepper, Red Hat Inc., December 21, 2005. http://people.redhat.com/drepper/tls.pdf ELFv2 ABI Compliance TH/TS Specification 1.00, OpenPOWER Foundation, June 27, 2017. http://cdn.openpowerfoundation.org/wp-content/uploads/resources/openpower-elfv2abi-thts/openpower-elfv2abi-thts-20170627.pdf The following documents are of interest for their historical information but are not normative in any way. 64-bit PowerPC ELF Application Binary Interface Supplement 1.9. http://refspecs.linuxfoundation.org/ELF/ppc64/PPC-elf64abi.html IBM PowerOpen™ ABI Application Binary Interface Big-Endian 32-Bit Hardware Implementation. ftp://www.sourceware.org/pub/binutils/ppc-docs/ppc-poweropen/ Power Architecture 32-bit ABI Supplement 1.0 Embedded/Linux/Unified. https://www.power.org/documentation/power-architecture-32-bit-abi-supplement-1-0-embeddedlinuxunified/ ALTIVEC PIM: AltiVec™ Technology Programming Interface Manual, Freescale Semiconductor, 1999. http://www.freescale.com/files/32bit/doc/ref_manual/ALTIVECPIM.pdf ELF Assembly User’s Guide, Fourth edition, IBM, 2000. https://www-03.ibm.com/technologyconnect/tgcm/TGCMFileServlet.wss/assem_um.pdf?id=109917A251EFD64C872569D900656D07&linkid=1h3000&c_t=md515o6ntgh671shz9ioar20oyfp1grs
Changes from Revision 1.4 Errata recorded at https://openpowerfoundation.org/?resource_lib=openpower-elfv2-errata-elfv2-abi-version-1-4 have been incorporated into this document. PowerISA version 3.1 introduces PC-relative instructions for accessing code and data. Thus compilers and assembly programmers that target version 3.1 or later can, if desired, avoid usage of a TOC pointer for such accesses. The ABI has been updated to describe the implications of this new capability. For specifics, see , , , , , , and . Appendix A, "Predefined Functions for Vector Programming," and most of Chapter 6, "Vector Programming Interfaces," have been removed from this document. This material is now incorporated into the POWER Vector Intrinsics Programming Reference. See for a link to this document.
Conformance to this Specification Compilers, assemblers, linkers, system libraries, and other toolchain components that implement this specification should fully implement all relevant aspects described in chapters 2 through 6 of this specification, except for material that is specifically denoted as optional, as an optimization, or as an example. Some aspects will only be relevant to a compiler, while others will only be relevant to a linker, and so forth.