Pragmas (Using the GNU Compiler Collection (GCC)) (original) (raw)
Next: Thread-Local Storage, Previous: Attributes Specific to GCC, Up: Extensions to the C Language Family [Contents][Index]
6.5 Pragmas Accepted by GCC ¶
GCC supports several types of pragmas, primarily in order to compile code originally written for other compilers. Note that in general we do not recommend the use of pragmas; See Declaring Attributes of Functions, for further explanation.
The GNU C preprocessor recognizes several pragmas in addition to the compiler pragmas documented here. Refer to the CPP manual for more information.
GCC additionally recognizes OpenMP pragmas when the -fopenmpoption is specified, and OpenACC pragmas when the -fopenaccoption is specified. See OpenMP, and OpenACC.
- AArch64 Pragmas
- ARM Pragmas
- LoongArch Pragmas
- M32C Pragmas
- PRU Pragmas
- RS/6000 and PowerPC Pragmas
- S/390 Pragmas
- Darwin Pragmas
- Solaris Pragmas
- Symbol-Renaming Pragmas
- Structure-Layout Pragmas
- Weak Pragmas
- Diagnostic Pragmas
- Visibility Pragmas
- Push/Pop Macro Pragmas
- Function Specific Option Pragmas
- Loop-Specific Pragmas