From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27359 invoked by alias); 25 Jul 2011 11:30:18 -0000 Received: (qmail 27351 invoked by uid 22791); 25 Jul 2011 11:30:18 -0000 X-SWARE-Spam-Status: No, hits=-0.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from tirion.supremecenter202.com (HELO tirion.supremecenter202.com) (209.25.195.243) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 25 Jul 2011 11:30:00 +0000 Received: from [195.189.206.101] (port=39531 helo=[192.168.209.100]) by tirion.supremecenter202.com with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69) (envelope-from ) id 1QlJMG-0000I2-9G for ecos-devel@ecos.sourceware.org; Mon, 25 Jul 2011 11:30:00 +0000 Message-ID: <4E2D53B4.1060108@siva.mk> Date: Mon, 25 Jul 2011 11:30:00 -0000 From: Visar Zejnullahu User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.18) Gecko/20110617 Thunderbird/3.1.11 MIME-Version: 1.0 To: ecos-devel@ecos.sourceware.org Subject: Testing newlib Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact ecos-devel-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: ecos-devel-owner@ecos.sourceware.org X-SW-Source: 2011-07/txt/msg00004.txt.bz2 Hi. As announced here: http://sourceware.org/ml/ecos-devel/2011-07/msg00003.html we are working on a port of Newlib's single precision floating point math library (float vs double...). I know part of the questions should be addressed to the Newlib's mailing list (which I have done as well), but I am asking help on the Ecos part of the problems. We've reached the testing phase of the single precision functions. First, I have noticed the tests provided in Ecos are different from those of Newlib's. Can anyone tell how are the test cases chosen? As one can notice, the test cases in Ecos are random, but are they randomly chosen over some interval that is "critical" for some specific function (i.e. some interval in which the specific function might return some value that differs from the value it should return, that is, in this interval the function might be erroneous). On the other hand, the test cases in Newlib are from the interval [-1.2;1.19] with step 0.01, and some other test cases that do not exceed the interval [-30;30]. Second, I have noticed, there are no tests provided in the current/tests/vectors directory (where all tests for the corresponding functions are) for these functions: acosh, atanh, gamma functions, hypot, Bessel functions, remainder, scalb, asinh, cbrt, copysign, error function, expm1, finite, ilogb, isnan, log1p, nextafter, rint, scalbn and significand (I am talking about the standard double-receiving-and-returning functions, not their float counterparts we are working on). From these functions. I could not find tests on the corresponding test folder of the Newlib (1.19.0) for these functions: remainder, scalb, cbrt, copysign, expm1, finite, ilogb, nextafter, rint, scalbn and significand. How could this be explained? I know that some of them are not standard ANSI C functions, and some of them are closely related with other similar functions (for example, expm1(x) is exp(x) - 1, as the name suggests). Also, I have noticed that in some functions, when the argument is out of range, the function returns value other than specified in documentation of the Newlib. For example, when asin receives argument not in the range [-1;1], the documentation says it should return NaN, while in fact it returns zero. And lastly, about the gamma function - I've used the tests provided from Newlib, and when I try to compile the test files about this function, I get the error ecos/packages/language/c/libm/current/src/double/ieee754-api/w_gamma.c:99: undefined reference to `signgam'. Can anyone help on this? Kind regards, Visar