C99 Mode Dev C%2b%2b

Learning Database New Features

ARM Optimizing C/C Compiler v5.2 User's Guide Literature Number: SPNU151J November 2014. Dev C C99 Mode Posted on 5/31/2020 The default compilation mode for Sun compilers that support the # C99 standard is -xc99=all,nolib. C99MODE = is equivalent to -xc99=all,nolib. Final cut pro high sierra dmg.

C99 Mode Dev C 2b 2b 2c

21c

F36089-08

December 2020

Learning Database New Features

F36089-08

Copyright © 2020, Oracle and/or its affiliates.

This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited.

The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing.

If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, then the following notice is applicable:

U.S. GOVERNMENT END USERS: Oracle programs (including any operating system, integrated software, any programs embedded, installed or activated on delivered hardware, and modifications of such programs) and Oracle computer documentation or other Oracle data delivered to or accessed by U.S. Government end users are 'commercial computer software' or 'commercial computer software documentation' pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use, reproduction, duplication, release, display, disclosure, modification, preparation of derivative works, and/or adaptation of i) Oracle programs (including any operating system, integrated software, any programs embedded, installed or activated on delivered hardware, and modifications of such programs), ii) Oracle computer documentation and/or iii) other Oracle data, is subject to the rights and limitations specified in the license contained in the applicable contract. The terms governing the U.S. Government's use of Oracle cloud services are defined by the applicable contract for such services. No other rights are granted to the U.S. Government.

This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications.

Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.

Intel and Intel Inside are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Epyc, and the AMD logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group.

This software or hardware and documentation may provide access to or information about content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services unless otherwise set forth in an applicable agreement between you and Oracle. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services, except as set forth in an applicable agreement between you and Oracle.

Next: C++ Dialect Options, Previous: Invoking G++, Up: Invoking GCC [Contents][Index]

3.4 Options Controlling C Dialect

The following options control the dialect of C (or languages derivedfrom C, such as C++, Objective-C and Objective-C++) that the compileraccepts:

-ansi

C99 Mode Dev C 2b 2b 1b

In C mode, this is equivalent to -std=c90. In C++ mode, it isequivalent to -std=c++98.

This turns off certain features of GCC that are incompatible with ISOC90 (when compiling C code), or of standard C++ (when compiling C++ code),such as the asm and typeof keywords, andpredefined macros such as unix and vax that identify thetype of system you are using. It also enables the undesirable andrarely used ISO trigraph feature. For the C compiler,it disables recognition of C++ style ‘//’ comments as well asthe inline keyword.

The alternate keywords __asm__, __extension__,__inline__ and __typeof__ continue to work despite-ansi. You would not want to use them in an ISO C program, ofcourse, but it is useful to put them in header files that might be includedin compilations done with -ansi. Alternate predefined macrossuch as __unix__ and __vax__ are also available, with orwithout -ansi.

The -ansi option does not cause non-ISO programs to berejected gratuitously. For that, -Wpedantic is required inaddition to -ansi. See Warning Options.

The macro __STRICT_ANSI__ is predefined when the -ansioption is used. Some header files may notice this macro and refrainfrom declaring certain functions or defining certain macros that theISO standard doesn’t call for; this is to avoid interfering with anyprograms that might use these names for other things.

Functions that are normally built in but do not have semanticsdefined by ISO C (such as alloca and ffs) are not built-infunctions when -ansi is used. See Otherbuilt-in functions provided by GCC, for details of the functionsaffected.

-std=

Determine the language standard. See Language StandardsSupported by GCC, for details of these standard versions. This optionis currently only supported when compiling C or C++.

The compiler can accept several base standards, such as ‘c90’ or‘c++98’, and GNU dialects of those standards, such as‘gnu90’ or ‘gnu++98’. When a base standard is specified, thecompiler accepts all programs following that standard plus thoseusing GNU extensions that do not contradict it. For example,-std=c90 turns off certain features of GCC that areincompatible with ISO C90, such as the asm and typeofkeywords, but not other GNU extensions that do not have a meaning inISO C90, such as omitting the middle term of a ?:expression. On the other hand, when a GNU dialect of a standard isspecified, all features supported by the compiler are enabled, even whenthose features change the meaning of the base standard. As a result, somestrict-conforming programs may be rejected. The particular standardis used by -Wpedantic to identify which features are GNUextensions given that version of the standard. For example-std=gnu90 -Wpedantic warns about C++ style ‘//’comments, while -std=gnu99 -Wpedantic does not.

A value for this option must be provided; possible values are

c90
c89
iso9899:1990

Support all ISO C90 programs (certain GNU extensions that conflictwith ISO C90 are disabled). Same as -ansi for C code.

iso9899:199409

ISO C90 as modified in amendment 1.

c99
c9x
iso9899:1999
iso9899:199x

ISO C99. This standard is substantially completely supported, modulobugs and floating-point issues(mainly but not entirely relating to optional C99 features fromAnnexes F and G). Seehttp://gcc.gnu.org/c99status.html for more information. Thenames ‘c9x’ and ‘iso9899:199x’ are deprecated.

c11
c1x
iso9899:2011

ISO C11, the 2011 revision of the ISO C standard. This standard issubstantially completely supported, modulo bugs, floating-point issues(mainly but not entirely relating to optional C11 features fromAnnexes F and G) and the optional Annexes K (Bounds-checkinginterfaces) and L (Analyzability). The name ‘c1x’ is deprecated.

c17
c18
iso9899:2017
iso9899:2018

ISO C17, the 2017 revision of the ISO C standard(published in 2018). This standard issame as C11 except for corrections of defects (all of which are alsoapplied with -std=c11) and a new value of__STDC_VERSION__, and so is supported to the same extent as C11.

c2x

The next version of the ISO C standard, still under development. Thesupport for this version is experimental and incomplete.

gnu90
gnu89

GNU dialect of ISO C90 (including some C99 features).

gnu99
gnu9x

GNU dialect of ISO C99. The name ‘gnu9x’ is deprecated.

gnu11
gnu1x

GNU dialect of ISO C11.The name ‘gnu1x’ is deprecated.

gnu17
gnu18

GNU dialect of ISO C17. This is the default for C code.

gnu2x

The next version of the ISO C standard, still under development, plusGNU extensions. The support for this version is experimental andincomplete.

c++98
c++03

The 1998 ISO C++ standard plus the 2003 technical corrigendum and someadditional defect reports. Same as -ansi for C++ code.

gnu++98
gnu++03

GNU dialect of -std=c++98.

c++11
c++0x

The 2011 ISO C++ standard plus amendments.The name ‘c++0x’ is deprecated.

gnu++11
gnu++0x

GNU dialect of -std=c++11.The name ‘gnu++0x’ is deprecated.

C99 Mode Dev C 2b 2b 1

c++14
c++1y

The 2014 ISO C++ standard plus amendments.The name ‘c++1y’ is deprecated.

gnu++14
gnu++1y

GNU dialect of -std=c++14.The name ‘gnu++1y’ is deprecated.

c++17
c++1z

The 2017 ISO C++ standard plus amendments.The name ‘c++1z’ is deprecated.

gnu++17
gnu++1z

GNU dialect of -std=c++17.This is the default for C++ code.The name ‘gnu++1z’ is deprecated.

c++20
c++2a

The 2020 ISO C++ standard plus amendments.Support is experimental, and could change in incompatible ways infuture releases.The name ‘c++2a’ is deprecated.

gnu++20
gnu++2a

GNU dialect of -std=c++20.Support is experimental, and could change in incompatible ways infuture releases.The name ‘gnu++2a’ is deprecated.

-fgnu89-inline

The option -fgnu89-inline tells GCC to use the traditionalGNU semantics for inline functions when in C99 mode.See An Inline Function is As Fast As a Macro.Using this option is roughly equivalent to adding thegnu_inline function attribute to all inline functions(see Function Attributes).

The option -fno-gnu89-inline explicitly tells GCC to use theC99 semantics for inline when in C99 or gnu99 mode (i.e., itspecifies the default behavior).This option is not supported in -std=c90 or-std=gnu90 mode.

The preprocessor macros __GNUC_GNU_INLINE__ and__GNUC_STDC_INLINE__ may be used to check which semantics arein effect for inline functions. See Common PredefinedMacros in The C Preprocessor.

-fpermitted-flt-eval-methods=style

ISO/IEC TS 18661-3 defines new permissible values forFLT_EVAL_METHOD that indicate that operations and constants witha semantic type that is an interchange or extended format should beevaluated to the precision and range of that type. These new values area superset of those permitted under C99/C11, which does not specify themeaning of other positive values of FLT_EVAL_METHOD. As such, codeconforming to C11 may not have been written expecting the possibility ofthe new values.

-fpermitted-flt-eval-methods specifies whether the compilershould allow only the values of FLT_EVAL_METHOD specified in C99/C11,or the extended set of values specified in ISO/IEC TS 18661-3.

style is either c11 or ts-18661-3 as appropriate.

The default when in a standards compliant mode (-std=c11 or similar)is -fpermitted-flt-eval-methods=c11. The default when in a GNUdialect (-std=gnu11 or similar) is-fpermitted-flt-eval-methods=ts-18661-3.

-aux-info filename

Output to the given filename prototyped declarations for all functionsdeclared and/or defined in a translation unit, including those in headerfiles. This option is silently ignored in any language other than C.

Besides declarations, the file indicates, in comments, the origin ofeach declaration (source file and line), whether the declaration wasimplicit, prototyped or unprototyped (‘I’, ‘N’ for new or‘O’ for old, respectively, in the first character after the linenumber and the colon), and whether it came from a declaration or adefinition (‘C’ or ‘F’, respectively, in the followingcharacter). In the case of function definitions, a K&R-style list ofarguments followed by their declarations is also provided, insidecomments, after the declaration.

-fallow-parameterless-variadic-functions

Accept variadic functions without named parameters.

Although it is possible to define such a function, this is not veryuseful as it is not possible to read the arguments. This is onlysupported for C as this construct is allowed by C++.

-fno-asm

Do not recognize asm, inline or typeof as akeyword, so that code can use these words as identifiers. You can usethe keywords __asm__, __inline__ and __typeof__instead. -ansi implies -fno-asm.

In C++, this switch only affects the typeof keyword, sinceasm and inline are standard keywords. You may want touse the -fno-gnu-keywords flag instead, which has the sameeffect. In C99 mode (-std=c99 or -std=gnu99), thisswitch only affects the asm and typeof keywords, sinceinline is a standard keyword in ISO C99.

-fno-builtin
-fno-builtin-function

Don’t recognize built-in functions that do not begin with‘__builtin_’ as prefix. See Other built-infunctions provided by GCC, for details of the functions affected,including those which are not built-in functions when -ansi or-std options for strict ISO C conformance are used because theydo not have an ISO standard meaning.

GCC normally generates special code to handle certain built-in functionsmore efficiently; for instance, calls to alloca may become singleinstructions which adjust the stack directly, and calls to memcpymay become inline copy loops. The resulting code is often both smallerand faster, but since the function calls no longer appear as such, youcannot set a breakpoint on those calls, nor can you change the behaviorof the functions by linking with a different library. In addition,when a function is recognized as a built-in function, GCC may useinformation about that function to warn about problems with calls tothat function, or to generate more efficient code, even if theresulting code still contains calls to that function. For example,warnings are given with -Wformat for bad calls toprintf when printf is built in and strlen isknown not to modify global memory.

C99 mode dev c 2b 2b 1

C99 Mode Dev C 2b 2b 3

With the -fno-builtin-function optiononly the built-in function function isdisabled. function must not begin with ‘__builtin_’. If afunction is named that is not built-in in this version of GCC, thisoption is ignored. There is no corresponding-fbuiltin-function option; if you wish to enablebuilt-in functions selectively when using -fno-builtin or-ffreestanding, you may define macros such as:

-fgimple

Enable parsing of function definitions marked with __GIMPLE.This is an experimental feature that allows unit testing of GIMPLEpasses.

-fhosted

Assert that compilation targets a hosted environment. This implies-fbuiltin. A hosted environment is one in which theentire standard library is available, and in which main has a returntype of int. Examples are nearly everything except a kernel.This is equivalent to -fno-freestanding.

-ffreestanding

Assert that compilation targets a freestanding environment. Thisimplies -fno-builtin. A freestanding environmentis one in which the standard library may not exist, and program startup maynot necessarily be at main. The most obvious example is an OS kernel.This is equivalent to -fno-hosted.

See Language Standards Supported by GCC, for details offreestanding and hosted environments.

-fopenacc

Enable handling of OpenACC directives #pragma acc in C/C++ and!$acc in Fortran. When -fopenacc is specified, thecompiler generates accelerated code according to the OpenACC ApplicationProgramming Interface v2.6 https://www.openacc.org. This optionimplies -pthread, and thus is only supported on targets thathave support for -pthread.

