From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id C43303858C1F for ; Thu, 13 Apr 2023 17:37:54 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C43303858C1F Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1681407474; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=weq/Boy9jvOFzA3TQMjIM/Ax1OqbhEFoc44cVW8fHPs=; b=fvD7EFTS3n4KH7NEQ7cxVbe0uw60/qXGcEwGKmjHsXPY1OBQUJERcih/MkxsFTvzF1o+Ng 3TbrV+//DBgkaP8lVx+m2BCUH2RQBJayHlbNdGZB8/3/A480DnPv0uiv0k/oQbyjehIJwP /JDu7KqL2B1kDZCdkXaFzzekstDNyaA= Received: from mail-qt1-f199.google.com (mail-qt1-f199.google.com [209.85.160.199]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-225-WB5okO66MdS4HT730PKomA-1; Thu, 13 Apr 2023 13:37:50 -0400 X-MC-Unique: WB5okO66MdS4HT730PKomA-1 Received: by mail-qt1-f199.google.com with SMTP id f2-20020ac87f02000000b003e6372b917dso29029469qtk.3 for ; Thu, 13 Apr 2023 10:37:50 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681407470; x=1683999470; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=weq/Boy9jvOFzA3TQMjIM/Ax1OqbhEFoc44cVW8fHPs=; b=mFIzyfzRPH58xOSKrSX97LNGgXoLxnYozO48bp+1TkMjNWF+Knf9rpnaaxtLqhk07Y PiCr8IG6ZF9pXvc3/4WsILp496sUmAqkoMPnbIva2XoFK1ftnnqb9NgpfZCx/atoV9lf /A1ZJHYF0ber+VluFs7COP0eW0k/eVqF/+F/leBS8y+FtSHezomXuqQhQw/2vtgHi0/L AoELQs0faGr3b6Bfg5wSIX7sxsq7Vf9tHV4jqrPyt8pyh/Cg5Qsqh0XJNTLlIstvf7N/ 46p7UFG4u4/ur6BEV0ECJ7X6krhjA7WLWoYisyZRT0jTUAMJ0GY6QJY0A76dikl2au2l RzWw== X-Gm-Message-State: AAQBX9dj+G+fsLNSOOmmLYriLbmWNk0aBhWwP8a3gjZh5p0DiiJlXzD0 aNeQh9sQ11HLsXfdYAAkGlDnS/I+CoaKDDSb6v+/RxXCh1SDzYTwSZrk6uNNIutYUIe1dgygMGI /KS/IqCtvqcrLI4GIoSJ72OymVFhlZE8= X-Received: by 2002:ac8:7d16:0:b0:3e6:71d6:5d65 with SMTP id g22-20020ac87d16000000b003e671d65d65mr987296qtb.4.1681407470154; Thu, 13 Apr 2023 10:37:50 -0700 (PDT) X-Google-Smtp-Source: AKy350ZQbJH5GuqXB/qMJ3Fkc+Om4ytb/FX7zgKD5C4X2rycmGU0jaZ7BaOUbA72qxNQ8XNeJZ7t2Mas5szayTwZ6NA= X-Received: by 2002:ac8:7d16:0:b0:3e6:71d6:5d65 with SMTP id g22-20020ac87d16000000b003e671d65d65mr987287qtb.4.1681407469895; Thu, 13 Apr 2023 10:37:49 -0700 (PDT) MIME-Version: 1.0 References: <20230412153445.161047-1-andoni.arregui@gtd-gmbh.de> In-Reply-To: From: Jeff Johnston Date: Thu, 13 Apr 2023 13:37:39 -0400 Message-ID: Subject: Re: [PATCH 0/4] Fix huge error for pow detected by Paul Zimmermann To: andoni.arregui@gtd-gmbh.de Cc: Paul Zimmermann , newlib@sourceware.org X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: multipart/alternative; boundary="000000000000f7511305f93b2e7e" X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --000000000000f7511305f93b2e7e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks Andoni and Paul. Patches pushed to master. -- Jeff J. On Thu, Apr 13, 2023 at 10:42=E2=80=AFAM Andoni Arregi wrote: > Dear Paul, > > thank *you* for detecting the errors/inaccuracies first (questions are as > important as the answers) and then > independently confirming that the patch solves them. > > You know how tricky this is and how easy it is to fix something here and > break it there. That's why such an independent > verification in addition to our tests is so important :-) > > By the way, most of the submitted work is product of the effort of our > colleague Fabian Schriever. > > Best regards > > On Thu, 2023-04-13 at 14:16 +0200, Paul Zimmermann wrote: > > Hi Andoni, > > > > I had time to check this patch series on top of be2749c. > > > > I confirm the issue I reported is fixed. > > > > In addition, the maximal known error, which was 636 ulps > > apart from the above issue, has dropped to less than 1 ulp: > > > > pow 0 -1 0x1.4c3064d46aef3p-851,-0x1.cef4118ed50c2p-10 [0.893] 0.892119 > 0.8921192373561432 > > > > Thank you, great work! > > > > Paul > > > > > From: Andoni Arregi > > > Cc: Andoni Arregi > > > Date: Wed, 12 Apr 2023 17:34:41 +0200 > > > > > > This patch series fixes in pow the huge error detected by Paul > > > Zimmermann where x is negative and y is a large odd integer. > > > > > > There is also an accuracy fix for cases where x is close to 1 and y is > > > large. > > > > > > Andoni Arregi (4): > > > Fix missing sign for overflow/underflow where x is negative and y is > > > large odd integer > > > Fix x close to 1, y between 2^31 and 2^64 > > > Compare j as unsigned > > > Replace always true if with else > > > > > > newlib/libm/math/e_pow.c | 48 +++++++++++++++++++++-----------------= -- > > > 1 file changed, 25 insertions(+), 23 deletions(-) > > > > > > -- > > > 2.40.0 > > > > > > > > > > > -- > Andoni Arregi > Gesch=C3=A4ftsf=C3=BChrer > > GTD GmbH > Ravensburger Str. 32a, 88677 Markdorf > T: +49 7544 96440 22 | M: +49 151 65620499 | F: +49 7544 96440 29 > http://www.gtd-gmbh.de andoni.arregi@gtd-gmbh.de > > --000000000000f7511305f93b2e7e--