Re: mingw-64 80 bit precision for doubles works

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12/17/2014 7:56 AM, navin p wrote:
> Hello,
>    Visual Studio 2010 cannot build x64 executables with 80 bits
> extended precision for doubles. Atleast it has been removed in Visual
> Studio 2013 saying not supported on x64 and ARM platforms.
>
> _MCW_PC (Precision control)
>
> (Not supported on ARM or x64 platforms.)
>
>
>   How can gcc/mingw-64 build x64 executables with double precision set
> to 80 bits?
>
> I get rounding errors when i do %.18g for doubles on windows but
> Visual Studio truncates the last digits for 2^61 and all.
>
>
gcc supports 80--bit long double, but printf format %.18g casts to
64-bit double prior to formatting, even if you link a printf with long
double support (which the Microsoft one lacks).
As you hinted, you would also need to over-ride the Windows X64 run-time
default of 53-bit precision mode, but this will apply only to x87 code
(such as explicit long double), while the default for double is SSE2 on X64.
> -- 
> Tim Prince




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux