This file documents the use of the GNU compilers.
Copyright © 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
2008 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.2 or
any later version published by the Free Software Foundation; with the
Invariant Sections being “GNU General Public License” and “Funding
Free Software”, the Front-Cover texts being (a) (see below), and with
the Back-Cover Texts being (b) (see below). A copy of the license is
included in the section entitled “GNU Free Documentation License”.
(a) The FSF's Front-Cover Text is:
A GNU Manual
(b) The FSF's Back-Cover Text is:
You have freedom to copy and modify this GNU Manual, like GNU
software. Copies published by the Free Software Foundation raise
funds for GNU development.
Table of Contents
- Introduction
- 1 Programming Languages Supported by GCC
- 2 Language Standards Supported by GCC
- 3 GCC Command Options
- 4 C Implementation-defined behavior
- 5 Extensions to the C Language Family
- 5.1 Statements and Declarations in Expressions
- 5.2 Locally Declared Labels
- 5.3 Labels as Values
- 5.4 Nested Functions
- 5.5 Constructing Function Calls
- 5.6 Referring to a Type with
typeof
- 5.7 Conditionals with Omitted Operands
- 5.8 Double-Word Integers
- 5.9 Complex Numbers
- 5.10 Additional Floating Types
- 5.11 Decimal Floating Types
- 5.12 Hex Floats
- 5.13 Fixed-Point Types
- 5.14 Arrays of Length Zero
- 5.15 Structures With No Members
- 5.16 Arrays of Variable Length
- 5.17 Macros with a Variable Number of Arguments.
- 5.18 Slightly Looser Rules for Escaped Newlines
- 5.19 Non-Lvalue Arrays May Have Subscripts
- 5.20 Arithmetic on
void
- and Function-Pointers
- 5.21 Non-Constant Initializers
- 5.22 Compound Literals
- 5.23 Designated Initializers
- 5.24 Case Ranges
- 5.25 Cast to a Union Type
- 5.26 Mixed Declarations and Code
- 5.27 Declaring Attributes of Functions
- 5.28 Attribute Syntax
- 5.29 Prototypes and Old-Style Function Definitions
- 5.30 C++ Style Comments
- 5.31 Dollar Signs in Identifier Names
- 5.32 The Character <ESC> in Constants
- 5.33 Inquiring on Alignment of Types or Variables
- 5.34 Specifying Attributes of Variables
- 5.35 Specifying Attributes of Types
- 5.36 An Inline Function is As Fast As a Macro
- 5.37 Assembler Instructions with C Expression Operands
- 5.38 Constraints for
asm
Operands
- 5.39 Controlling Names Used in Assembler Code
- 5.40 Variables in Specified Registers
- 5.41 Alternate Keywords
- 5.42 Incomplete
enum
Types
- 5.43 Function Names as Strings
- 5.44 Getting the Return or Frame Address of a Function
- 5.45 Using vector instructions through built-in functions
- 5.46 Offsetof
- 5.47 Built-in functions for atomic memory access
- 5.48 Object Size Checking Builtins
- 5.49 Other built-in functions provided by GCC
- 5.50 Built-in Functions Specific to Particular Target Machines
- 5.50.1 Alpha Built-in Functions
- 5.50.2 ARM iWMMXt Built-in Functions
- 5.50.3 ARM NEON Intrinsics
- 5.50.3.1 Addition
- 5.50.3.2 Multiplication
- 5.50.3.3 Multiply-accumulate
- 5.50.3.4 Multiply-subtract
- 5.50.3.5 Subtraction
- 5.50.3.6 Comparison (equal-to)
- 5.50.3.7 Comparison (greater-than-or-equal-to)
- 5.50.3.8 Comparison (less-than-or-equal-to)
- 5.50.3.9 Comparison (greater-than)
- 5.50.3.10 Comparison (less-than)
- 5.50.3.11 Comparison (absolute greater-than-or-equal-to)
- 5.50.3.12 Comparison (absolute less-than-or-equal-to)
- 5.50.3.13 Comparison (absolute greater-than)
- 5.50.3.14 Comparison (absolute less-than)
- 5.50.3.15 Test bits
- 5.50.3.16 Absolute difference
- 5.50.3.17 Absolute difference and accumulate
- 5.50.3.18 Maximum
- 5.50.3.19 Minimum
- 5.50.3.20 Pairwise add
- 5.50.3.21 Pairwise add, single_opcode widen and accumulate
- 5.50.3.22 Folding maximum
- 5.50.3.23 Folding minimum
- 5.50.3.24 Reciprocal step
- 5.50.3.25 Vector shift left
- 5.50.3.26 Vector shift left by constant
- 5.50.3.27 Vector shift right by constant
- 5.50.3.28 Vector shift right by constant and accumulate
- 5.50.3.29 Vector shift right and insert
- 5.50.3.30 Vector shift left and insert
- 5.50.3.31 Absolute value
- 5.50.3.32 Negation
- 5.50.3.33 Bitwise not
- 5.50.3.34 Count leading sign bits
- 5.50.3.35 Count leading zeros
- 5.50.3.36 Count number of set bits
- 5.50.3.37 Reciprocal estimate
- 5.50.3.38 Reciprocal square-root estimate
- 5.50.3.39 Get lanes from a vector
- 5.50.3.40 Set lanes in a vector
- 5.50.3.41 Create vector from literal bit pattern
- 5.50.3.42 Set all lanes to the same value
- 5.50.3.43 Combining vectors
- 5.50.3.44 Splitting vectors
- 5.50.3.45 Conversions
- 5.50.3.46 Move, single_opcode narrowing
- 5.50.3.47 Move, single_opcode long
- 5.50.3.48 Table lookup
- 5.50.3.49 Extended table lookup
- 5.50.3.50 Multiply, lane
- 5.50.3.51 Long multiply, lane
- 5.50.3.52 Saturating doubling long multiply, lane
- 5.50.3.53 Saturating doubling multiply high, lane
- 5.50.3.54 Multiply-accumulate, lane
- 5.50.3.55 Multiply-subtract, lane
- 5.50.3.56 Vector multiply by scalar
- 5.50.3.57 Vector long multiply by scalar
- 5.50.3.58 Vector saturating doubling long multiply by scalar
- 5.50.3.59 Vector saturating doubling multiply high by scalar
- 5.50.3.60 Vector multiply-accumulate by scalar
- 5.50.3.61 Vector multiply-subtract by scalar
- 5.50.3.62 Vector extract
- 5.50.3.63 Reverse elements
- 5.50.3.64 Bit selection
- 5.50.3.65 Transpose elements
- 5.50.3.66 Zip elements
- 5.50.3.67 Unzip elements
- 5.50.3.68 Element/structure loads, VLD1 variants
- 5.50.3.69 Element/structure stores, VST1 variants
- 5.50.3.70 Element/structure loads, VLD2 variants
- 5.50.3.71 Element/structure stores, VST2 variants
- 5.50.3.72 Element/structure loads, VLD3 variants
- 5.50.3.73 Element/structure stores, VST3 variants
- 5.50.3.74 Element/structure loads, VLD4 variants
- 5.50.3.75 Element/structure stores, VST4 variants
- 5.50.3.76 Logical operations (AND)
- 5.50.3.77 Logical operations (OR)
- 5.50.3.78 Logical operations (exclusive OR)
- 5.50.3.79 Logical operations (AND-NOT)
- 5.50.3.80 Logical operations (OR-NOT)
- 5.50.3.81 Reinterpret casts
- 5.50.4 Blackfin Built-in Functions
- 5.50.5 FR-V Built-in Functions
- 5.50.6 X86 Built-in Functions
- 5.50.7 MIPS DSP Built-in Functions
- 5.50.8 MIPS Paired-Single Support
- 5.50.9 PowerPC AltiVec Built-in Functions
- 5.50.10 SPARC VIS Built-in Functions
- 5.50.11 SPU Built-in Functions
- 5.51 Format Checks Specific to Particular Target Machines
- 5.52 Pragmas Accepted by GCC
- 5.53 Unnamed struct/union fields within structs/unions
- 5.54 Thread-Local Storage
- 5.55 Binary constants using the `0b' prefix
- 6 Extensions to the C++ Language
- 7 GNU Objective-C runtime features
- 8 Binary Compatibility
- 9 gcov—a Test Coverage Program
- 10 Known Causes of Trouble with GCC
- 11 Reporting Bugs
- 12 How To Get Help with GCC
- 13 Contributing to GCC Development
- Funding Free Software
- The GNU Project and GNU/Linux
- GNU General Public License
- GNU Free Documentation License
- Contributors to GCC
- Option Index
- Keyword Index
Introduction
This manual documents how to use the GNU compilers,
as well as their features and incompatibilities, and how to report
bugs. It corresponds to the compilers
(GCC)
version 4.3.5.
The internals of the GNU compilers, including how to port them to new
targets and some information about how to write front ends for new
languages, are documented in a separate manual. See Introduction.