llrint() into math.h

Víctor Paesa wzrlpy@arsystel.com
Sat Nov 25 02:42:00 GMT 2006


Hi,

>>> I will ask in newlib list, as you have kindly suggested.
>>
>> I have interest in llrint too. What did the newlib-guys answer?
>
>  Victor never asked, from the looks of it.

Right, I changed mind and never wrote, I decided to add it into my
sources via this:

#ifndef llrint
inline long long int llrint (double x)
{
    long long int llrintres;
    asm
    ("fistpll %0"
    : "=m" (llrintres) : "t" (x) : "st");
    return llrintres;
}
#endif


Regards,
Víctor



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list