http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
--- Comment #8 from Jeffrey Yasskin 2011-03-17
01:09:38 UTC ---
Ah, I didn't check Posix, specifically
http://pubs.opengroup.org/onlinepubs/9699919799/functions/lrint.html. I now
agree that gcc can't optimize this without -fno-math-errno.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #7 f
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
--- Comment #6 from sgunderson at bigfoot dot com 2011-03-16 22:59:53 UTC ---
(In reply to comment #5)
> So, there's no glibc bug, but I don't think this makes a compelling case for
> any particular gcc behavior. The "implementation" is gcc+glibc,
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
--- Comment #5 from Jeffrey Yasskin 2011-03-16
17:21:57 UTC ---
According to C99, lrint does not produce domain errors. It may only produce
range errors (and isn't required to):
"The lrint and llrint functions round their argument to the nearest
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
--- Comment #4 from Richard Guenther 2011-03-16
12:16:24 UTC ---
(In reply to comment #3)
> (In reply to comment #2)
> > But the lrintf() man page says explicitly that these functions cannot set
> > errno. Is this the man page being too glibc-spe
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
--- Comment #3 from Richard Guenther 2011-03-16
12:14:35 UTC ---
(In reply to comment #2)
> But the lrintf() man page says explicitly that these functions cannot set
> errno. Is this the man page being too glibc-specific, or something else?
Yes,
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
--- Comment #2 from sgunderson at bigfoot dot com 2011-03-16 12:03:40 UTC ---
But the lrintf() man page says explicitly that these functions cannot set
errno. Is this the man page being too glibc-specific, or something else?
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48139
Richard Guenther changed:
What|Removed |Added
Status|UNCONFIRMED |RESOLVED
Resolution|