Is the motorola 68hc08 really 8bit?

I have a basic theory question about the motorola 68hc08 micro-controller.

How can it be an 8 bit micro-controller when it uses 16bit addresses?

I know it has a mix of 8 bit and 16 bite registers.

Reply to
Lawrence Fox
Loading thread data ...

the 'size' of a processor is usually defined by the number of bits in the registers and the number of bits most instructions handle.

But it isn't always really clear. Some registers are 8 bits, some are 16, some instructions handle 8 bits, other handle 16 bits at a time. And then the problem when a processor is 16 bits internally, but 8 bits externally (for example, 8088, 80386SX,68008).

A processor with only 8 address bits would be quite useless, maybe only useful for the smallest of the smallest controllers.

Jeroen

Reply to
Jeroen

Hi,

I would define the size of an processor by the width of its databus.

8 bits databus = 8 bits processor 16 bit databus = 16 bits processor etc. etc.

The size of the address bus just reflects the size of the memory which can be accessed.

8 bits address bus = 256 bytes memory 16 bits address bus = 64k memory 24 bits addressbus = 16M memory etc. etc.

regards

Jens

"Lawrence Fox" skrev i en meddelelse news:41fb91a3$ snipped-for-privacy@news.comindico.com.au...

Reply to
Jens Gydesen

So, you'd call an ST-62 a 1 bit processor?

Best regards, Spehro Pefhany

--
"it's the network..."                          "The Journey is the reward"
speff@interlog.com             Info for manufacturers: http://www.trexon.com
 Click to see the full signature
Reply to
Spehro Pefhany

Because it has an 8 bit ALU.

Reply to
Mark

As a rough rule of thumb: because an 8-bit value is the largest it can add to something else of the same size in a single opcode. I.e. if you find a CPU can support n bit operands in its "add" opcode, that's an 8-bit CPU.

Most processors have wider addresses (and sometimes external buses) than data. Someone, sometime probably wrote a PhD thesis explaining why exactly that has to be so...

--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.
Reply to
Hans-Bernhard Broeker

micro-controller.

Didn't you mean to say that's an n-bit cpu?

Reply to
Mark

Of course. Silly typo. Thanks for catching it.

--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.
Reply to
Hans-Bernhard Broeker

You probably intended to write "n-bit CPU".

Do you realise that this rule makes the 8080 and Z80 into 16-bit processors?

| Add HL register pair (16 bits) to register pair BC, DE, HL or to SP and | store result in HL. | | Z80 mnemonic: ADD HL,ss OP Code: 00ss1001

It is quite common for n-bit processors to include a limited number of operations on 2n-bits.

--
Göran Larsson     http://www.mitt-eget.com/
Reply to
Goran Larsson

As far as I am concerned they are and always were. They also handle stack and addressing in 16 bit chunks. Now the 6502 was definitely an 8 bitter. Very annoying.

--
"If you want to post a followup via groups.google.com, don't use
 the broken "Reply" link at the bottom of the article.  Click on 
 Click to see the full signature
Reply to
CBFalconer

If they have a fully working 16-bit addition, then yes, that IMHO makes them 16-bit processors.

And I did say this was a rule-of-thumb, didn't I? The distinction isn't really as well-defined as to allow for a simple, definitive answer, anyway. Nor does it truly matter.

Calling a CPU "8-bit" (or whatever) is just that: name-calling. It has no meaning well-defined enough that engineers (as opposed to, say, marketroids) should worry much about getting it right --- there *is* no fully correct definition. Some designer, somewhere, sometime was probably daring enough to build a processor with a 1-bit external memory interface, 128-bit addressing, a 32-bit ALU, and (a lot of)

8-bit general-purpose registers.

It may be helpful to look at the actual implementation of those operations, though. E.g., a microcoded processor that actually does a sequence of 2 additions of sequential 8-bit values, when instructed to do a 16-bit add, wouldn't really qualify as a 16-bit CPU. Yet the CPU's machine language could still justifiably be called a 16-bit one, simply because it's easily imaginable that the next iteration of the chip will do this operation in one "step", with a real 16-bit ALU.

