Fortran · Exception
What does Denormal Operand Trap (-ffpe-trap=denormal) mean in Fortran?
A gfortran-specific trap condition — not one of the five IEEE_FLAG_TYPE constants in the IEEE_EXCEPTIONS module — that fires when an operation consumes or produces a subnormal (denormalized) floating-point value: a number smaller than the smallest normal value that still keeps some precision by giving up exponent range. It's a hardware-level x86 condition rather than a mandated IEEE 754 exception, so it isn't available on every architecture.
A gfortran-specific trap condition — not one of the five IEEE_FLAG_TYPE constants in the IEEE_EXCEPTIONS module — that fires when an operation consumes or produces a subnormal (denormalized) floating-point value: a number smaller than the smallest normal value that still keeps some precision by giving up exponent range. It's a hardware-level x86 condition rather than a mandated IEEE 754 exception, so it isn't available on every architecture.
Add 'denormal' to -ffpe-trap= only while investigating unexplained slowdowns or precision loss traced to subnormal arithmetic; leave it out of normal production builds, since numerically valid code can legitimately produce denormals without being buggy.