Concept

Application binary interface

Summary
In computer software, an application binary interface (ABI) is an interface between two binary program modules. Often, one of these modules is a library or operating system facility, and the other is a program that is being run by a user. An ABI defines how data structures or computational routines are accessed in machine code, which is a low-level, hardware-dependent format. In contrast, an application programming interface (API) defines this access in source code, which is a relatively high-level, hardware-independent, often human-readable format. A common aspect of an ABI is the calling convention, which determines how data is provided as input to, or read as output from, computational routines. Examples of this are the x86 calling conventions. Adhering to an ABI (which may or may not be officially standardized) is usually the job of a compiler, operating system, or library author. However, an application programmer may have to deal with an ABI directly when writing a program in a mix of programming languages, or even compiling a program written in the same language with different compilers. An ABI is as important as the underlying hardware architecture. The program will fail equally if it violates any constraints of these two. Details covered by an ABI include the following: Processor instruction set, with details like register file structure, stack organization, memory access types, etc. Sizes, layouts, and alignments of basic data types that the processor can directly access Calling convention, which controls how the arguments of functions are passed, and return values retrieved; for example, it controls the following: Whether all parameters are passed on the stack, or some are passed in registers Which registers are used for which function parameters Whether the first function parameter passed on the stack is pushed first or last Whether the caller or callee is responsible for cleaning up the stack after the function call How an application should make system calls to the operating system, and if the ABI specifies direct system calls rather than procedure calls to system call stubs, the system call numbers In the case of a complete operating system ABI, the binary format of s, program libraries, etc.
About this result
This page is automatically generated and may contain information that is not correct, complete, up-to-date, or relevant to your search query. The same applies to every other page on this website. Please make sure to verify the information with EPFL's official sources.