On Thu, Jan 27, 2005 at 03:07:39PM -0600, Guy Rouillier wrote: > Frank D. Engel, Jr. wrote: > > I think it is an internal thing with gcc that the size of a pointer > > and > > sizeof(int) are always the same, regardless of machine word size... > > with a 64-bit binary, sizeof(int) and sizeof(void *) should both be 8, > > which still causes them to be equal. > > On AMD64, gcc produced: int 4 long 8 pointer 8 And this is as it's supposed to be. 32-bit architectures are usually ILP32 (ints, longs and pointers are 32 bits) whereas 64-bit architectures are generally LP64 (longs and pointers are 64 bits but ints are *not*). I'm sure you could search for reasons why this is but this is how it is. Have a nice day, -- Martijn van Oosterhout <kleptog@xxxxxxxxx> http://svana.org/kleptog/ > Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a > tool for doing 5% of the work and then sitting around waiting for someone > else to do the other 95% so you can sue them.
Attachment:
pgpr9kDf6FNci.pgp
Description: PGP signature