http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60779

            Bug ID: 60779
           Summary: -fcx-fortran-rules ignored when using -flto
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dturnbull at gmail dot com

Using the following test code on g++-4.9 (GCC) 4.9.0 20140330

if (isnan((complex<float>(1,0) / complex<float>(0,0)).real())) {
    cout << "Fortran rules: \n";
} else {
    cout << "ISO rules: \n";
}

The -fcx-fortran-rules option behaves as expected. The test code indicates
Fortran rules are being used and performance indicates the NaN checking is
indeed disabled.

When enabling both -fcx-fortran-rules and -flto the test code indicates ISO
rules are being used and performance is identical to compiling without
-fcx-fortran-rules.

This happens in both the C and C++ compilers.

Reply via email to