Newsgroups: comp.lang.c Path: utzoo!henry From: henry@utzoo.uucp (Henry Spencer) Subject: Re: 64 bit ints Message-ID: <1988Nov4.183818.21555@utzoo.uucp> Organization: U of Toronto Zoology References: <6264@june.cs.washington.edu> <225800084@uxe.cso.uiuc.edu> <8803@smoke.BRL.MIL> <2074@ficc.uu.net> Date: Fri, 4 Nov 88 18:38:18 GMT In article <2074@ficc.uu.net> peter@ficc.uu.net (Peter da Silva) writes: >> ... int has always been intended to be the >> integer type "most convenient for the machine". > >What is the most convenient type for a 68000? 16-bit ints are much faster >(twice as fast for loads and stores) but 32-bit ints fit the register >architecture better. You have just discovered Excedrin Headache number 68000 for compiler implementors. Which is why some 68000 C compilers go one way and some the other. The 68000 actually does pretty well at supporting 16-bit ints, so I don't think "not fitting the register architecture" is a big problem. The hard part is that it supports 32 bits well enough to be tempting (especially since sizeof(int)==sizeof(char*) reduces breakage of poorly- written programs) but not well enough for it to be the clear choice. It sort of depends on whether you view the 68000 as a cut-down 68020 (in the same way the 8088 is a cut-down 8086 -- all the 8088 compilers that I know of use 16-bit ints even though 8 would be faster!) or as a machine in its own right. -- The Earth is our mother. | Henry Spencer at U of Toronto Zoology Our nine months are up. |uunet!attcan!utzoo!henry henry@zoo.toronto.edu