8

Much like the VAX, the 6809 and 6309 have a preponderance of indirect addressing modes (in VAX parlance, "deferred"), though neither go so far as to include a VAX-like doubly-indirect mode.

To what extent were these modes useful/actually used?

I can obviously think of contrived instances where these would be a good fit, but it's difficult to determine whether these would show up in the "real world". It's worth noting that the 6809's cousin, the 68HC12, removed all but two of these indirect modes.

  • Note that the 6812 is actually a different branch of the family that split off around 1977-78, before the 6809 was introduced. So it certainly wasn't the case that the addressing modes were later removed from members of the 6809 family, but that the (always much, much more popular, though quietly in embedded applications) 6801 series simply lasted longer than than the CPUs designed for computers rather than embedded systems. – Curt J. Sampson Oct 14 at 16:41
13

The 6809 offers to combine indirect with either a fixed extended (16 Bit) address or all indirect indexed modes. These modes are extremely useful for all kinds of linked list and/or table processing. Essentially the basics for any operating system, thus simplifying and speeding up OS programming including any kind of list defined I/O. Especially the latter is quite powerful in a concurent setup (*1). And that's where the 6809 was targeted at: modular multi-process environments. Such an environment is filled with dynamic structures that are built and managed at runtime, usually not holding many predefined addresses and structures.

The 68HC12 was optimized as a single-chip controller, not a general purpose CPU. Unlike a general-purpose environment, a controller does usually operate on predefined structures with no or just a small amount of dynamic structures.


*1 - Think for example an I/O subsystem where each pending request is defined with a control block holding the address of a data buffer and a pointer within. During an interrupt to send or receive a character, X could point to the control block for the actual operation (so no need to move that block into a fixed address) and use the actual buffer pointer within the structure with [X+offset] in a single operation. Increment (or decrement) it the same way and finish the I/O routine.

  • 4
    OS-9 is a good real-world example to justify the theoretical aspects of this answer. – Brian H Oct 19 '18 at 18:18
10

Although not too obvious, almost every feature of 6809 looks like specially made for high level languages like C and for 'serious' systems like OSes.

For example, indirect addressing is convenient to dereference the pointers (like a=*b in C), stack-offset addressing simplifies working with local stacked variables, position-independent code simplifies linking executables and loading them into the memory before they are run (no need to fix myriads of absolute addresses).

68hc12 is an embedded controller, and while still having features for high level languages (indirect addressing, stack-offset addressing), has no need for position-independence (as the embedded system executes code from a fixed ROM).

  • 4
    Its worth noting that the designers of the 6809 stated at the time that they believed position independent code was critical, because they believed it would enable an environment where code on ROMs could be platform independent, which they saw as an important future development. Unfortunately, that never really happened. – Jules Oct 19 '18 at 17:56
  • 2
    OS-9 was (relatively) mainstream with the CoCo and made good use of the 6809 features to deliver a tiny multiuser kernel with preemptive multitasking and advanced support for device drivers. All notable features for any 8-bit OS. – Brian H Oct 19 '18 at 18:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.