This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/34071] Poor precision of complex division __divdc3 in 64-bit on Intel
- From: "joseph at codesourcery dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Nov 2007 16:29:16 -0000
- Subject: [Bug c/34071] Poor precision of complex division __divdc3 in 64-bit on Intel
- References: <bug-34071-15342@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #3 from joseph at codesourcery dot com 2007-11-12 16:29 -------
Subject: Re: Poor precision of complex division __divdc3 in
64-bit on Intel
Excess overflows in complex arithmetic is noted on
<http://gcc.gnu.org/c99status.html> but I don't think there's a specific
bug for it. Bug 24581 deals with cases GCC gets wrong through always
converting real operands of complex arithmetic to complex type. Bug 30789
is the bug that constant folding of complex multiplication and division is
worse than the runtime arithmetic because it doesn't handle any of the
special cases at all.
Complex multiplication and division in libgcc do essentially follow what
C99 Annex G says (but GCC does not have support for imaginary types - I'm
not sure how useful or otherwise such support would be).
Some libgcc function do use wider types for internal computations (in
particular the conversions from long long to floating types) - the
suggested solution for this bug would effectively be to use XFmode in
__divdc3 instead of DFmode. You may want to avoid using the soft-float
TFmode __float128, however, and only select wider types that are
reasonably fast (or compile-time options could select implementations
with different trade-offs).
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34071