From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 114959 invoked by alias); 25 Jun 2018 17:04:27 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 114921 invoked by uid 89); 25 Jun 2018 17:04:26 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-11.1 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=kfmode, KFmode, love, HContent-Transfer-Encoding:8bit X-HELO: gate.crashing.org Received: from gate.crashing.org (HELO gate.crashing.org) (63.228.1.57) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 25 Jun 2018 17:04:24 +0000 Received: from gate.crashing.org (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id w5PH4L6h007822; Mon, 25 Jun 2018 12:04:21 -0500 Received: (from segher@localhost) by gate.crashing.org (8.14.1/8.14.1/Submit) id w5PH4Kvu007817; Mon, 25 Jun 2018 12:04:20 -0500 Date: Mon, 25 Jun 2018 17:04:00 -0000 From: Segher Boessenkool To: Carl Love Cc: gcc-patches@gcc.gnu.org, David Edelsohn , Bill Schmidt Subject: Re: [PATCH, rs6000] Fix AIX test case failures Message-ID: <20180625170419.GK16221@gate.crashing.org> References: <1529704544.7264.13.camel@us.ibm.com> <20180625094450.GD16221@gate.crashing.org> <1529945597.6530.4.camel@us.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1529945597.6530.4.camel@us.ibm.com> User-Agent: Mutt/1.4.2.3i X-IsSubscribed: yes X-SW-Source: 2018-06/txt/msg01571.txt.bz2 On Mon, Jun 25, 2018 at 09:53:17AM -0700, Carl Love wrote: > On Mon, 2018-06-25 at 04:44 -0500, Segher Boessenkool wrote: > > On Fri, Jun 22, 2018 at 02:55:44PM -0700, Carl Love wrote: > > > --- a/gcc/testsuite/gcc.target/powerpc/divkc3-2.c > > > +++ b/gcc/testsuite/gcc.target/powerpc/divkc3-2.c > > > @@ -13,4 +13,5 @@ divide (cld_t *p, cld_t *q, cld_t *r) > > >    *p = *q / *r; > > >  } > > >   > > > -/* { dg-final { scan-assembler "bl __divkc3" } } */ > > > +/* { dg-final { scan-assembler "bl __divkc3" { target { powerpc*- > > > *-linux* } } } } */ > > > +/* { dg-final { scan-assembler "bl .__divdc3" { target { powerpc*- > > > *-aix* } } } } */ > > > > Should it be calling __divdc3 on AIX, is that correct? > > I was a bit surprised that it wasn't calling divkc3. I am guessing > these are library routines we are calling? I couldn't find the source > code for them and don't really know what the difference is between > divkc3 and divdc3. divkc3 is for KCmode, that is the complex mode for KFmode (128-bit IEEE). divdc3 is for DCmode, that is the complex mode for DFmode (64-bit IEEE, that is, "double"). I think this is the same as PR82625, for which I have a patch in testing. > So, not sure why AIX and Linux are not calling the name for the > function or if what is being called is functionally equivalent? AIX uses 64-bit long double by default, and GCC has a bug with that and -mabi=ieeelongdouble and __ieee128. It thinks __ieee128 is the same as long double if it has -mabi=ieeelongdouble, but that is not always true. So it ends up using the long double type for __ieee128, but that is just double precision float in this case. So, hang on :-) Segher