This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/47989] New: -mrecip causes 482.sphinx3 to miscompare


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

           Summary: -mrecip causes 482.sphinx3 to miscompare
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: target
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: rguenth@gcc.gnu.org
            Target: x86_64-*-*


We currently miscompare 482.sphinx3 with -Ofast -mrecip because for

float foo (float x, float y)
{    
  return ((int)(x/y + 0.5)) * y;
} 

we use rcpss for the division by y.  This results in a possible error
of +-1 for the integer intermediate result and an error of +-y for
the overall result.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]