Intel® Fortran Compiler XE 13.1 User and Reference Guides
The following table shows the compile-time environment variables that affect the Intel® Fortran Compiler:
|
Compile-Time Environment Variable |
Description |
|---|---|
|
IFORTCFG |
Specifies a configuration file that the compiler should use instead of the default configuration file. By default, the compiler uses the default configuration file (ifort.cfg) from the same directory where the compiler executable resides. NoteOn Windows* operating systems, this environment variable cannot be set from the IDE. |
|
INTEL_LICENSE_FILE |
Specifies the location of the product license file. |
|
PATH |
Specifies the directory path for the compiler executable files. |
|
TMP, TMPDIR, TEMP |
Specifies the directory in which to store temporary files. See Temporary Files Created by the Compiler or Linker. NoteOn Windows* operating systems, this environment variable cannot be set from the IDE. |
|
CPATH (Linux* OS and OS X*) |
Specifies the path for include and module files. |
|
GCCROOT (Linux OS and OS X) |
Specifies the location of the gcc binaries. Set this variable only when the compiler cannot locate the gcc binaries when using the -gcc-name option. |
|
GXX_INCLUDE (Linux OS and OS X) |
Specifies the location of the gcc headers. Set this variable to specify the locations of the GCC installed files when the compiler does not find the needed values as specified by the use of -gcc-name=directory-name/gcc. |
|
GXX_ROOT (Linux OS and OS X) |
Specifies the location of the gcc binaries. Set this variable to specify the locations of the GCC installed files when the compiler does not find the needed values as specified by the use of -gcc-name=directory-name/gcc. |
|
LIBRARY_PATH (Linux OS and OS X) |
Specifies the path for libraries to be used during the link phase. |
|
LD_LIBRARY_PATH (Linux OS) |
Specifies the path for shared (.so) library files. |
|
DYLD_LIBRARY_PATH (OS X) |
Specifies the path for dynamic libraries. |
|
INCLUDE (Windows OS) |
Specifies the directory path for the include files (files included by INCLUDE statements, #include files, RC INCLUDE files, and module files referenced by USE statements). |
|
LIB (Windows OS) |
Specifies the directory path for .LIB (library) files, which the linker links in. If the LIB environment variable is not set, the linker looks for .LIB files in the current directory. |
The Intel® Fortran run-time system recognizes a number of environment variables. These variables can be used to customize run-time diagnostic error reporting, allow program continuation under certain conditions, disable the display of certain dialog boxes under certain conditions, and allow just-in-time debugging.
The following table summarize Compiler environment variables that are recognized at run time.
| Run-Time Environment Variable | Description |
|---|---|
|
decfort_dump_flag |
If this variable is set to Y or y, a core dump will be taken when any severe Intel Fortran run-time error occurs. |
|
F_UFMTENDIAN |
This variable specifies the numbers of the units to be used for little-endian-to-big-endian conversion purposes. See Environment Variable F_UFMTENDIAN Method. |
|
FOR_COARRAY_CONFIG_FILE (Windows* OS and Linux* OS) |
This variable specifies the coarray configuration file and path to be used at execution time. It overrides, at runtime, the value specified by the /Qcoarray-config-file:value (Windows* OS) or -coarray-config-file=value (Linux* OS) qualifier. |
|
FOR_COARRAY_NUM_IMAGES (Windows* OS and Linux* OS) |
This variable specifies the number of images created for coarrays. It overrides, at runtime, the value specified by the /Qcoarray-num-images:value (Windows* OS) or -coarray-num-images=value qualifier. |
|
FOR_FMT_TERMINATOR |
This variable specifies the numbers of the units to have a specific record terminator. See Record Types. |
|
FOR_ACCEPT |
The ACCEPT statement does not include an explicit logical unit number. Instead, it uses an implicit internal logical unit number and the FOR_ACCEPT environment variable. If FOR_ACCEPT is not defined, the code ACCEPT f,iolist reads from CONIN$ (standard input). If FOR_ACCEPT is defined (as a file name optionally containing a path), the specified file would be read. |
|
FOR_DEBUGGER_IS_PRESENT |
This variable tells the Fortran run-time library that your program is executing under a debugger. If set to True, it generates debug exceptions whenever severe or continuous errors are detected. Under normal conditions you don't need to set this variable on Windows systems, as this information can be extracted from the operating system. On Linux* OS and OS X*, you will need to set this variable if you want debug exceptions. Setting this variable to True when your program is not executing under a debugger will cause unpredictable behavior. |
|
FOR_DEFAULT_PRINT_DEVICE (Windows* OS only) |
This variable lets you specify the print device other than the default print device PRN (LPT1) for files closed (CLOSE statement) with the DISPOSE='PRINT' specifier. To specify a different print device for the file associated with the CLOSE statement DISPOSE='PRINT' specifier, set FOR_DEFAULT_PRINT_DEVICE to any legal DOS print device before executing the program. |
|
FOR_DIAGNOSTIC_LOG_FILE |
If this variable is set to the name of a file, diagnostic output is written to the specified file. The Fortran run-time system attempts to open that file (append output) and write the error information (ASCII text) to the file. The setting of FOR_DIAGNOSTIC_LOG_FILE is independent of FOR_DISABLE_DIAGNOSTIC_DISPLAY, so you can disable the screen display of information but still capture the error information in a file. The text string you assign for the file name is used literally, so you must specify the full name. If the file open fails, no error is reported and the run-time system continues diagnostic processing. See also Locating Run-Time Errors and Using Traceback Information Overview. |
|
FOR_DISABLE_DIAGNOSTIC_DISPLAY |
This variable disables the display of all error information. This variable is helpful if you just want to test the error status of your program and do not want the Fortran run-time system to display any information about an abnormal program termination. See also Using Traceback Information Overview. |
|
FOR_DISABLE_STACK_TRACE |
Specifies that the call stack trace information that typically follows the displayed severe error message text should be disabled. The Fortran run-time error message is displayed whether or not FOR_DISABLE_STACK_TRACE is set to true. If the program is executing under a debugger, the automatic output of the stack trace information by the Fortran library will be disabled to reduce noise. You should use the debugger's stack trace facility if you want to view the stack trace. See also Locating Run-Time Errors and Using Traceback Information Overview. |
|
FOR_IGNORE_EXCEPTIONS |
Specifies that default run-time exception handling, for example, to allow just-in-time debugging, should be disabled. The run-time system exception handler returns EXCEPTION_CONTINUE_SEARCH to the operating system, which looks for other handlers to service the exception. |
|
FOR_NOERROR_DIALOGS |
Specifies that the display of dialog boxes should be disabled when certain exceptions or errors occur. This is useful when running many test programs in batch mode to prevent a failure from stopping execution of the entire test stream. |
|
FOR_PRINT |
Neither the PRINT statement nor a WRITE statement with an asterisk (*) in place of a unit number includes an explicit logical unit number. Instead, both use an implicit internal logical unit number and the FOR_PRINT environment variable. If FOR_PRINT is not defined, the code PRINT f,iolist or WRITE (*,f) iolist writes to CONOUT$ (standard output). If FOR_PRINT is defined (as a file name optionally containing a path), the specified file would be written to. |
|
FOR_READ |
A READ statement that uses an asterisk (*) in place of a unit number does not include an explicit logical unit number. Instead, it uses an implicit internal logical unit number and the FOR_READ environment variable. If FOR_READ is not defined, the code READ (*,f) iolist or READ f,iolist reads from CONIN$ (standard input). If FOR_READ is defined (as a file name optionally containing a path), the specified file would be read. |
|
FOR_TYPE |
The TYPE statement does not include an explicit logical unit number. Instead, it uses an implicit internal logical unit number and the FOR_TYPE environment variable. If FOR_TYPE is not defined, the code TYPE f,iolist writes to CONOUT$ (standard output). If FOR_TYPE is defined (as a file name optionally containing a path), the specified file would be written to. |
|
FORT_BLOCKSIZE |
Specifies the default BLOCKSIZE value to be used when BLOCKSIZE= is omitted on the OPEN statement. Valid values are 0 to 2147467264. Sizes are rounded up to the next 512-byte boundary. |
|
FORT_BUFFERCOUNT |
Specifies the default BUFFERCOUNTvalue to be used when BUFFERCOUNT= is omitted on the OPEN statement. Valid values are 0 to 127. If 0 is specified, the default value of 1 will be used. |
|
FORT_BUFFERED |
Specifies that buffered I/O should be used at run time for output of all Fortran I/O units, except those with output to the terminal. This provides a run-time mechanism to support the -assume buffered_io (Linux OS and OS X) or /assume:buffered_io (Windows OS) compiler option. |
|
FORT_CONVERTn |
Specifies the data format for an unformatted file associated with a particular unit number (n), as described in Methods of Specifying the Data Format. |
|
FORT_CONVERT.ext and FORT_CONVERT_ext |
Specifies the data format for unformatted files with a particular file extension suffix (ext), as described in Methods of Specifying the Data Format. |
|
FORT_FMT_RECL |
Specifies the default record length (normally 132 bytes) for formatted files. |
|
FORT_UFMT_RECL |
Specifies the default record length (normally 2040 bytes) for unformatted files. |
|
FORTn |
Specifies the file name for a particular unit number n, when a file name is not specified in the OPEN statement or an implicit OPEN is used, and the compiler option -fpscomp filesfromcmd (Linux OS and OS X) or /fpscomp:filesfromcmd (Windows OS) was not specified. Preconnected files attached to units 0, 5, and 6 are by default associated with system standard I/O files. |
|
NLSPATH (Linux OS and OS X only) |
Specifies the path for the Intel Fortran run-time error message catalog. |
|
TBK_ENABLE_VERBOSE_STACK_TRACE |
Displays more detailed call stack information in the event of an error. The default brief output is usually sufficient to determine where an error occurred. Brief output includes up to twenty stack frames, reported one line per stack frame. For each frame, the image name containing the PC, routine name, line number, and source file are given. The verbose output, if selected, will provide (in addition to the information in brief output) the exception context record if the error was a machine exception (machine register dump), and for each frame, the return address, frame pointer and stack pointer and possible parameters to the routine. This output can be quite long (but limited to 16K bytes) and use of the environment variable FOR_DIAGNOSTIC_LOG_FILE is recommended if you want to capture the output accurately. Most situations should not require the use of verbose output. The variable FOR_ENABLE_VERBOSE_STACK_TRACE is also recognized for compatibility with Compaq* Visual Fortran. See also Using Traceback Information Overview. |
|
TBK_FULL_SRC_FILE_SPEC |
By default, the traceback output displays only the file name and extension in the source file field. To display complete file name information including the path, set the environment variable TBK_FULL_SRC_FILE_SPEC to true. The variable FOR_FULL_SRC_FILE_SPEC is also recognized for compatibility with Compaq* Visual Fortran. See also Using Traceback Information Overview. |
|
FORT_TMPDIR, TMP, TMPDIR, and TEMP |
Specifies an alternate working directory where scratch files are created. |
| GNU extensions (recognized by the Intel® OpenMP compatibility library) | |
|
GOMP_STACKSIZE |
GNU extension recognized by the Intel OpenMP compatibility library. Same as OMP_STACKSIZE. KMP_STACKSIZE overrides GOMP_STACKSIZE, which overrides OMP_STACKSIZE. Default: See OMP_STACKSIZE description |
|
GOMP_CPU_AFFINITY (Linux OS and Mac OS X only) |
GNU extension recognized by the Intel OpenMP compatibility library. Specifies a list of OS processor IDs. Default: Affinity is disabled |
|
OpenMP* Environment Variables (OMP_) and Extensions (KMP_) |
|
|
OMP_DYNAMIC |
Enables (.TRUE.) or disables (.FALSE.) the dynamic adjustment of the number of threads. Default: .FALSE. Syntax: export OMP_DYNAMIC=value |
|
OMP_MAX_ACTIVE_LEVELS |
The maximum number of levels of parallel nesting for the program. Default: 1 Syntax: export OMP_MAX_ACTIVE_LEVEL=value |
|
OMP_NESTED |
Enables (.TRUE.) or disables (.FALSE.)nested parallelism. Default: .FALSE. Syntax: export OMP_NESTED=value |
|
OMP_NUM_THREADS |
Sets the maximum number of threads to use for OpenMP* parallel regions if no other value is specified in the application. The value can be a single integer, in which case it specifies the number of threads for all parallel regions. Or it can be a comma-separated list of integers, in which case each integer specifies the number of threads for a parallel region at a nesting level. The first position in the list represents the outer-most parallel nesting level, the second position represents the next-inner parallel nesting level, and so on. At any level, the integer can be left out of the list. If the first integer in a list is left out, it implies the normal default value for threads is used at the outer-most level. If the integer is left out of any other level, the number of threads for that level is inherited from the previous level. This environment variable applies to both -openmp and -parallel options. Default: Number of processors visible to the operating system. Syntax: export OMP_NUM_THREADS=value[,value]* |
|
OMP_PROC_BIND |
Enables (true) or disables (false) the binding of threads to processor contexts. If enabled, this is the same as specifying KMP_AFFINITY=scatter. If disabled, this is the same as specifying KMP_AFFINITY=none. If both OMP_PROC_BIND and KMP_AFFINITY are specified, KMP_AFFINITY settings take precedence. GOMP_CPU_AFFINITY also takes precedence over OMP_PROC_BIND. Default: false |
|
OMP_SCHEDULE |
Sets the run-time schedule type and an optional chunk size. Default: STATIC, no chunk size specified Syntax: export OMP_SCHEDULE="kind[,chunk_size]" This environment variable is available for both Intel® and non-Intel microprocessors but it may perform additional optimizations for Intel microprocessors than it performs for non-Intel microprocessors. |
|
OMP_STACKSIZE |
Sets the number of bytes to allocate for each OpenMP thread to use as the private stack for the thread. Recommended size is 16M. Use the optional suffixes: B (bytes), K (Kilobytes), M (Megabytes), G (Gigabytes), or T (Terabytes) to specify the units. If only value is specified and B, K, M, G, or T is not specified, then size is assumed to be K (Kilobytes). This variable does not affect the native operating system threads created by the user program nor the thread executing the sequential part of an OpenMP program or parallel programs created using the-parallel option. The kmp_{set,get}_stacksize_s() routines set/retrieve the value. The kmp_set_stacksize_s() routine must be called from sequential part, before first parallel region is created. Otherwise, calling kmp_set_stacksize_s() has no effect. Default for IA-32 architecture: 2M Syntax: export OMP_STACKSIZE=value Related environment variables: KMP_STACKSIZE. KMP_STACKSIZE overrides OMP_STACKSIZE. |
|
OMP_THREAD_LIMIT |
Limits the number of simultaneously executing threads in an OpenMP* program. If this limit is reached and another native operating system thread encounters OpenMP* API calls or constructs, the program can abort with an error message. If this limit is reached when an OpenMP parallel region begins, a one-time warning message might be generated indicating that the number of threads in the team was reduced, but the program will continue. This environment variable is only used for programs compiled with the -openmp or -parallel options. The omp_get_thread_limit() routine returns the value of the limit. Default: No enforced limit Syntax: export OMP_THREAD_LIMIT=value Related environment variable: KMP_ALL_THREADS. Its value overrides OMP_THREAD_LIMIT. |
|
OMP_WAIT_POLICY |
Decides whether threads spin (active) or yield (passive) while they are waiting. OMP_WAIT_POLICY=ACTIVE is an alias for KMP_LIBRARY=turnaround, and OMP_WAIT_POLICY=PASSIVE is an alias for KMP_LIBRARY=throughtput. Default: Passive Syntax: export OMP_WAIT_POLICY=value |
|
KMP_AFFINITY |
Enables run-time library to bind threads to physical processing units. Default: none This environment variable is available for both Intel® and non-Intel microprocessors but it may perform additional optimizations for Intel microprocessors than it performs for non-Intel microprocessors. |
|
KMP_ALL_THREADS |
Limits the number of simultaneously executing threads in an OpenMP* program. If this limit is reached and another native operating system thread encounters OpenMP* API calls or constructs, then the program may abort with an error message. If this limit is reached at the time an OpenMP parallel region begins, a one-time warning message may be generated indicating that the number of threads in the team was reduced, but the program will continue execution. This environment variable is only used for programs compiled with -openmp or -openmp-profile. Default: No enforced limit |
|
KMP_BLOCKTIME |
Sets the time, in milliseconds, that a thread should wait, after completing the execution of a parallel region, before sleeping. Use the optional character suffixes: s (seconds), m (minutes), h (hours), or d (days) to specify the units. Default: 200 milliseconds |
|
KMP_CPUINFO_FILE |
Specifies an alternate file name for file containing machine topology description. The file must be in the same format as /proc/cpuinfo. Default: None This environment variable is available for both Intel® and non-Intel microprocessors but it may perform additional optimizations for Intel microprocessors than it performs for non-Intel microprocessors. |
|
KMP_DETERMINISTIC_REDUCTIONS |
Enables (1) or disables (0) the use of a specific ordering of the reduction operations for implementing the reduction clause for an OpenMP* parallel region. This has the effect that, for a given number of threads, in a given parallel region, for a given data set and reduction operation, a floating point reduction done for an OpenMP reduction clause will have a consistent floating point result from run to run, since round-off errors will be identical. Default:0 |
|
KMP_DYNAMIC_MODE |
Selects the method used to determine the number of threads to use for a parallel region when OMP_DYNAMIC=true. Possible values: (asat | load_balance | thread_limit), where,
Default for IA-32 architecture: load_balance (on all supported OSes) Default for Intel® MIC architecture: thread_limit (on supported OSes) |
|
KMP_INHERIT_FP_CONTROL |
Enables (1) or disables (0) the copying of the floating point control settings of the master thread to the floating point control settings of the OpenMP* worker threads at the start of each parallel region. Default: 1 |
|
KMP_LIBRARY |
Selects the OpenMP run-time library execution mode. The values for this variable are serial, turnaround, or throughput. Default: throughput |
|
KMP_MONITOR_STACKSIZE |
Sets the number of bytes to allocate for the monitor thread, which is used for book-keeping during program execution. Use the optional suffixes: b (bytes), k (kilobytes), m (megabytes), g (gigabytes), or t (terabytes) to specify the units. Default: max (32k, system minimum thread stack size) |
|
KMP_SETTINGS |
Enables (1) or disables (0) the printing of OpenMP run-time library environment variables during program execution. Two lists of variables are printed: user-defined environment variables settings and effective values of variables used by OpenMP run-time library. Default: 0 |
|
KMP_STACKSIZE |
Sets the number of bytes to allocate for each OpenMP* thread to use as its private stack. Recommended size is 16m. Use the optional suffix b, k, m, g, or t, to specify bytes, kilobytes, megabytes, gigabytes, or terabytes.This variable does not affect the native operating system threads created by the user program nor the thread executing the sequential part of an OpenMP* program or parallel programs created using -parallel option. Default: IA-32 architecture: 2m, Intel® 64 architecture: 4m,. |
|
KMP_VERSION |
Enables (1) or disables (0) the printing of OpenMP* run-time library version information during program execution. Default: 0 |
| PGO Environment Variables | |
|
INTEL_PROF_DUMP_CUMULATIVE |
When using interval profile dumping (initiated by INTEL_PROF_DUMP_INTERVAL or the function _PGOPTI_Set_Interval_Prof_Dump) during the execution of an instrumented user application, allows creation of a single .dyn file to contain profiling information instead of multiple .dyn files. If this environment variable is not set, executing an instrumented user application creates a new .dyn file for each interval. Setting this environment variable is useful for applications that do not terminate or those that terminate abnormally (bypass the normal exit code). |
|
INTEL_PROF_DUMP_INTERVAL |
Initiates interval profile dumping in an instrumented user application. This environment variable may be used to initiate Interval Profile Dumping in an instrumented application. See Interval Profile Dumping for more information. |
|
PROF_DIR |
Specifies the directory in which dynamic information files are created. This variable applies to all three phases of the profiling process. |
|
PROF_DUMP_INTERVAL |
Deprecated; use INTEL_PROF_DUMP_INTERVAL instead. |
|
PROF_NO_CLOBBER |
Alters the feedback compilation phase slightly. By default, during the feedback compilation phase, the compiler merges data from all dynamic information files and creates a new pgopti.dpi file if the .dyn files are newer than an existing pgopti.dpi file. When this variable is set the compiler does not overwrite the existing pgopti.dpi file. Instead, the compiler issues a warning. You must remove the pgopti.dpi file if you want to use additional dynamic information files. |
| Intel® MIC Architecture Environment Variables | |
|
MIC_ENV_PREFIX |
Used to control environment variables passed to the coprocessor. By default, all environment variables set on the host are passed to the coprocessor. Setting MIC_ENV_PREFIX passes only environment variables that have a prefix of the value of this variable. For example, setting setenv MIC_ENV_PREFIX=MIC passes only environment variables that have a prefix of MIC.
NoteThe MIC_LD_LIBRARY_PATH variable is not stripped and passed to the coprocessor, so you cannot use MIC_ENV_PREFIX=MIC to change the LD_LIBRARY_PATH on the coprocessor. For information on passing environment variables to a particular coprocessor, and on passing multiple environment variables to one or all coprocessors, see Setting Environment Variables on the CPU to Modify the Coprocessor's Execution Environment. |
|
MIC_HOST_LOG |
A string containing the file name to output traces from the host. Default: None Example: MIC_HOST_LOG=/home/user/app/host.log |
|
MIC_LD_LIBRARY_PATH |
Specifies the location for target shared objects. LD_LIBRARY_PATH specifies the location for host objects. |
|
MIC_PROXY_IO |
Enables (1) or disables (0) the proxy of stderr and stdout, and specifies whether the process wants I/O proxy support between the host and coprocessor. Default: 1 Example: MIC_PROXY_IO=0 |
|
MIC_SEP_MONITOR |
Enables (1) or disables (0) SEP at offload regions. Default: 0 Example: MIC_SEP_MONITOR=1 |
|
MIC_STACKSIZE |
Specifies the stack size of the main thread for the offload. This value is typically much larger than the stack size for individual threads. It corresponds to what you would set with ulimit -s (BASH shell) or limit stacksize (C shell) if you were running natively on either the coprocessor or the host. Set this variable to integerB|K|M|G|T, where:
Default: 12M Example: MIC_STACKSIZE=16M |
|
OFFLOAD_DEVICES |
Restricts the offload process to use only the coprocessors specified as the value of the variable. Set this variable to a comma separated list of coprocessor device numbers in the range 0 to number_of_devices_in_the_system-1, where 0 is the first coprocessor in the system, and number_of_devices_in_the_system-1 is the last coprocessor in the system. Coprocessors available for offloading are numbered logically. The function OFFLOAD_NUMBER_OF_DEVICES returns the number of available coprocessors. Coprocessor indices that you use in the target specifier of the offload directives are in the range 0 to number_of_devices_in_the_system-1. Default: The offload process uses all devices. Example: OFFLOAD_DEVICES = 1,2 On a system with more than two coprocessors installed, this setting enables the application to use only coprocessors 1 and 2. Offloads to coprocessors 0 or 1 are performed on the first and second physical coprocessors. Offloads to target numbers higher than 1 wrap-around so that all offloads remain within coprocessors 0 and 1. The function OFFLOAD_NUMBER_OF_DEVICES executed on a coprocessor return 0 or 1, when the offload is running on the first or second coprocessor. |
|
OFFLOAD_INIT |
Specifies a hint to the offload runtime when to initialize coprocessors.
Default: on_offload_all Example: OFFLOAD_INIT=on_start |
|
OFFLOAD_REPORT |
Controls printing offload execution time, in seconds, and the amount of data transferred, in bytes. This environment variable is equivalent to using the __Offload_report API.
Default: None Example: OFFLOAD_REPORT=1 See also __Offload_report. |