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]

optimization/7122: -o2 processed floating point code generates bogus NaN


>Number:         7122
>Category:       optimization
>Synopsis:       -o2 processed floating point code generates bogus NaN
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jun 25 10:46:01 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     hanelyp@calweb.com
>Release:        gcc 2.96 20000731 (redhat linux 7.1 2.96-98)
>Organization:
>Environment:
redhat linux 7.2
cygwin
>Description:
compiling with -o2 produces bogus floating point NaN. Same generated code may work right sometimes and not others.  Libraries (presumably built with this option) are affected, including atof(), sin(), cos()

call to printf() appears to patch bug in some cases.
>How-To-Repeat:
bug encountered developing http://www.calweb.com/~hanelyp/treecad/
>Fix:
As an interum, avoiding this optomization with floating point code.
>Release-Note:
>Audit-Trail:
>Unformatted:


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