z80 timing... 6502 timing

From: Eric Smith <eric_at_brouhaha.com>
Date: Sat Apr 17 03:04:26 1999

Sellam wrote:
> Ooh! A machine code competition. I'm in! I'll do the 6502 and whoop
> EVERYONE'S ass!

Sounds like I challenge; I'm a damn good 6502 programmer, IMNSHO.

On the other hand, I've found that the 6809 often has better code density
than any other 8-bit micro. Many years ago there was a challenge on one of
the newsgroups to write the smallest routine (not necessarily the fastest)
to convert a number from 1-255 in the accumulator to roman numerals (output
by a subroutine call that prints a character). I don't remember the byte
counts, but my 6809 routine was several bytes shorter than any other
entrant. There was one famous net.personality that insisted that his 6502
code was even shorter, but he refused to post the code so his claim went
unverified.

To make my code as short as it was, I used every trick in the book and
then some. For instance, I had a table whose end was delimited by a byte
with the high bit set. The table was placed immediately *before* the code
in memory, because the high bit of the first opcode was set and could thus
end the table.
Received on Sat Apr 17 1999 - 03:04:26 BST

This archive was generated by hypermail 2.3.0 : Fri Oct 10 2014 - 23:31:43 BST