Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/17/84; site opus.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!genrad!panda!talcott!harvard!cmcl2!seismo!hao!nbires!opus!rcd From: rcd@opus.UUCP (Dick Dunn) Newsgroups: net.lang.c Subject: Re: Code Generation (register byte, short...) Message-ID: <264@opus.UUCP> Date: Tue, 26-Nov-85 01:02:04 EST Article-I.D.: opus.264 Posted: Tue Nov 26 01:02:04 1985 Date-Received: Thu, 28-Nov-85 04:08:19 EST References: <29@brl-tgr.ARPA> Organization: NBI,Inc, Boulder CO Lines: 32 > [on a 68000 where short*short is a single instruction, but int*int requires a > procedure call ] > > Thats what you get for using a machine that calims to be 32-bit when it really > is 16-bit. Dont know how to help you with your gripe but "int" exists to > represent the natural size of the machine..... in my interpretation that > would be the size that works best, fastest etc. Did you escape from a marketing department, or what? Go tighten up your tie 'til your eyes bug out. The 68000 and 68010 are described by Motorola as 16-bit microprocessors. See, for example, the manual called "MC68010 16-BIT VIRTUAL MEMORY MICROPROCESSOR" from Motorola. Hint: Even the title will (might?) give you a clue. They didn't start calling th 68000 family 32-bit processors until the 68020, in spite of having 32-bit registers and 32-bit add/subtract/logical instructions all along. A choice of 16-bit ints for C for the 68000/68010 would be idiotic. (Yes, I know a few people have done it. That makes it no less idiotic.) Issues are at least array indices and differences of pointers. Really, there's a matter that some machines don't have a handy-dandy black and white definition of what the natural size of integer for the machine is. 32-bit ints make a lot of sense for the 680[01]0, but multiplies and divides are expensive. Implementor makes a choice and you do what you can. More modern languages ought to be able to cope with machines which don't have a single obvious choice of length for all possible forms of integer. -- Dick Dunn {hao,ucbvax,allegra}!nbires!rcd (303)444-5710 x3086 ...If you get confused just listen to the music play...