From owner-freebsd-numerics@FreeBSD.ORG Thu Jun 27 01:38:34 2013 Return-Path: Delivered-To: freebsd-numerics@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 4929578A for ; Thu, 27 Jun 2013 01:38:34 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (troutmask.apl.washington.edu [128.95.76.21]) by mx1.freebsd.org (Postfix) with ESMTP id 1278D1BCA for ; Thu, 27 Jun 2013 01:38:34 +0000 (UTC) Received: from troutmask.apl.washington.edu (localhost.apl.washington.edu [127.0.0.1]) by troutmask.apl.washington.edu (8.14.6/8.14.6) with ESMTP id r5R1Z2vg037390; Wed, 26 Jun 2013 18:35:02 -0700 (PDT) (envelope-from sgk@troutmask.apl.washington.edu) Received: (from sgk@localhost) by troutmask.apl.washington.edu (8.14.6/8.14.6/Submit) id r5R1Z2me037389; Wed, 26 Jun 2013 18:35:02 -0700 (PDT) (envelope-from sgk) Date: Wed, 26 Jun 2013 18:35:02 -0700 From: Steve Kargl To: enh Subject: Re: sincos? Message-ID: <20130627013502.GA37295@troutmask.apl.washington.edu> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-numerics@freebsd.org X-BeenThere: freebsd-numerics@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Discussions of high quality implementation of libm functions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Jun 2013 01:38:34 -0000 On Wed, Jun 26, 2013 at 04:45:34PM -0700, enh wrote: > i'm a recent lurker on this list; i've inherited Android's C library, and > among other things i'm trying to track FreeBSD's lib/msun much more closely > than we have traditionally. > > i was just reminded of the existence of a change submitted to us (Android) > a while back that adds a sincos/sincosf implementation cobbled together > from your s_sin.c/s_sinf.c and s_cos.c/s_cosf.c implementations: > https://android-review.googlesource.com/#/c/47585/ > A quick glance at the code shows that the android project has slapped its Copyright on fdlibm code. I suspect that you'll want to restore proper attribution to Sun Microsystems. > the submitter (Intel) rightly points out that at the moment GCC carefully > optimizes paired sin/cos calls into a sincos call which we deoptimize back > into separate sin/cos calls. i personally don't want to take on maintenance > of this, but i would be happy to include you guys' sincos implementation if > you had one. is there a reason you don't have one? I haven't submitted the versions of sincos[fl], which I've developed over the last year or so, yet. First, I need to redo some testing. Second, I need to convince Bruce that the implementation would be a nice addition to libm. -- Steve