-fopenacc-dim=geom

Specify default compute dimensions for parallel offload regions that donot explicitly specify. The geom value is a triple of’:’-separated sizes, in order ’gang’, ’worker’ and, ’vector’. A sizecan be omitted, to use a target-specific default value.

-fopenacc-kernels=mode

Specify mode of OpenACC ‘kernels’ constructs handling.With -fopenacc-kernels=decompose, OpenACC ‘kernels’constructs are decomposed into parts, a sequence of computeconstructs, each then handled individually.This is work in progress.With -fopenacc-kernels=parloops, OpenACC ‘kernels’ constructsare handled by the ‘parloops’ pass, en bloc.This is the current default.

-fopenmp

Enable handling of OpenMP directives #pragma omp in C/C++ and!$omp in Fortran. When -fopenmp is specified, thecompiler generates parallel code according to the OpenMP ApplicationProgram Interface v4.5 https://www.openmp.org. This optionimplies -pthread, and thus is only supported on targets thathave support for -pthread. -fopenmp implies-fopenmp-simd.

-fopenmp-simd

Enable handling of OpenMP’s SIMD directives with #pragma ompin C/C++ and !$omp in Fortran. Other OpenMP directivesare ignored.

-fgnu-tm

When the option -fgnu-tm is specified, the compilergenerates code for the Linux variant of Intel’s current TransactionalMemory ABI specification document (Revision 1.1, May 6 2009). This isan experimental feature whose interface may change in future versionsof GCC, as the official specification changes. Please note that notall architectures are supported for this feature.

For more information on GCC’s support for transactional memory,See The GNU Transactional Memory Library in GNUTransactional Memory Library.

Note that the transactional memory feature is not supported withnon-call exceptions (-fnon-call-exceptions).

-fms-extensions

Accept some non-standard constructs used in Microsoft header files.

In C++ code, this allows member names in structures to be similarto previous types declarations.

Some cases of unnamed fields in structures and unions are onlyaccepted with this option. See Unnamed struct/unionfields within structs/unions, for details.

Note that this option is off for all targets except for x86targets using ms-abi.

-fplan9-extensions

Accept some non-standard constructs used in Plan 9 code.

This enables -fms-extensions, permits passing pointers tostructures with anonymous fields to functions that expect pointers toelements of the type of the field, and permits referring to anonymousfields declared using a typedef. See Unnamedstruct/union fields within structs/unions, for details. This is onlysupported for C, not C++.

-fcond-mismatch

Allow conditional expressions with mismatched types in the second andthird arguments. The value of such an expression is void. This optionis not supported for C++.

-flax-vector-conversions

Allow implicit conversions between vectors with differing numbers ofelements and/or incompatible element types. This option should not beused for new code.

-funsigned-char

Let the type char be unsigned, like unsigned char.

Each kind of machine has a default for what char shouldbe. It is either like unsigned char by default or likesigned char by default.

Ideally, a portable program should always use signed char orunsigned char when it depends on the signedness of an object.But many programs have been written to use plain char andexpect it to be signed, or expect it to be unsigned, depending on themachines they were written for. This option, and its inverse, let youmake such a program work with the opposite default.

The type char is always a distinct type from each ofsigned char or unsigned char, even though its behavioris always just like one of those two.

-fsigned-char

Let the type char be signed, like signed char.

Note that this is equivalent to -fno-unsigned-char, which isthe negative form of -funsigned-char. Likewise, the option-fno-signed-char is equivalent to -funsigned-char.

-fsigned-bitfields
-funsigned-bitfields
-fno-signed-bitfields
-fno-unsigned-bitfields

These options control whether a bit-field is signed or unsigned, when thedeclaration does not use either signed or unsigned. Bydefault, such a bit-field is signed, because this is consistent: thebasic integer types such as int are signed types.

-fsso-struct=endianness

Set the default scalar storage order of structures and unions to thespecified endianness. The accepted values are ‘big-endian’,‘little-endian’ and ‘native’ for the native endianness ofthe target (the default). This option is not supported for C++.

Warning: the -fsso-struct switch causes GCC to generatecode that is not binary compatible with code generated without it if thespecified endianness is not the native endianness of the target.

Next: C++ Dialect Options, Previous: Invoking G++, Up: Invoking GCC [Contents][Index]