Target Macros (GNU Compiler Collection (GCC) Internals) (original) (raw)
Next: Host Configuration, Previous: Machine Descriptions, Up: Introduction [Contents][Index]
17 Target Description Macros and Functions ¶
In addition to the file machine.md, a machine description includes a C header file conventionally given the namemachine.h and a C source file named machine.c. The header file defines numerous macros that convey the information about the target machine that does not fit into the scheme of the.md file. The file tm.h should be a link tomachine.h. The header file config.h includestm.h and most compiler source files include config.h. The source file defines a variable targetm
, which is a structure containing pointers to functions and data relating to the target machine. machine.c should also contain their definitions, if they are not defined elsewhere in GCC, and other functions called through the macros defined in the .h file.
- The Global targetm Variable
- Controlling the Compilation Driver, gcc
- Run-time Target Specification
- Defining data structures for per-function information.
- Storage Layout
- Layout of Source Language Data Types
- Register Usage
- Register Classes
- Stack Layout and Calling Conventions
- Implementing the Varargs Macros
- Support for Nested Functions
- Implicit Calls to Library Routines
- Addressing Modes
- Anchored Addresses
- Condition Code Status
- Describing Relative Costs of Operations
- Adjusting the Instruction Scheduler
- Dividing the Output into Sections (Texts, Data, …)
- Position Independent Code
- Defining the Output Assembler Language
- Controlling Debugging Information Format
- Cross Compilation and Floating Point
- Mode Switching Instructions
- Defining target-specific uses of __attribute__
- Emulating TLS
- Defining coprocessor specifics for MIPS targets.
- Parameters for Precompiled Header Validity Checking
- C++ ABI parameters
- D ABI parameters
- Rust ABI parameters
- Adding support for named address spaces
- Miscellaneous Parameters