Looking at the data and address bus widths, OTOH, doesn't really tell you anything about the "bittyness" of the CPU. Even less so if there's any cache in the chip design. Otherwise, the 386SX would have to be called a 16-bitter (yet it runs the exact same software as a full 386), and a modern Pentium4 a 128-or-whatever bitter.

--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.
Reply to
Hans-Bernhard Broeker

Funny - the Z80, regarded a 16-bit CPU previously, now qualifies as a

4-bit CPU (AFAIK it had a 4bit ALU).
Reply to
Andreas Kaiser

And the ST-62 (and the 6804, IIRC) would be one-bit processors.

Best regards, Spehro Pefhany

--
"it's the network..."                          "The Journey is the reward"
speff@interlog.com             Info for manufacturers: http://www.trexon.com
 Click to see the full signature
Reply to
Spehro Pefhany

You are the first person I have seen that claims that the two processors that basically started the 8-bit processor segment are 16-bit processors.

Yes, but having a rule-of-thumb that classifies the the two most known 8-bit processor as 16-bit processors does not make sense.

The Z80 isn't microcoded, but it does the 16-bit add as a sequence of 4-bit adds. It also does 8-bit add as a sequence of 4-bit adds. So you are saying that the Z80 is a 16-bit processor that doesn't qualify as a 16-bit processor?

I find it hard to view the 8080 and Z80 as anything other than 8-bit processors. The accumulator (A) is 8 bits and most ALU operations operate on the accumulator. That some special case 16-bit operations are included for fast address calculations does not make it a 16-bit processor.

--
Göran Larsson     http://www.mitt-eget.com/
Reply to
Goran Larsson

... snip ...

I find it hard to view the 8080 as anything other than a 16-bit processor. The accumulator (HL) is 16 bits, and can conveniently be exchanged with general purpose registers, or even the top of stack. Its content can also be transferred to the program counter, or the stack pointer, or used as an indirect address. Left shifts are trivial, although right shifts are much more awkward.

--
"If you want to post a followup via groups.google.com, don't use
 the broken "Reply" link at the bottom of the article.  Click on 
 Click to see the full signature
Reply to
CBFalconer

The 8080 HL register pair is seriously dysfunctional as an 16-bit accumulator. How much work can be done with an accumulator that only supports the ALU operations ADD, INC and DEC? For everything else data has to be moved 8 bits at at time into the real accumulator, the A register.

Sounds more like an address register than an accumulator.

--
Göran Larsson     http://www.mitt-eget.com/
Reply to
Goran Larsson

I take it you're being facetious here.

If not, this line of argument would mean that the Atmel AVR family (which is about as "pure" a 8-bit processor there is) would be considered 16-bit processors because there's an ADIW instruction allowing one to add a value to a concatenated pair of 8-bit registers.

Reply to
Everett M. Greene

The very fact that the processor even _has_ a concept of "concatenated pairs of 8-bit registers" already settles that, to some point. That's quite a strong deviation from a "pure" 8-bit processor design, IMHO. Especially if compared to another candidate already mentioned in this thread: the 6502.

Actually, I doubt that one and the same processor can meaningfully be qualified both as "a pure 8-bit design" and "geared towards being programmed in C". C's requirement of a minimum integer width of 16 bits pretty much precludes that.

--
Hans-Bernhard Broeker (broeker@physik.rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.
Reply to
Hans-Bernhard Broeker

Who, me? About this critical classification? I also have numerical statistics to do with pins, dip packages, number of angels, dancing on.

--
"If you want to post a followup via groups.google.com, don't use
 the broken "Reply" link at the bottom of the article.  Click on 
 Click to see the full signature
Reply to
CBFalconer

This is getting silly. If there IS a definition of 8 bit/16 bit/32 bit etc. etc. it's quite simple: an N bit processor is one in which the internal data bus is N bits wide. That covers microcontrollers with no external bus, as well as processors that are N bit internally but (usually transparently) N/2 (4,8 etc) bits to the external bus.

The question of how addresses are dealt with is quite separate, and a whole generation of programming effort has been lost to a lunatic address paging scheme, but that's life.

Paul Burke

Reply to
Paul Burke

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.