GSoC/GCI Archive
Google Code-in 2010 Haiku

Research missing math.h functions

completed by: mschallert

mentors: Joseph R. Prostko

This is a research-only task that is open solely for the student, mschallert, due to the work completed on the math.h implementation task that wasn't enough for full credit, but did demand some credit.  That said, it was agreed that in the future, we will only allow full implementation on such tasks in order to count the task as completed. 


As part of Haiku trac ticket 2696:http://dev.haiku-os.org/ticket/2696

These are present in the math.h header, but not yet implemented:
math.h:
lgammal
gamma_r
gammaf_r

The following issues also need to be adressed in math.h:
1. Missing definition of float_t and double_t as described at opengroup.org.
2.  Missing declaration of FLT_EVAL_METHOD.
3.  Function "int isgreater(real-floating x, real-floating y);" is never defined or declared in the header.
4.  Function "int isgreaterequal(real-floating x, real-floating y);"  is never defined or declared in the header.
5.  Functions "int isless(real-floating x, real-floating y);,
    int islessequal(real-floating x, real-floating y);,
    int islessgreater(real-floating x, real-floating y);" are never defined or declared in  the header.
6.  Function "int isunordered(real-floating x, real-floating y);" is never defined or declared in the header.
7.  There is no definition of "MAXFLOAT" constant in the header.
8.  The following optional macros "FP_FAST_FMA, FP_FAST_FMAF, FP_FAST_FMAL" are not defined in the header.
9.  The following macros "FP_ILOGB0, FP_ILOGBNAN, MATH_ERRNO, MATH_ERREXCEPT, math_errhandling" are never defined in the header.

The functions need to provide the requirements as defined at:
http://www.opengroup.org/onlinepubs/9699919799/basedefs/math.h.html