Lines Matching defs:p
36 * remainderl(x,p)
37 * returns x REM p = x - [x/p]*p as if in infinite
38 * precise arithmetic, where [x/p] is the (inifinite bit)
39 * integer nearest x/p (in half way case choose the even one).
41 * Based on fmodl() return x-[x/p]chopped*p exactly.
54 remainderl(long double x, long double p) {
58 if (isnanl(p))
59 return (x + p);
62 p = fabsl(p);
63 if (p <= hfmax)
64 x = fmodl(x, p + p);
67 if (p < dbmin) {
68 if (x + x > p) {
69 if (x == p)
72 x -= p; /* avoid x-x=-0 in RM mode */
73 if (x + x >= p)
74 x -= p;
77 hp = half * p;
79 if (x == p)
82 x -= p; /* avoid x-x=-0 in RM mode */
84 x -= p;