public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "anlauf at gmx dot de" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/42809] Too much noise with -Wconversion Date: Thu, 21 Jan 2010 21:12:00 -0000 [thread overview] Message-ID: <20100121211156.705.qmail@sourceware.org> (raw) In-Reply-To: <bug-42809-6318@http.gcc.gnu.org/bugzilla/> ------- Comment #4 from anlauf at gmx dot de 2010-01-21 21:11 ------- Created an attachment (id=19684) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19684&action=view) Slightly improved version of the previous patch I have improved the patch so that now the following assignments do not throw a warning: e.g. real(4) <- integer(1,2) real(8) <- integer(1,2,4) dto. for complex on the l.h.s. This assumes the standard IEEE representations of reals which have a sufficiently large number of mantissa bits to accomodate the converted value from the integer of smaller kind. It works for me, up to the cases where the converted value is known to be an integer exactly representable as a real with the desired kind, see my comment above. The patch works apparently correctly with -fdefault-real-8 and -fdefault-integer-8 (ugh!). I have regtested the patch and found a probably unrelated failure: FAIL: gfortran.dg/vect/fast-math-mgrid-resid.f scan-tree-dump-times optimized "vect_var[^\n]*\+ " 13 The patch is just at the limit of 10 lines, so whoever wants to take it feel free to do so. I have left only the work to provide a testcase for the testsuite. ;-) Enjoy. -- anlauf at gmx dot de changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #19669|0 |1 is obsolete| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42809
next prev parent reply other threads:[~2010-01-21 21:12 UTC|newest] Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top 2010-01-19 22:39 [Bug fortran/42809] New: " anlauf at gmx dot de 2010-01-19 22:42 ` [Bug fortran/42809] " pinskia at gcc dot gnu dot org 2010-01-19 22:59 ` anlauf at gmx dot de 2010-01-20 23:02 ` anlauf at gmx dot de 2010-01-21 21:12 ` anlauf at gmx dot de [this message] 2010-01-22 20:43 ` anlauf at gmx dot de 2010-05-08 17:29 ` dfranke at gcc dot gnu dot org 2010-05-10 17:12 ` dfranke at gcc dot gnu dot org 2010-05-10 19:26 ` dfranke 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=20100121211156.705.qmail@sourceware.org \ --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).