-pass-exit-codes | Exit with highest error code from a phase. | help |
--help | Display this information. | help |
--target-help | Display target specific command line options (including assembler and linker options). | help |
--version | Display compiler version information. | help |
-dumpspecs | Display all of the built in spec strings. | help |
-dumpversion | Display the version of the compiler. | help |
-dumpmachine | Display the compiler's target processor. | help |
-foffload targets | Specify offloading targets. | help |
-print-search-dirs | Display the directories in the compiler's search path. | help |
-print-libgcc-file-name | Display the name of the compiler's companion library. | help |
-print-file-name lib | Display the full path to library <lib>. | help |
-print-prog-name prog | Display the full path to compiler component <prog>. | help |
-print-multiarch | Display the target's normalized GNU triplet, used as a component in the library path. | help |
-print-multi-directory | Display the root directory for versions of libgcc. | help |
-print-multi-lib | Display the mapping between command line options and multiple library search directories. | help |
-print-sysroot | Display the target libraries directory. | help |
-Wa | Pass comma-separated <options> on to the assembler. | help |
-Wp | Pass comma-separated <options> on to the preprocessor. | help |
-Wl | Pass comma-separated <options> on to the linker. | help |
-Xassembler arg | Pass <arg> on to the assembler. | help |
-Xpreprocessor arg | Pass <arg> on to the preprocessor. | help |
-Xlinker arg | Pass <arg> on to the linker. | help |
-save-temps | Store the usual "temporary" intermediate files permanently; | help + man |
-no-canonical-prefixes | Do not canonicalize paths when building relative prefixes to other gcc components. | help |
-pipe | Use pipes rather than intermediate files. | help |
-time | Time the execution of each subprocess. | help |
-specs file | Override built-in specs with the contents of <file>. | help |
-std standard | Specify the standard to which the program is expected to conform, which may be one of f95, f2003, f2008, f2018, f2023, gnu, or legacy. | help + man |
--sysroot directory | Use <directory> as the root directory for headers and libraries. | help |
-B directory | Add <directory> to the compiler's search paths. | help |
-v | Display the programs invoked by the compiler. | help |
-### | Like -v but options quoted and commands not executed. | help |
-E | Preprocess only; | help |
-S | Compile only; | help |
-c | Compile and assemble, but do not link. | help |
-o file | Place the output into <file>. | help |
-pie | Create a dynamically linked position independent executable. | help |
-shared | Create a shared library. | help |
-x language | Specify the language of the following input files. | help |
-fbacktrace -fdebug-aux-vars | Directory Options (in the manual page but not in --help) | man |
-Idir -Jdir | Link Options (in the manual page but not in --help) | man |
-static-libgfortran -static-libquadmath | Runtime Options (in the manual page but not in --help) | man |
-fconvert conversion | Interoperability Options (in the manual page but not in --help) | man |
-fc-prototypes -fc-prototypes-external | Code Generation Options (in the manual page but not in --help) | man |
-fdump-fortran-global -fdump-fortran-optimized | ## Options controlling Fortran dialect (in the manual page but not in --help) | man |
-ffree-form | (in the manual page but not in --help) | man |
-ffixed-form | Specify the layout used by the source file. (in the manual page but not in --help) | man |
-fall-intrinsics | This option causes all intrinsic procedures (including the GNU-specific extensions) to be accepted. (in the manual page but not in --help) | man |
-fallow-argument-mismatch | Some code contains calls to external procedures with mismatches between the calls and the procedure definition, or with mismatches between different calls. (in the manual page but not in --help) | man |
-fallow-invalid-boz | A BOZ literal constant can occur in a limited number of contexts in standard conforming Fortran. (in the manual page but not in --help) | man |
-fd-lines-as-code | (in the manual page but not in --help) | man |
-fd-lines-as-comments | Enable special treatment for lines beginning with "d" or "D" in fixed form sources. (in the manual page but not in --help) | man |
-fdec | DEC compatibility mode. (in the manual page but not in --help) | man |
-fdec-char-conversions | Enable the use of character literals in assignments and "DATA" statements for non-character variables. (in the manual page but not in --help) | man |
-fdec-structure | Enable DEC "STRUCTURE" and "RECORD" as well as "UNION", "MAP", and dot ('.') as a member separator (in addition to '%'). (in the manual page but not in --help) | man |
-fdec-intrinsic-ints | Enable B/I/J/K kind variants of existing integer functions (e.g. "BIAND", "IIAND", "JIAND", etc...). (in the manual page but not in --help) | man |
-fdec-math | Obsolete flag. (in the manual page but not in --help) | man |
-fdec-static | Enable DEC-style "STATIC" and "AUTOMATIC" attributes to explicitly specify the storage of variables and other objects. (in the manual page but not in --help) | man |
-fdec-include | Enable parsing of "INCLUDE" as a statement in addition to parsing it as "INCLUDE" line. (in the manual page but not in --help) | man |
-fdec-format-defaults | Enable format specifiers F, G and I to be used without width specifiers; (in the manual page but not in --help) | man |
-fdec-blank-format-item | Enable a blank format item at the end of a format specification i.e. nothing following the final comma. (in the manual page but not in --help) | man |
-fdollar-ok | Allow $ as a valid non-first character in a symbol name. (in the manual page but not in --help) | man |
-fbackslash | Change the interpretation of backslashes in string literals from a single backslash character to "C-style" escape characters. (in the manual page but not in --help) | man |
-fmodule-private | Set the default accessibility of module entities to "PRIVATE". (in the manual page but not in --help) | man |
-ffixed-line-length-n | Set column after which characters are ignored in typical fixed-form lines in the source file, and, unless "-fno-pad-source", through which spaces are assumed (as if padded to that length) after the… (in the manual page but not in --help) | man |
-fno-pad-source | By default fixed-form lines have spaces assumed (as if padded to that length) after the ends of short fixed-form lines. (in the manual page but not in --help) | man |
-ffree-line-length-n | Set column after which characters are ignored in typical free-form lines in the source file. (in the manual page but not in --help) | man |
-fmax-identifier-length n | Specify the maximum allowed identifier length. (in the manual page but not in --help) | man |
-fimplicit-none | Specify that no implicit typing is allowed, unless overridden by explicit "IMPLICIT" statements. (in the manual page but not in --help) | man |
-fcray-pointer | Enable the Cray pointer extension, which provides C-like pointer functionality. (in the manual page but not in --help) | man |
-fopenacc | Enable handling of OpenACC directives !$acc in free-form Fortran and !$acc, c$acc and $acc in fixed-form Fortran. (in the manual page but not in --help) | man |
-fopenmp | Enable handling of OpenMP directives !$omp in Fortran. (in the manual page but not in --help) | man |
-fopenmp-allocators | Enables handling of allocation, reallocation and deallocation of Fortran allocatable and pointer variables that are allocated using the !$omp allocators and !$omp allocate constructs. (in the manual page but not in --help) | man |
-fopenmp-simd | Enable handling of OpenMP's "simd", "declare simd", "declare reduction", "assume", "ordered", "scan" and "loop" directive, and of combined or composite directives with "simd" as constituent with… (in the manual page but not in --help) | man |
-fno-range-check | Disable range checking on results of simplification of constant expressions during compilation. (in the manual page but not in --help) | man |
-fdefault-integer-8 | Set the default integer and logical types to an 8 byte wide type. (in the manual page but not in --help) | man |
-fdefault-real-8 | Set the default real type to an 8 byte wide type. (in the manual page but not in --help) | man |
-fdefault-real-10 | Set the default real type to an 10 byte wide type. (in the manual page but not in --help) | man |
-fdefault-real-16 | Set the default real type to an 16 byte wide type. (in the manual page but not in --help) | man |
-fdefault-double-8 | Set the "DOUBLE PRECISION" type and double real constants like "1.d0" to an 8 byte wide type. (in the manual page but not in --help) | man |
-finteger-4-integer-8 | Promote all INTEGER(KIND=4) entities to an INTEGER(KIND=8) entities. (in the manual page but not in --help) | man |
-freal-4-real-8 | (in the manual page but not in --help) | man |
-freal-4-real-10 | (in the manual page but not in --help) | man |
-freal-4-real-16 | (in the manual page but not in --help) | man |
-freal-8-real-4 | (in the manual page but not in --help) | man |
-freal-8-real-10 | (in the manual page but not in --help) | man |
-freal-8-real-16 | Promote all REAL(KIND=M) entities to REAL(KIND=N) entities. (in the manual page but not in --help) | man |
-ftest-forall-temp | Enhance test coverage by forcing most forall assignments to use temporary. (in the manual page but not in --help) | man |
-funsigned | Allow the experimental unsigned extension. (in the manual page but not in --help) | man |
-cpp | (in the manual page but not in --help) | man |
-nocpp | Enable preprocessing. (in the manual page but not in --help) | man |
-dM | Instead of the normal output, generate a list of '#define' directives for all the macros defined during the execution of the preprocessor, including predefined macros. (in the manual page but not in --help) | man |
-dD | Like -dM except in two respects: it does not include the predefined macros, and it outputs both the "#define" directives and the result of preprocessing. (in the manual page but not in --help) | man |
-dN | Like -dD, but emit only the macro names, not their expansions. (in the manual page but not in --help) | man |
-dU | Like dD except that only macros that are expanded, or whose definedness is tested in preprocessor directives, are output; (in the manual page but not in --help) | man |
-dI | Output '#include' directives in addition to the result of preprocessing. (in the manual page but not in --help) | man |
-fworking-directory | Enable generation of linemarkers in the preprocessor output that let the compiler know the current working directory at the time of preprocessing. (in the manual page but not in --help) | man |
-idirafter dir | Search dir for include files, but do it after all directories specified with -I and the standard system directories have been exhausted. (in the manual page but not in --help) | man |
-imultilib dir | Use dir as a subdirectory of the directory containing target-specific C++ headers. (in the manual page but not in --help) | man |
-iprefix prefix | Specify prefix as the prefix for subsequent -iwithprefix options. (in the manual page but not in --help) | man |
-isysroot dir | This option is like the --sysroot option, but applies only to header files. (in the manual page but not in --help) | man |
-iquote dir | Search dir only for header files requested with "#include "file""; (in the manual page but not in --help) | man |
-isystem dir | Search dir for header files, after all directories specified by -I but before the standard system directories. (in the manual page but not in --help) | man |
-nostdinc | Do not search the standard system directories for header files. (in the manual page but not in --help) | man |
-undef | Do not predefine any system-specific or GCC-specific macros. (in the manual page but not in --help) | man |
-Apredicate answer | Make an assertion with the predicate predicate and answer answer. (in the manual page but not in --help) | man |
-A-predicate answer | Cancel an assertion with the predicate predicate and answer answer. (in the manual page but not in --help) | man |
-C | Do not discard comments. (in the manual page but not in --help) | man |
-CC | Do not discard comments, including during macro expansion. (in the manual page but not in --help) | man |
-Dname | Predefine name as a macro, with definition 1. (in the manual page but not in --help) | man |
-H | Print the name of each header file used, in addition to other normal activities. (in the manual page but not in --help) | man |
-P | Inhibit generation of linemarkers in the output from the preprocessor. (in the manual page but not in --help) | man |
-Uname | Cancel any previous definition of name, either built in or provided with a -D option. (in the manual page but not in --help) | man |
-fmax-errors n | Limits the maximum number of error messages to n, at which point GNU Fortran bails out rather than attempting to continue processing the source code. (in the manual page but not in --help) | man |
-fsyntax-only | Check the code for syntax errors, but do not actually compile it. (in the manual page but not in --help) | man |
-Wpedantic | (in the manual page but not in --help) | man |
-pedantic | Issue warnings for uses of extensions to Fortran. (in the manual page but not in --help) | man |
-pedantic-errors | Like -pedantic, except that errors are produced rather than warnings. (in the manual page but not in --help) | man |
-Wall | Enables commonly used warning options pertaining to usage that we recommend avoiding and that we believe are easy to avoid. (in the manual page but not in --help) | man |
-Waliasing | Warn about possible aliasing of dummy arguments. (in the manual page but not in --help) | man |
-Wampersand | Warn about missing ampersand in continued character constants. (in the manual page but not in --help) | man |
-Warray-temporaries | Warn about array temporaries generated by the compiler. (in the manual page but not in --help) | man |
-Wc-binding-type | Warn if the a variable might not be C interoperable. (in the manual page but not in --help) | man |
-Wcharacter-truncation | Warn when a character assignment truncates the assigned string. (in the manual page but not in --help) | man |
-Wline-truncation | Warn when a source code line is truncated. (in the manual page but not in --help) | man |
-Wconversion | Warn about implicit conversions that are likely to change the value of the expression after conversion. (in the manual page but not in --help) | man |
-Wconversion-extra | Warn about implicit conversions between different types and kinds. (in the manual page but not in --help) | man |
-Wdeprecated-openmp | Warn for usage of deprecated OpenMP code. (in the manual page but not in --help) | man |
-Wexternal-argument-mismatch | Warn about argument mismatches for dummy external procedures. (in the manual page but not in --help) | man |
-Wextra | Enables some warning options for usages of language features that may be problematic. (in the manual page but not in --help) | man |
-Wfrontend-loop-interchange | Warn when using -ffrontend-loop-interchange for performing loop interchanges. (in the manual page but not in --help) | man |
-Wimplicit-interface | Warn if a procedure is called without an explicit interface. (in the manual page but not in --help) | man |
-Wimplicit-procedure | Warn if a procedure is called that has neither an explicit interface nor has been declared as "EXTERNAL". (in the manual page but not in --help) | man |
-Winteger-division | Warn if a constant integer division truncates its result. (in the manual page but not in --help) | man |
-Wintrinsics-std | Warn if gfortran finds a procedure named like an intrinsic not available in the currently selected standard (with -std) and treats it as "EXTERNAL" procedure because of this. (in the manual page but not in --help) | man |
-Wno-overwrite-recursive | Do not warn when -fno-automatic is used with -frecursive. (in the manual page but not in --help) | man |
-Wreal-q-constant | Produce a warning if a real-literal-constant contains a "q" exponent-letter. (in the manual page but not in --help) | man |
-Wsurprising | Produce a warning when "suspicious" code constructs are encountered. (in the manual page but not in --help) | man |
-Wtabs | By default, tabs are accepted as whitespace, but tabs are not members of the Fortran Character Set. (in the manual page but not in --help) | man |
-Wundefined-do-loop | Warn if a "DO" loop with step either 1 or -1 yields an underflow or an overflow during iteration of an induction variable of the loop. (in the manual page but not in --help) | man |
-Wunderflow | Produce a warning when numerical constant expressions that yield an underflow are encountered during compilation. (in the manual page but not in --help) | man |
-Wintrinsic-shadow | Warn if a user-defined procedure or module procedure has the same name as an intrinsic; (in the manual page but not in --help) | man |
-Wuse-without-only | Warn if a "USE" statement has no "ONLY" qualifier and thus implicitly imports all public entities of the used module. (in the manual page but not in --help) | man |
-Wunused-dummy-argument | Warn about unused dummy arguments. (in the manual page but not in --help) | man |
-Wunused-parameter | Contrary to gcc's meaning of -Wunused-parameter, gfortran's implementation of this option does not warn about unused dummy arguments (see -Wunused-dummy-argument), but about unused "PARAMETER" values. (in the manual page but not in --help) | man |
-Walign-commons | By default, gfortran warns about any occasion of variables being padded for proper alignment inside a "COMMON" block. (in the manual page but not in --help) | man |
-Wfunction-elimination | Warn if any calls to impure functions are eliminated by the optimizations enabled by the -ffrontend-optimize option. (in the manual page but not in --help) | man |
-Wrealloc-lhs | Warn when the compiler might insert code to for allocation or reallocation of an allocatable array variable of intrinsic type in intrinsic assignments. (in the manual page but not in --help) | man |
-Wrealloc-lhs-all | Warn when the compiler inserts code to for allocation or reallocation of an allocatable variable; (in the manual page but not in --help) | man |
-Wcompare-reals | Warn when comparing real or complex types for equality or inequality. (in the manual page but not in --help) | man |
-Wtarget-lifetime | Warn if the pointer in a pointer assignment might be longer than the its target. (in the manual page but not in --help) | man |
-Wzerotrip | Warn if a "DO" loop is known to execute zero times at compile time. (in the manual page but not in --help) | man |
-Wdo-subscript | Warn if an array subscript inside a "DO" loop could lead to an out-of-bounds access even if the compiler cannot prove that the statement is actually executed, in cases like (in the manual page but not in --help) | man |
-Werror | Turns all warnings into errors. (in the manual page but not in --help) | man |
-fdebug-aux-vars | Renames internal variables created by the gfortran front end and makes them accessible to a debugger. (in the manual page but not in --help) | man |
-ffpe-trap list | Specify a list of floating point exception traps to enable. (in the manual page but not in --help) | man |
-ffpe-summary list | Specify a list of floating-point exceptions, whose flag status is printed to "ERROR_UNIT" when invoking "STOP" and "ERROR STOP". (in the manual page but not in --help) | man |
-fno-backtrace | When a serious runtime error is encountered or a deadly signal is emitted (segmentation fault, illegal instruction, bus error, floating-point exception, and the other POSIX signals that have the… (in the manual page but not in --help) | man |
-Jdir | This option specifies where to put .mod files for compiled modules. (in the manual page but not in --help) | man |
-fintrinsic-modules-path dir | This option specifies the location of pre-compiled intrinsic modules, if they are not in the default location expected by the compiler. (in the manual page but not in --help) | man |
-static-libquadmath | On systems that provide libquadmath as a shared and a static library, this option forces the use of the static version. (in the manual page but not in --help) | man |
-frecord-marker length | Specify the length of record markers for unformatted files. (in the manual page but not in --help) | man |
-fmax-subrecord-length length | Specify the maximum length for a subrecord. (in the manual page but not in --help) | man |
-fsign-zero | When enabled, floating point numbers of value zero with the sign bit set are written as negative number in formatted output and treated as negative in the "SIGN" intrinsic. (in the manual page but not in --help) | man |
-fdump-fortran-optimized | Output the parse tree after front-end optimization. (in the manual page but not in --help) | man |
-fdump-fortran-original | Output the internal parse tree after translating the source program into internal representation. (in the manual page but not in --help) | man |
-fdump-parse-tree | Output the internal parse tree after translating the source program into internal representation. (in the manual page but not in --help) | man |
-fno-automatic | Treat each program unit (except those marked as "RECURSIVE") as if the "SAVE" statement were specified for every local variable and array referenced in it. (in the manual page but not in --help) | man |
-ff2c | Generate code designed to be compatible with code generated by g77 and f2c. (in the manual page but not in --help) | man |
-fno-underscoring | Do not transform names of entities specified in the Fortran source file by appending underscores to them. (in the manual page but not in --help) | man |
-fsecond-underscore | By default, GNU Fortran appends an underscore to external names. (in the manual page but not in --help) | man |
-fcoarray keyword | none (in the manual page but not in --help) | man |
-fcheck keyword | Enable the generation of run-time checks; (in the manual page but not in --help) | man |
-fbounds-check | Deprecated alias for -fcheck=bounds. (in the manual page but not in --help) | man |
-ftail-call-workaround | (in the manual page but not in --help) | man |
-fcheck-array-temporaries | Deprecated alias for -fcheck=array-temps. (in the manual page but not in --help) | man |
-fmax-array-constructor n | This option can be used to increase the upper limit permitted in array constructors. (in the manual page but not in --help) | man |
-fmax-stack-var-size n | This option specifies the size in bytes of the largest array that is put on the stack; (in the manual page but not in --help) | man |
-fstack-arrays | Adding this option makes the Fortran compiler put all arrays of unknown size and array temporaries onto stack memory. (in the manual page but not in --help) | man |
-fpack-derived | This option tells GNU Fortran to pack derived type members as closely as possible. (in the manual page but not in --help) | man |
-frepack-arrays | In some circumstances GNU Fortran may pass assumed shape array sections via a descriptor describing a noncontiguous area of memory. (in the manual page but not in --help) | man |
-fshort-enums | This option is provided for interoperability with C code that was compiled with the -fshort-enums option. (in the manual page but not in --help) | man |
-finline-arg-packing | When passing an assumed-shape argument of a procedure as actual argument to an assumed-size or explicit size or as argument to a procedure that does not have an explicit interface, the argument may… (in the manual page but not in --help) | man |
-fexternal-blas | This option makes gfortran generate calls to BLAS functions for some matrix operations like "MATMUL", instead of using our own algorithms, if the size of the matrices involved is larger than a given… (in the manual page but not in --help) | man |
-fexternal-blas64 | makes gfortran generate calls to BLAS functions for some matrix operations like "MATMUL", instead of using our own algorithms, if the size of the matrices involved is larger than a given limit (see… (in the manual page but not in --help) | man |
-fblas-matmul-limit n | Only significant when -fexternal-blas or -fexternal-blas64 are in effect. (in the manual page but not in --help) | man |
-finline-intrinsics | (in the manual page but not in --help) | man |
-finline-matmul-limit n | When front-end optimization is active, some calls to the "MATMUL" intrinsic function are inlined. (in the manual page but not in --help) | man |
-frecursive | Allow indirect recursion by forcing all local arrays to be allocated on the stack. (in the manual page but not in --help) | man |
-finit-local-zero | (in the manual page but not in --help) | man |
-finit-derived | (in the manual page but not in --help) | man |
-finit-integer n | (in the manual page but not in --help) | man |
-finit-real zero|inf|-inf|nan|snan | (in the manual page but not in --help) | man |
-finit-logical true|false | (in the manual page but not in --help) | man |
-finit-character n | The -finit-local-zero option instructs the compiler to initialize local "INTEGER", "REAL", and "COMPLEX" variables to zero, "LOGICAL" variables to false, and "CHARACTER" variables to a string of null… (in the manual page but not in --help) | man |
-falign-commons | By default, gfortran enforces proper alignment of all variables in a "COMMON" block by padding them as needed. (in the manual page but not in --help) | man |
-fno-protect-parens | By default the parentheses in expression are honored for all optimization levels such that the compiler does not do any reassociation. (in the manual page but not in --help) | man |
-frealloc-lhs | An allocatable left-hand side of an intrinsic assignment is automatically (re)allocated if it is either unallocated or has a different shape. (in the manual page but not in --help) | man |
-faggressive-function-elimination | Functions with identical argument lists are eliminated within statements, regardless of whether these functions are marked "PURE" or not. (in the manual page but not in --help) | man |
-ffrontend-optimize | This option performs front-end optimization, based on manipulating parts of the Fortran parse tree. (in the manual page but not in --help) | man |
-ffrontend-loop-interchange | Attempt to interchange loops in the Fortran front end where profitable. (in the manual page but not in --help) | man |