Revaldinho's written up the story of our performance and code density evolution, using Bruce Clark's pi spigot program as a benchmark.
You'll notice that
- - the OPC5 has evolved via two intermediate forms into the OPC6.
- our code size is still about 1.5x the 6502 but much better than it was
- our cycle count is around 3x better than the 6502 when we write our best code
- it's not too hard to just translate 6502 code into OPC5 or OPC6, but it won't be great code
- our clocks-per-instruction with the best code and best machine is very respectable
In the course of writing these Pi programs, and other programs, we've identified some common errors we make - some of which are because the single-page assembler is a bit feature-limited:
- missing r0 in the source (the minimal assembler emits bad code)
- duplicate label
- failing to stack r13 (our link register)
- failing to stack scratch registers
- using ld where we intend mov
- assembling for wrong start address
- failing to account for I/O hole in memory map and placing code there by mistake
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.