public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: sjs@essex.ac.uk
To: gcc-gnats@gcc.gnu.org
Subject: ada/8925: Floating point code gives incorrect results
Date: Fri, 13 Dec 2002 05:16:00 -0000	[thread overview]
Message-ID: <20021213131502.23414.qmail@sources.redhat.com> (raw)


>Number:         8925
>Category:       ada
>Synopsis:       Floating point code gives incorrect results
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Dec 13 05:16:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Steve Sangwine, University of Essex, UK
>Release:        gcc 3.2
>Organization:
>Environment:
Windows 2000
MinGW 2.0.0-3
>Description:
The code attached contains a test program and part of a library of code which works correctly with Gnat 3.15p and
previous versions of Gnat. When compiled with gcc 3.2 this
code gives incorrect numerical results (integer values output are never changed from -infinity, as they should be).
>How-To-Repeat:
Compile the main program rgb_conversions_test.adb. NB I have
reported a fault with gnatchop, which on my system fails to chop the source code file which I have attached. Run the program rgb_conversions_test and at the prompts enter 180.0 for phase, 1.0 for saturation and 0.5 for intensity. The output that I get is shown in the file incorrect.txt. When compiled with Gnat 3.15p the same code gives the results shown in the file correct.txt.
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: text/plain; name="incorrect.txt"
Content-Disposition: inline; filename="incorrect.txt"

D:\Ada\Creake\Test>rgb_conversion_test
Enter phase:      180.0
Enter saturation: 1.0
Enter intensity:  0.5
Invalid_HSI_Coordinate raised
Raw values:           0-2147483648-2147483648
Enter phase:      ^C
D:\Ada\Creake\Test>


             reply	other threads:[~2002-12-13 13:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-13  5:16 sjs [this message]
2003-05-13  0:06 Dara Hazeghi
2003-05-13  6:33 steven

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20021213131502.23414.qmail@sources.redhat.com \
    --to=sjs@essex.ac.uk \
    --cc=gcc-gnats@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).