From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16810 invoked by alias); 29 Dec 2007 17:49:37 -0000 Received: (qmail 16801 invoked by uid 22791); 29 Dec 2007 17:49:37 -0000 X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.33.17) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sat, 29 Dec 2007 17:49:31 +0000 Received: from zps19.corp.google.com (zps19.corp.google.com [172.25.146.19]) by smtp-out.google.com with ESMTP id lBTHnMGx014434; Sat, 29 Dec 2007 17:49:23 GMT Received: from smtp.corp.google.com (spacemonkey1.corp.google.com [192.168.120.115]) by zps19.corp.google.com with ESMTP id lBTHnLZx008972 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sat, 29 Dec 2007 09:49:21 -0800 Received: from localhost.localdomain.google.com (adsl-76-249-168-94.dsl.pltn13.sbcglobal.net [76.249.168.94]) (authenticated bits=0) by smtp.corp.google.com (8.13.8/8.13.8) with ESMTP id lBTHnKb2031175 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sat, 29 Dec 2007 09:49:20 -0800 To: =?utf-8?b?SXNtYWlsIETDtm5tZXo=?= Cc: gcc@gcc.gnu.org Subject: Re: glibc 2.7 complex functions are possibly miscompiled by gcc 4.3 trunk References: <200712221911.32786.ismail@pardus.org.tr> <200712291811.47936.ismail@pardus.org.tr> From: Ian Lance Taylor Date: Sat, 29 Dec 2007 18:12:00 -0000 In-Reply-To: <200712291811.47936.ismail@pardus.org.tr> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2007-12/txt/msg00703.txt.bz2 Ismail D=C3=B6nmez writes: > Saturday 22 December 2007 19:11:32 tarihinde Ismail D=C3=B6nmez =C5=9Funl= ar=C4=B1 yazm=C4=B1=C5=9Ft=C4=B1: > > Hi all, > > > > I am doing glibc 4.3 regression tests using gcc 4.3 trunk nearly every = day > > and I see 3 tests fail : > > > > math/test-float > > math/test-ildoubl > > math/test-ifloat > > > > The erorrs are all similar : > > > > Failure: Test: Imaginary part of: cacosh (-0 + 0 i) =3D=3D 0.0 + pi/2 i > > Result: > > is: 0.00000000000000000000e+00 0x0.00000000000000000000p+0 > > should be: 1.57079637050628662109e+00 0x1.921fb600000000000000p+0 > > difference: 1.57079637050628662109e+00 0x1.921fb600000000000000p+0 > > ulp : 13176795.0000 > > max.ulp : 0.0000 >=20 > Replying to myself once again, these failures are due to -fgcse-after-rel= oad=20 > flag, -O3 -fno-gcse-after-reload cures this. Any tips on how to debug thi= s? Generic advice to start: compile with -da to get all the RTL dump files. Compare the dump files immediately before and after gcse-after-reload and see what changed. Set breakpoints on validate_change or make_insn_raw as appropriate for the changes. Walk up the stack and see what the code is doing. The file in question is postreload-gcse.c, which is relatively self-contained. Of course it is moderately likely that the bug is not in gcse-after-reload, and is in some other pass generating incorrect information. Still, finding the problem in gcse-after-reload is a good start. Ian