From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,5cc99ba8cc92b94d X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 1995-02-24 09:49:10 PST Path: nntp.gmd.de!stern.fokus.gmd.de!gmdtub!cs.tu-berlin.de!fu-berlin.de!news.dfn.de!Germany.EU.net!howland.reston.ans.net!news.sprintlink.net!uunet!in1.uu.net!hearye.mlb.semi.harris.com!jabba.ess.harris.com!usenet From: azimmer@rsa.hisd.harris.com (Alan D Zimmerman) Newsgroups: comp.lang.ada Subject: Re: Rational/Verdix Number Bug Message-ID: <3il66m$ps1@jabba.ess.harris.com> Date: 24 Feb 95 17:49:10 GMT References: <3i0nip$b55@rational.rational.com> Reply-To: azimmer@rsa.hisd.harris.com Organization: Loral Space & Range Systems NNTP-Posting-Host: appsrv2.rsa.hisd.harris.com Date: 1995-02-24T17:49:10+00:00 List-Id: In article <3i0nip$b55@rational.rational.com>, kdm@rational.com (Kent Mitchell) writes: > Roger C Hennesen (rch@odo.amherst.com) wrote: > : We have discovered that the number 2147.483648 is not handled properly by the > : Sun/Rational/Verdix Ada compiler. Multiplying or dividing by this number > : results in a sign inversion in the result. > > : The position of the decimal point does not matter. The number is 2^31. Also > : numbers around this number (e.g. +/- 0.000003) exhibit strange results in > : floating point calculations. > > : The problem was discovered in SunAda version 2.1.1 and duplicated with the SCO > : Verdix Compiler version 6.2.1. > > : Rational was notified of the problem, but has not responded. > > O.K. I'll respond here since I'm concerned about both the bug *and* the > statement that we didn't respond. > First WRT the "no response" issue, hHow did you report the bug (phone, > e-mail, or?). Did you get *no* response (not even a customer support "log" > number or automated e-mail response) or ???. > > Second WRT the bug, do you have a minimum faulty program which reproduces > the problem? If so mail it to me so I can take a look at is and reproduce > the problem internally. I'll see if I can't grease the skids a bit. > > -- > Kent Mitchell | One possible reason that things aren't > Technical Consultant | going according to plan is ..... > Rational Software Corporation | that there never *was* a plan! Well, I am in a perplexing situation. I tried this when I first heard about the problem and duplicated it with a program like the one attached. I just tried it and I could not duplicate it. I am running SunAda 1.1(j) on a SPARC LX. Below is the test program. with text_io; procedure test_float is test : float := 2147.486348; package flt_io is new text_io.float_io(float); begin flt_io.put(test); text_io.new_line; flt_io.put(test * 2.0); text_io.new_line; flt_io.put(test / 2.0); end test_float; Here are my results: 2.14748634800000E+03 4.29497269600000E+03 1.07374317400000E+03 Alan -- | Alan D. Zimmerman | Eagle Scout | | azimmer@rsa.hisd.harris.com | Scoutmaster T324 | |-------------------------------------------------------------------| | All opinions are solely my own and do not represent Loral | | On My Honor I will do my best... |