NetBSD Problem Report #46434
From www@NetBSD.org Wed May 9 03:08:49 2012
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
by www.NetBSD.org (Postfix) with ESMTP id A884863B91F
for <gnats-bugs@gnats.NetBSD.org>; Wed, 9 May 2012 03:08:48 +0000 (UTC)
Message-Id: <20120509030847.9868363B915@www.NetBSD.org>
Date: Wed, 9 May 2012 03:08:47 +0000 (UTC)
From: isaki@NetBSD.org
Reply-To: isaki@NetBSD.org
To: gnats-bugs@NetBSD.org
Subject: tests/lib/libm/t_cosh should not depends on exp()
X-Send-Pr-Version: www-1.0
>Number: 46434
>Category: lib
>Synopsis: tests/lib/libm/t_cosh should not depends on exp()
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: lib-bug-people
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed May 09 03:10:00 +0000 2012
>Closed-Date: Mon Aug 12 03:48:37 +0000 2019
>Last-Modified: Mon Aug 12 03:48:37 +0000 2019
>Originator: Tetsuya Isaki
>Release: NetBSD 6.0_BETA/x68k
>Organization:
NetBSD
>Environment:
>Description:
The 'cosh_def' test in tests/lib/libm/t_cosh.c (rev 1.4) uses
the following formula:
cosh(x) = (exp(x) + exp(-x)) / 2
By this method, if exp() is not right though cosh() is right,
the test of cosh() fails. It's not appropriate.
# By the way, in incomplete m68k FPE (in-kernel FPU emulation),
# cosh() is implemeted (of course, correctly I think :-) but
# exp() is not implemented yet. Therefore, the current test of
# cosh() does not pass X-(
The following tests have a similar problem as far as I found:
- coshf_def
- sinh_def
- sinhf_def
>How-To-Repeat:
See the source code.
or run the t_cosh test on m68k without FPU.
>Fix:
N/A, Sorry.
>Release-Note:
>Audit-Trail:
From: "Tetsuya Isaki" <isaki@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/46434 CVS commit: src/tests/lib/libm
Date: Tue, 9 Apr 2013 12:11:05 +0000
Module Name: src
Committed By: isaki
Date: Tue Apr 9 12:11:04 UTC 2013
Modified Files:
src/tests/lib/libm: t_acos.c t_asin.c t_atan.c t_cosh.c t_sinh.c
Log Message:
Use a pre-calculated value as expected result, instead of
comparing it in a mathematical formula.
PR lib/46434 (and see also 46433).
To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/tests/lib/libm/t_acos.c
cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libm/t_asin.c
cvs rdiff -u -r1.7 -r1.8 src/tests/lib/libm/t_atan.c
cvs rdiff -u -r1.4 -r1.5 src/tests/lib/libm/t_cosh.c \
src/tests/lib/libm/t_sinh.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->feedback
State-Changed-By: maya@NetBSD.org
State-Changed-When: Sun, 11 Aug 2019 09:22:36 +0000
State-Changed-Why:
If there are remaning issues after your commit, what are they?
State-Changed-From-To: feedback->closed
State-Changed-By: isaki@NetBSD.org
State-Changed-When: Mon, 12 Aug 2019 03:48:37 +0000
State-Changed-Why:
Oh, It resolved. Thank you for notifying.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.