This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: patch: docs for soft float routines


On Mon, Mar 10, 2003 at 11:03:01AM -0800, Aldy Hernandez wrote:
> + Given two arguments (a and b), these functions compare the two
> + arguments.  If @code{a} is less than @code{b}, the function returns
> + -1.  If @code{a} is greater than @code{b}, the function returns 1.  If
> + @code{a} is equal to @code{b}, the function returns 0.  If either
> + argument is a NAN, the function returns 1.
> + 
> + @smallexample
> + int __cmpdf2 (double, double);
> + int __cmpsf2 (float, float);
> + int __cmptf2 (long double, long double);
> + @end smallexample

> + These functions return the result of converting its floating point
> + argument to an integer, still represented in floating point mode, by
> + rounding towards zero.
> + 
> + @smallexample
> + int __fixdfsi (double);

Um, in what way is the result "still represented in floating point mode"?

> + long double __floatunsitf (int);

Typo: "unsigned".

> + These functions return 1 if the first argument is greater or equal
> + than the second argument, or if either argument is a NAN.  Otherwise,
> + 0 is returned.
> + 
> + @smallexample
> + int __gedf2 (double, double);

Incorrect.  We *don't* return 1 for NaN here, since test for truth
is __gedf2(x,y) >= 0.  We return -1 for NaN.  Similarly for __gt.

> + These functions represent the result of converting its floating point
> + argument ot a fixed point value, regarded as unsigned.  How rounding
> + is done is not specified.
> + 
> + @smallexample
> + unsigned int __fixunsdfsi (double);

I'm pretty sure we expect crop to zero here, not "unspecified".




r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]