public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ada/12052] New: ada program fails to print floatingpoint numbers
@ 2003-08-25 12:45 olle at cb dot uu dot se
  2003-08-27 14:06 ` [Bug ada/12052] " pinskia at gcc dot gnu dot org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: olle at cb dot uu dot se @ 2003-08-25 12:45 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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

           Summary: ada program fails to print floatingpoint numbers
           Product: gcc
           Version: 3.3.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: ada
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: olle at cb dot uu dot se
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: def-alpha-osf5.1
  GCC host triplet: dec-alpha-osf5.1
GCC target triplet: dec-alpha-osf5.1

When running the attached ada-program, it fails to print the floating point values.

This is 3.3.1 usingHP Tru64 UNIX 5.1B

It was bootstrapped using gnat 3.14p.

setenv ADAC /usr/local/gnat-3.14/bin/gcc
../gcc-3.3.1/configure --enable-libgcj alpha-dec-osf5.1


The program runs OK compiled with gnat-3.14p

> cat print_roots.adb
With TEXT_IO,ADA,ADA.NUMERICS.GENERIC_ELEMENTARY_FUNCTIONS;
Procedure Print_roots is
   use Text_IO,ADA;
   Package Math is new NUMERICS.GENERIC_ELEMENTARY_FUNCTIONS(Long_Float);
   Package Flt_IO is new Float_IO(Long_Float);
   use Flt_IO,Math;
   R,X : Long_Float;
begin
   X := 2.0;
   Put("Roots of various numbers ");
   Put(X,5,2);
   New_line(2);
   Loop
      Begin
         Get(X);
         Exit When X = 0.0;
         R := Sqrt(X);
         Put("Root of ");
         Put(X);
         Put(" is ");
         Put(R);
         New_Line;
      Exception
         When Data_Error => Put("Data Error");New_Line;skip_line;
      End;
   End Loop;
   New_line;
   Put("Program finished");
   New_Line;
End Print_Roots;

> gcc -v
Reading specs from /usr/local/lib/gcc-lib/alpha-dec-osf5.1/3.3.1/specs
Configured with: ../gcc-3.3.1/configure --enable-libgcj alpha-dec-osf5.1
Thread model: single
gcc version 3.3.1

> gnat make print_roots.adb
gcc -c print_roots.adb
gnatbind -x print_roots.ali
gnatlink print_roots.ali
> print_roots
Roots of various numbers    -0.00E+00

5
Root of -0.00000000000000E+00 is -0.00000000000000E+00
4
Root of -0.00000000000000E+00 is -0.00000000000000E+00
0

Program finished

--------------------------
Trying gnat 3.14p instead
--------------------------

> set path=(/usr/local/gnat-3.14/bin $path)
> gnat make print_roots.adb
gcc -c print_roots.adb
gnatbind -x print_roots.ali
gnatlink print_roots.ali
> print_roots
Roots of various numbers     2.00E+00

4
Root of  4.00000000000000E+00 is  2.00000000000000E+00
5
Root of  5.00000000000000E+00 is  2.23606797749979E+00
0

Program finished
> exit
> exit

Process shell finished


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug ada/12052] ada program fails to print floatingpoint numbers
  2003-08-25 12:45 [Bug ada/12052] New: ada program fails to print floatingpoint numbers olle at cb dot uu dot se
@ 2003-08-27 14:06 ` pinskia at gcc dot gnu dot org
  2003-10-22  9:08 ` charlet at gcc dot gnu dot org
  2004-04-24 13:46 ` olle at cb dot uu dot se
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-27 14:06 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From pinskia at gcc dot gnu dot org  2003-08-27 14:05 -------
This works for me on powerpc-apple-darwin6.6 on the mainline (20030731).


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug ada/12052] ada program fails to print floatingpoint numbers
  2003-08-25 12:45 [Bug ada/12052] New: ada program fails to print floatingpoint numbers olle at cb dot uu dot se
  2003-08-27 14:06 ` [Bug ada/12052] " pinskia at gcc dot gnu dot org
@ 2003-10-22  9:08 ` charlet at gcc dot gnu dot org
  2004-04-24 13:46 ` olle at cb dot uu dot se
  2 siblings, 0 replies; 4+ messages in thread
From: charlet at gcc dot gnu dot org @ 2003-10-22  9:08 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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


charlet at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |3.4


------- Additional Comments From charlet at gcc dot gnu dot org  2003-10-22 09:01 -------
Works for me too on x86-linux.
I can't test on Tru64, but believe this is now fixed.

Feel free to reopen if not.

Arno


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug ada/12052] ada program fails to print floatingpoint numbers
  2003-08-25 12:45 [Bug ada/12052] New: ada program fails to print floatingpoint numbers olle at cb dot uu dot se
  2003-08-27 14:06 ` [Bug ada/12052] " pinskia at gcc dot gnu dot org
  2003-10-22  9:08 ` charlet at gcc dot gnu dot org
@ 2004-04-24 13:46 ` olle at cb dot uu dot se
  2 siblings, 0 replies; 4+ messages in thread
From: olle at cb dot uu dot se @ 2004-04-24 13:46 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From olle at cb dot uu dot se  2004-04-24 13:20 -------

Works OK on 3.4.0

-- 


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


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-04-24 13:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-25 12:45 [Bug ada/12052] New: ada program fails to print floatingpoint numbers olle at cb dot uu dot se
2003-08-27 14:06 ` [Bug ada/12052] " pinskia at gcc dot gnu dot org
2003-10-22  9:08 ` charlet at gcc dot gnu dot org
2004-04-24 13:46 ` olle at cb dot uu dot se

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).