1 /* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
3 * Permission to use, copy, modify, and distribute this software
4 * is freely granted, provided that this notice is preserved.
8 #include "math_private.h"
11 double fdim(double x
, double y
)
13 int cx
= __fpclassify(x
); /* need both NAN and INF */
14 int cy
= __fpclassify(y
); /* need both NAN and INF */
15 if (cx
== FP_NAN
|| cy
== NAN
)
22 if (isinf(z
) && cx
!= FP_INFINITE
&& cy
!= FP_INFINITE
)