<div dir="ltr">ECL uses tanf() for computing the tangent with single-floats. If you have a look at the code in ecl/src/c/numbers/tan.d you will find the lines below. One possibility would be to uncomment safe_tanf() and see whether ECL now works. If this is the case then we might have to add another switch for your platform :-/<div>

<br></div><div><br></div><div><div>/*</div><div> * As of 2006-10-13 I found this bug in GLIBC's tanf, which overflows</div><div> * when the argument is pi/4. It is 2008 and this has not yet been</div><div> * solved. Not only that, but if we use tan() on float, GCC automatically</div>

<div> * and stupidly forces the use of tanf().</div><div> */</div><div>#if defined(__amd64__) && defined(__GLIBC__)</div><div>static double safe_tanf(double x) { return tan(x); }</div><div>#else</div><div># define safe_tanf(x) tanf(x)</div>

<div>#endif</div></div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Mar 28, 2013 at 11:50 PM, Eric Marsden <span dir="ltr"><<a href="mailto:eric.marsden@free.fr" target="_blank">eric.marsden@free.fr</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I have recently acquired a cubieboard, a small ARM Cortex-A8 development<br>
board (ARM v7, NEON, VFPv3), on which I run the rasbpian Debian<br>
derivative. It's using GCC 4.6.3 and runs fine under ECL, except for a<br>
bug in TAN:<br>
<br>
,----<br>
| ;;; Loading #P"/usr/local/lib/ecl-12.12.1/asdf.fas"<br>
| ECL (Embeddable Common-Lisp) 12.12.1 (git:e90ff5a6c720334e0450a107bb0bdc1fd746d5ea)<br>
| Copyright (C) 1984 Taiichi Yuasa and Masami Hagiya<br>
| Copyright (C) 1993 Giuseppe Attardi<br>
| Copyright (C) 2000 Juan J. Garcia-Ripoll<br>
| ECL is free software, and you are welcome to redistribute it<br>
| under certain conditions; see file 'Copyright' for details.<br>
| Type :h for Help.<br>
| Top level in: #<process TOP-LEVEL>.<br>
| > (tan (coerce (/ pi 4) 'double-float))<br>
| 0.9999999999999999d0<br>
| > (tan (coerce (/ pi 4) 'single-float))<br>
| Condition of type: FLOATING-POINT-UNDERFLOW<br>
| #<a FLOATING-POINT-UNDERFLOW><br>
`----<br>
<br>
A basic C program which prints tan(atan(1)) works fine. What can I do to<br>
help to debug?<br>
<br>
--<br>
Eric Marsden<br>
<br>
<br>
------------------------------------------------------------------------------<br>
Own the Future-Intel(R) Level Up Game Demo Contest 2013<br>
Rise to greatness in Intel's independent game demo contest. Compete<br>
for recognition, cash, and the chance to get your game on Steam.<br>
$5K grand prize plus 10 genre and skill prizes. Submit your demo<br>
by 6/6/13. <a href="http://altfarm.mediaplex.com/ad/ck/12124-176961-30367-2" target="_blank">http://altfarm.mediaplex.com/ad/ck/12124-176961-30367-2</a><br>
_______________________________________________<br>
Ecls-list mailing list<br>
<a href="mailto:Ecls-list@lists.sourceforge.net">Ecls-list@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/ecls-list" target="_blank">https://lists.sourceforge.net/lists/listinfo/ecls-list</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Instituto de Física Fundamental, CSIC<br>c/ Serrano, 113b, Madrid 28006 (Spain) <br><a href="http://juanjose.garciaripoll.googlepages.com" target="_blank">http://juanjose.garciaripoll.googlepages.com</a>
</div>