From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from Atcsqr.andestech.com (60-248-80-70.hinet-ip.hinet.net [60.248.80.70]) by sourceware.org (Postfix) with ESMTPS id D4E4038582A2 for ; Sun, 16 Oct 2022 03:10:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D4E4038582A2 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=andestech.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=andestech.com Received: from mail.andestech.com (ATCPCS16.andestech.com [10.0.1.222]) by Atcsqr.andestech.com with ESMTP id 29G3AYdw089032; Sun, 16 Oct 2022 11:10:34 +0800 (+08) (envelope-from peterlin@andestech.com) Received: from APC323 (10.0.12.98) by ATCPCS16.andestech.com (10.0.1.222) with Microsoft SMTP Server id 14.3.498.0; Sun, 16 Oct 2022 11:10:32 +0800 Date: Sun, 16 Oct 2022 11:08:08 +0000 From: Yu-Chien Peter Lin To: Szabolcs Nagy CC: , Subject: Re: math tests failed when the argument is out of domain Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/2.2.6 (2022-06-05) X-Originating-IP: [10.0.12.98] X-DNSRBL: X-MAIL:Atcsqr.andestech.com 29G3AYdw089032 X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_06_12,KAM_DMARC_STATUS,PDS_RDNS_DYNAMIC_FP,RDNS_DYNAMIC,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Thu, Oct 13, 2022 at 10:24:59AM +0100, Szabolcs Nagy wrote: > The 10/11/2022 20:25, Yu-Chien Peter Lin wrote: > > Hi all, > > > > We run the glibc testsuite on RISC-V targets and got some > > common failure of following test in math subdir. > > > > FAIL: math/test-double-acos > > FAIL: math/test-double-asin > > FAIL: math/test-float64-acos > > FAIL: math/test-float64-asin > > FAIL: math/test-float32x-acos > > FAIL: math/test-float32x-asin > > > > The return values and errno of acos and asin are correct, but > > they don't raise "Invalid operation" exception when the argument > > is inf, -inf, 1.125, -1.125, max_value and -max_value. > > > fwiw i saw this on aarch64 with some version of gcc-10 when > 'return INFINITY/INFINITY;' is optimized to 'return NAN;' > so the fenv exception is not set. > > this could be fixed via a more robust arithmetic to set nan > e.g. (x-x)/(x-x) or ensuring gcc takes exceptions into account > when const folding float operations. Hi Szabolcs, Thanks, these tests are pass with your patch applied. Best Regards, Peter Lin > > > > These failed cases are listed test results [1] since glibc 2.33, > > but it seems not a reported bug on sourceware bugzilla. so I want > > to know the status on this issue. > > > > [1] https://sourceware.org/glibc/wiki/Release/2.35#RISC-V_.28rv64imafdc.2Flp64d.29 > > > > These tests run at below environments. > > - glibc 2.35 > > - gcc 10.2.1 > > - binutils 2.38 > > - Linux 5.4 > > > > Best Regards, > > Peter Lin