public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/18784] New: Floating point calculation inconsistent within program with -O2
@ 2004-12-02 14:19 Graham dot Murphy at jhuapl dot edu
2004-12-02 14:21 ` [Bug c/18784] " Graham dot Murphy at jhuapl dot edu
2004-12-02 14:22 ` pinskia at gcc dot gnu dot org
0 siblings, 2 replies; 3+ messages in thread
From: Graham dot Murphy at jhuapl dot edu @ 2004-12-02 14:19 UTC (permalink / raw)
To: gcc-bugs
Attached (hopefully) is a C program that performs a simple
floating point calculation that produces a number very close
to an integer. When this calculation is done twice within
the same program, two different answers are produced if
there is an intervening print statement and -O2 or greater
optimization.
Problem appears with gcc 2.9 through 3.4.2 and Pentiums 1 - 4.
Not seen on AMD or Sparcs.
I have examined the FPU IEEE rounding control bits but see no
difference between the two sections.
--
Summary: Floating point calculation inconsistent within program
with -O2
Product: gcc
Version: 3.3.3
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: Graham dot Murphy at jhuapl dot edu
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: i686-pc-linux
GCC host triplet: i686-pc-linux
GCC target triplet: i686-pc-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18784
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c/18784] Floating point calculation inconsistent within program with -O2
2004-12-02 14:19 [Bug c/18784] New: Floating point calculation inconsistent within program with -O2 Graham dot Murphy at jhuapl dot edu
@ 2004-12-02 14:21 ` Graham dot Murphy at jhuapl dot edu
2004-12-02 14:22 ` pinskia at gcc dot gnu dot org
1 sibling, 0 replies; 3+ messages in thread
From: Graham dot Murphy at jhuapl dot edu @ 2004-12-02 14:21 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From Graham dot Murphy at jhuapl dot edu 2004-12-02 14:21 -------
Created an attachment (id=7656)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=7656&action=view)
.c, .i, .s, .o and x86 executeable.
Test suite.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18784
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c/18784] Floating point calculation inconsistent within program with -O2
2004-12-02 14:19 [Bug c/18784] New: Floating point calculation inconsistent within program with -O2 Graham dot Murphy at jhuapl dot edu
2004-12-02 14:21 ` [Bug c/18784] " Graham dot Murphy at jhuapl dot edu
@ 2004-12-02 14:22 ` pinskia at gcc dot gnu dot org
1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-12-02 14:22 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-12-02 14:21 -------
*** This bug has been marked as a duplicate of 323 ***
*** This bug has been marked as a duplicate of 323 ***
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |DUPLICATE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18784
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2004-12-02 14:22 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-12-02 14:19 [Bug c/18784] New: Floating point calculation inconsistent within program with -O2 Graham dot Murphy at jhuapl dot edu
2004-12-02 14:21 ` [Bug c/18784] " Graham dot Murphy at jhuapl dot edu
2004-12-02 14:22 ` pinskia at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).