64 bit architectures and C/C++
John R. MacMillan
john at sco.COM
Thu May 2 08:21:12 AEST 1991
|>4. Would it be better not to have a 32-bit data type and to make int
|>be 64 bits? If so, how would 32- and 64- bit programs interact?
|
|It is necessary to have 8, 16, and 32-bit data types, in order to be able
|to read data from files.
It's not necessary, but it does make it easier.
|I would suggest NOT specifying a size for the int
|data type; this is supposed to be the most efficient integral data type
|for a particular machine and compiler.
|
|[...]
|
|short 16 bits
|long 32 bits
|long long 64 bits
|int UNSPECIFIED
|void * UNSPECIFIED
Problem with this is that I don't think sizeof(long) is allowed to be
less than sizeof(int) which would constrain your ints to 32 bits.
More information about the Comp.lang.c
mailing list