Re: size of long long int on amd 64

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

 



Hi Nelson,

>> ...
>> I'd have thought that on a 64-bit word-size architecture, int would be
>> 64-bits big, long would be 128-bits big, and long long would be
>> 256-bits big.
>> ...

> No, the only requirement on C's integer data types is that
> 
> sizeof(char) <= sizeof(short) <= sizeof(int) <= sizeof(long) <= sizeof(long
> long)

I'm aware of the minimum size requirements of the types, as per ISO 9899 or
ISO 14882.

There are also semantic expectations of the data types, but those are not
expressed in the standard.  They are left to the implementer of the compiler
on the given architecture and operating system.

I was expressing my expectations.  Hence the "I'd have thought..." preface.

Is there a "Design & Evolution of C", something akin to Stroustrup's "Design
& Evolution of C++"?

Sincerely,
--Eljay


[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