[Coco] Unit tests on an 8 bit machine

Sean Conner sean at conman.org
Fri Dec 1 23:33:05 EST 2023


It was thus said that the Great Joel Rees via Coco once stated:
> On Sat, Dec 2, 2023 at 12:57 PM John Murphy via Coco
> <coco at maltedmedia.com> wrote:
> >
> > “all the other CPUs” it supports”??
> > It only supports the 6809 and the Hitachi clone, the 6309.
> 
> But all those object formats! And input formats! And automatically
> doing 6800->6809 source code conversion, if you ask it to!!
> 
> (They do come in handy, but they also make the code more complex.)

  They do.  The hardest portion of writing the assembler so far---parsing
the 6809 indexing mode.  Parsing expressions was pretty trivial after that.
I've also found it easier to change old assembly code than to try to change
the assembler to deal with old code (and I don't have much old code to deal
with).

> > “And ... it's a SEVEN pass assembler?”
> > Not as far as I can tell. The docs only mention first and second passes.
> 
> As many as seven, if I recall correctly, depending on settings. It can
> optimize offsets without hints.

  I'm ... not sure how I feel about that.  It means the source code might
not match the binary code, and some people worry about that.  My own
assembler will warn about such issues though, and the only "optimization" it
does is change '0,reg' to ',reg' (even when the expression before the comma
evalutes to 0), but you can easily override that if you want.

  -spc



More information about the Coco mailing list