This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/57974] std::pow(std::complex<long double>(0),1) returns (-nan,-nan)
- From: "ubizjak at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 25 Jul 2013 16:12:35 +0000
- Subject: [Bug middle-end/57974] std::pow(std::complex<long double>(0),1) returns (-nan,-nan)
- Auto-submitted: auto-generated
- References: <bug-57974-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57974
--- Comment #8 from UroÅ Bizjak <ubizjak at gmail dot com> ---
(In reply to Paolo Carlini from comment #7)
> However it's still not clear to me why this inconsistency doesn't happen
> with clang or icc, for example. I'm not convinced we are doing our job in
> the best way and I don't think we are going to make users happy. It's pretty
> easy to internally call in the c++ library or in user code another builtin
> which does produce a -inf without the user knowing and then passes it to a
> function like exp. If some of our builtins produce something which our other
> builtins aren't able to handle consistently we are looking for trouble.
But, then -funsafe-math-optimizations shouldn't be used.