Some time ago I was hit by incorrect
implementation of some complex intrinsic functions
in some compilers for some specific values on branch cuts.
I then wrote a simple checker for 8 f2008 intrinsics,
LOG, SQRT, ACOS, ACOSH, ASIN, ASINH, ATAN, ATANH:
My preliminary results are:
GCC6 on FreeBSD: passed 70 out of 70
Cray CCE 8.5.3: passed 37 out of 70
PGI (Portland) 16.3-0 on linux: passed 18 out of 34
Intel 16.0.2 on linux: passed 14 out of 14
Oracle 12.5 on linux: passed 6 out of 6
Full tests results, documentation and source code (BSD license):
http://cmplx.sourceforge.net/
I'm interested in any feedback.
Are my tests sound?
Could they be improved?
Are the function results for some cases beyond what is
prescribed by the standard?
I'd be grateful for results from other compilers/platforms.
As well as the test program, there is also
a document with detailed derivations,
showing what the values on both sides of the branch cuts should be.
There is also a document with conformal maps
of these 8 functions, drawn using PGPLOT.
Let me know directly if you want to contribute to the project.
Thanks
Anton
|