Subject: Re: Bits, bytes and words...
To: Andrew Reilly <andrew-netbsd@areilly.bpc-users.org>
From: Johnny Billquist <bqt@softjar.se>
List: netbsd-users
Date: 12/12/2006 08:55:21
Well, the PDP-10 uses 36 bit words, but a byte is a varaible sized 
quantity that is also handled in hardware, by byte instructions. And you 
can address individual bytes with those instructions.

So on a PDP-10, a byte can be the same as a word if you want to, or it 
can be just 1 bit, if that amuses you more. Most people tend to use 7 
bit bytes, though (5 to the word with one bit to spare). In some 
circumstances 6 bit bytes were optimal, and occasionally 9 bit bytes 
were nice (evenly divisible by 36).

A byte is just a convenient small unit to store something in. There is 
no one definition of how much a byte can store.

	Johnny

Andrew Reilly wrote:
> On Mon, 11 Dec 2006 19:50:08 +0100
> Johnny Billquist <bqt@softjar.se> wrote:
> 
> 
>>Now, bytes on the other hand could lead to a very funny discussion that 
>>many today don't appreciate fully.
> 
> 
> There are still quite a few strictly word-addressed machines in
> the embedded/DSP arena. That is,
> sizeof(char)==sizeof(int)==sizeof(long)==sizeof(void*)==1
> [and they all occupy 16,18,20,24,32,40, or 48 bits: take your
> pick; mostly it's obvious for the processor architecture;
> sometimes it depends on the address range...], and you need
> software support and special APIs to deal with packed
> byte-strings...  This is also how many older mainframes of the
> Cray, Burroughs or PDP-10 vintage operated. That's the "true"
> origin and meaning of the term "word".  Any of this newfangled
> PDP-11/Microsoft-mandated fixed size rubbish is just
> unnecessarily confusing.  Or, rather, it's confusing because the
> significance of the term isn't quite as obvious on modern,
> byte-addressed machines that have a whole slew of plausible
> "word" sizes.
> 
> Personally, I use "word" in an algorithm-specific sense to mean
> any atomically readable/writeable quantity larger than a byte
> that could plausibly be ported to a word-addressed machine and
> still work correctly.
> 
> Cheers,
>