Re: double and float in GCC

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

 



On Thu, Jun 23, 2016 at 02:03:38AM -0700, Kondi wrote:
> I built GCC toolchain for my custom CPU. My custom CPU have 32-bits floating
> point unit so I set DOUBLE_TYPE_SIZE 32, to prevent convertion from float to
> double. Additionally in newlib I define _DOUBLE_IS_32BITS. 
> When I ran the GCC test, buildin-math-4.c fails and exactly:
>  
> if (sizeof(int)*__CHAR_BIT__ <= __DBL_MANT_DIG__) {

> The IF condition is met,

Assuming your ints are 32 bits (and your __CHAR_BIT__ is 8), this means
your __DBL_MANT_DIG__ is bigger than 32.  That's not consistent.


Segher



[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