From owner-freebsd-amd64@FreeBSD.ORG Wed Mar 3 13:40:02 2010 Return-Path: Delivered-To: freebsd-amd64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EFD341065676 for ; Wed, 3 Mar 2010 13:40:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id B2E418FC22 for ; Wed, 3 Mar 2010 13:40:02 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id o23De2iA082491 for ; Wed, 3 Mar 2010 13:40:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id o23De2j4082490; Wed, 3 Mar 2010 13:40:02 GMT (envelope-from gnats) Resent-Date: Wed, 3 Mar 2010 13:40:02 GMT Resent-Message-Id: <201003031340.o23De2j4082490@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-amd64@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, "Eugene M. Zheganin" Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 78A9D106564A for ; Wed, 3 Mar 2010 13:33:54 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 683288FC15 for ; Wed, 3 Mar 2010 13:33:54 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o23DXrj4087960 for ; Wed, 3 Mar 2010 13:33:53 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id o23DXrb9087924; Wed, 3 Mar 2010 13:33:53 GMT (envelope-from nobody) Message-Id: <201003031333.o23DXrb9087924@www.freebsd.org> Date: Wed, 3 Mar 2010 13:33:53 GMT From: "Eugene M. Zheganin" To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 X-Mailman-Approved-At: Wed, 03 Mar 2010 19:41:40 +0000 Cc: Subject: amd64/144448: sin() broken in libm on amd64 X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Mar 2010 13:40:03 -0000 >Number: 144448 >Category: amd64 >Synopsis: sin() broken in libm on amd64 >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-amd64 >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Mar 03 13:40:02 UTC 2010 >Closed-Date: >Last-Modified: >Originator: Eugene M. Zheganin >Release: 7.2-RELEASE >Organization: Norma JSC. >Environment: FreeBSD gw0.qwerty.perm.ru 7.2-RELEASE FreeBSD 7.2-RELEASE #0: Fri May 1 07:18:07 UTC 2009 root@driscoll.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64 >Description: The following code, being compiled, is printing different results on i386 and amd64 platforms. The result on amd64 is invalid. ===Cut=== #include #include int main (int argc, char **argv) { int i; double curval, prevval; prevval = 734; curval = sin(734); printf("%.15f %.15f\n", prevval, curval); for (i = 0; i < 19; i++) { curval = 16 * curval; prevval = curval; curval = sin(curval); printf("%.15f %.15f\n", prevval, curval); } } ===Cut=== >How-To-Repeat: Get sample code from http://unix.zhegan.in/files/sin-cycle.c , compile it, and run. Compare results from running the code on different architectures. >Fix: >Release-Note: >Audit-Trail: >Unformatted: