public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: bording@bnl.gov
To: gcc-gnats@gcc.gnu.org
Subject: fortran/10188: gcc test.c  or g77 test.f -malign-double
Date: Sat, 22 Mar 2003 00:56:00 -0000	[thread overview]
Message-ID: <20030322005428.28063.qmail@sources.redhat.com> (raw)


>Number:         10188
>Category:       fortran
>Synopsis:       gcc test.c  or g77 test.f -malign-double
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Mar 22 00:56:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     bording@bnl.gov
>Release:        gcc-3.2.7
>Organization:
>Environment:
Red-Hat 8.0 on Pentium Pro
>Description:
It seems double precision is not used:
----fortran code----
      real a
      double precision b

      a = 0.555555555555555555
      b = 0.555555555555555555
      write(6,1) a
      write(6,2) b
1     format('real   ',f30.28)
2     format('double ',f30.28)
      end

gives : 
real   0.5555555820465087890625000000
double 0.5555555820465087890625000000

------C code -----
#include <stdio.h>
float a;
double b;
main()
{
  a = b = 0.555555555555555555;
  printf("real   %.28f\n",a);
  printf("double %.28f\n",b);
}

gives:
real   0.5555555820465087890625000000
double 0.5555555555555555802271783250

-----
For C double has higher resolution, but for fortran 
there is no differece. I have tried various
compiler flags without luck !
>How-To-Repeat:

>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


             reply	other threads:[~2003-03-22  0:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-22  0:56 bording [this message]
2003-03-22  1:16 Billinghurst, David (CRTS)
2003-03-22 13:40 toon

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=20030322005428.28063.qmail@sources.redhat.com \
    --to=bording@bnl.gov \
    --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).