public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "laurent at guerby dot net" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug ada/14988] New: Analysis of ACATS cxg2006 failures at -O1 Date: Fri, 16 Apr 2004 22:33:00 -0000 [thread overview] Message-ID: <20040416213806.14988.laurent@guerby.net> (raw) Various ACATS tests fail when compiled with optimizations, including cxg2006. It looks like the problem comes from Long_Long_Float handling, First LLF comes into play because System.Max_Digits is 18 on x86. A reduced test case follows, it looks like a simple aggregate used to represent long long complex numbers fails to be initialized properly at -O1. Interestingly the failure occurs only when using the standard package, and not when trying to do things by hand (you can try to uncomment GP+CP or the direct Complex type declation and both works fine). I also find the warning about "internal GNAT unit" suspicious, so may be something is simply wrong with some generic handling in the front-end. $ gnatmake -O1 p.adb gcc -c -O1 p.adb p.adb:1:18: warning: "Ada.Numerics.Long_Long_Complex_Types" is an internal GNAT unit p.adb:1:18: warning: use of this unit is non-portable and version-dependent gnatbind -x p.ali gnatlink p.ali [guerby@pc gcc]$ ./p raised PROGRAM_ERROR : p.adb:33 explicit raise [guerby@pc gcc]$ cat p.adb with Ada.Numerics.Long_Long_Complex_Types; use Ada.Numerics.Long_Long_Complex_Types; procedure P is -- generic -- type Real is digits <>; -- package GP is -- type Complex is record -- Re, Im : Real'Base; -- end record; -- end GP; -- package CP is new GP (Long_Long_Float); -- use CP; -- type Complex is record -- Re, Im : Long_Long_Float; -- end record; function My_Argument (X : Complex) return Long_Long_Float is begin if X.Im = 0.0 then return 0.0; else return 1.0; end if; end My_Argument; Z : Complex := (0.0, 0.0); X : Long_Long_Float; procedure Oops is begin raise Program_Error; end Oops; begin X := My_Argument (Z); if X /= 0.0 then Oops; end if; end P; -- Summary: Analysis of ACATS cxg2006 failures at -O1 Product: gcc Version: 3.5.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: ada AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: laurent at guerby dot net CC: gcc-bugs at gcc dot gnu dot org,laurent at guerby dot net GCC build triplet: i686-pc-linux-gnu GCC host triplet: i686-pc-linux-gnu GCC target triplet: i686-pc-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14988
next reply other threads:[~2004-04-16 21:38 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2004-04-16 22:33 laurent at guerby dot net [this message] 2004-04-17 0:16 ` [Bug ada/14988] " laurent at guerby dot net 2004-04-17 14:46 ` cvs-commit at gcc dot gnu dot org 2004-04-17 15:18 ` pinskia at gcc dot gnu dot org 2004-04-17 16:05 ` laurent at guerby dot net 2004-04-17 16:08 ` pinskia at gcc dot gnu dot org 2004-04-19 15:20 ` pinskia at gcc dot gnu dot org 2004-04-21 17:38 ` ebotcazou at gcc dot gnu dot org 2004-04-22 9:19 ` [Bug middle-end/14988] " ebotcazou at gcc dot gnu dot org 2004-05-02 13:46 ` cvs-commit at gcc dot gnu dot org 2004-05-02 13:48 ` ebotcazou at gcc dot gnu dot org
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=20040416213806.14988.laurent@guerby.net \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@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: linkBe 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).