delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/03/07/13:27:02

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-1.5 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD
X-Spam-Check-By: sourceware.org
Message-Id: <4D752358.9020508@saic.com>
Date: Mon, 07 Mar 2011 13:26:32 -0500
From: "Roger K. Wells" <ROGER DOT K DOT WELLS AT saic DOT com>
User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Thunderbird/3.1.7
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: 1.7.8: Fortran I/O rounding inaccuracy
References: <AANLkTinwzNz4X8btcrjVm+3Lxp_30iqr4FkuB1U=rrr6 AT mail DOT gmail DOT com> <4D74FD73 DOT 7010900 AT saic DOT com> <4D7509D4 DOT 5000204 AT saic DOT com> <loom DOT 20110307T181232-654 AT post DOT gmane DOT org>
In-Reply-To: <loom.20110307T181232-654@post.gmane.org>
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On 03/07/2011 12:15 PM, Peter Brown wrote:
> Roger K. Wells<ROGER.K.WELLS<at>  saic.com>  writes:
>
>> On 03/07/2011 10:44 AM, Roger K. Wells wrote:
>>> On 03/07/2011 04:39 AM, Thomas Henlich wrote:
>>>> Hi,
>>>>
>>>> I found the following bug in cygwin 1.7.8 on Windows XP:
>>>>
>>>> Fortran I/O rounding truncates the result after a certain number of
>>>> digits. The following program:
>>>> ===
>>>> write(*, '(f35.32)') 0.14285714285714285d0
>>>> end
>>>> ===
>>>> gives this output:
>>>>    0.14285714285714284921269000000000
>>>> The expected output is:
>>>>    0.14285714285714284921269268124888
>>>>
> I don't think this has anything to do with cygin. On our linux system I get
>
> With Intel ifort:
>   0.14285714285714284921269268124888
>
> With gfortran 4.1.2s544
>   0.14285714285714284921269270000000
>
I agree.  It's a GCC problem.  I get the same results on Cygwin & Linux:
compiling with g77 gives correct output
compiling with gfortran does not.
rkw
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>
>


-- 
Roger Wells, P.E.
SAIC
221 Third St
Newport, RI 02840
401-847-4210 (voice)
401-849-1585 (fax)
roger DOT k DOT wells AT saic DOT com


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019