Selects different strategies for speeding up or improving the accuracy of floating-point calculations.
.-:----------------. | .-nostrictnmaf-. | | +-single-------+ | | +-norsqrt------+ | | +-norrm--------+ | | +-rngchk-------+ | | +-rndsngl------+ | | +-nonans-------+ | | +-maf----------+ | | +-nohssngl-----+ | | +-nohsflt------+ | | +-nohscmplx----+ | | +-fold---------+ | | +-nofltint-----+ | V +-nofenv-------+ | >>- -q--float--=----+-fenv---------+-+------------------------->< +-fltint-------+ +-nofold-------+ +-hscmplx------+ +-hsflt--------+ +-hssngl-------+ +-nomaf--------+ +-nans---------+ +-norndsngl----+ +-norngchk-----+ +-rrm----------+ +-rsqrt--------+ +-nosingle-----+ '-strictnmaf---'
@PROCESS:
@PROCESS FLOAT(suboptions)
maf:nonans:rndsngl:rngchk:norrm:norsqrt:single:nostrictnmaf
Certain floating-point operations rely on the status of Floating-Point Status and Control Register (FPSCR), for example, to control the rounding mode or to detect underflow. In particular, many compiler built-in functions read values directly from the FPSCR.
When nofenv is in effect, the compiler assumes that the program does not depend on the hardware environment, and that aggressive compiler optimizations that change the sequence of floating-point operations are allowed. When fenv is in effect, such optimizations are suppressed.
You should use fenv for any code containing statements that read or set the hardware floating-point environment, to guard against optimizations that could cause unexpected behavior.
The Fortran language does not require checking for floating-point values outside the representable range of integers. In order to improve efficiency, the inline sequence used by -qfloat=fltint does not perform this check. If passed a value that is out of range, the inline sequence will produce undefined results.
If -qarch is set to a processor that has an instruction to convert from floating point to integer, that instruction will be used regardless of the [no]fltint setting. This conversion also applies to all Power® processors in 64-bit mode.
If you compile with the -O3 or higher optimization level, fltint is enabled automatically. To disable it, also specify -qstrict, -qstrict=operationprecision, or -qstrict=exceptions.
The -qfloat=[no]fold option replaces the deprecated -q[no]fold option. Use -qfloat=[no]fold in your new applications.
The hsflt suboption overrides the nans and spnans suboptions.
Specifies that single-precision expressions are rounded only when the results are stored into memory locations, but not after expression evaluation. Using hssngl can improve runtime performance and is safer than using hsflt.
This option only affects double-precision expressions being assigned to a single-precision, in which a store instruction is generated, when -qfloat=nosingle is in effect. Do not use this option if you are compiling with the default -qfloat=single.
The -qfloat=[no]maf option replaces the deprecated -q[no]maf option. Use -qfloat=[no]maf in your new applications.
The hsflt option overrides the nans option.
The -qfloat=[no]nans option replaces the deprecated -qfloat=[no]spnans option and the -q[no]spnans option. Use -qfloat=[no]nans in your new applications.
This option only affects double-precision expressions cast to single-precision. You can only specify norndsngl when -qfloat=nosingle is in effect.
The hsflt suboption overrides the rndsngl option.
norngchk is only allowed when -qnostrict is in effect. If -qstrict, -qstrict=infinities, -qstrict=operationprecision, or -qstrict=exceptions is in effect, norngchk is ignored.
The -qfloat=[no]rrm option replaces the deprecated -q[no]rrm option. Use -qfloat=[no]rrm in your new applications.
If you compile with the -O3 or higher optimization level, rsqrt is enabled automatically. To disable it, also specify -qstrict, -qstrict=nans, -qstrict=infinities, -qstrict=zerosigns, or -qstrict=exceptions.
To ensure strict semantics, specify both -qstrict and -qfloat=strictnmaf.
Using -qfloat suboptions other than the default settings may produce incorrect results in floating-point computations if not all required conditions for a given suboption are met. For this reason, you should only use this option if you are experienced with floating-point calculations involving IEEE floating-point values and can properly assess the possibility of introducing errors in your program. See also Implementation details of XL Fortran floating-point processing for more information.
If the -qstrict | -qnostrict and float suboptions conflict, the last setting specified is used.
xlf myprogram.f -qfloat=fold:nomaf