View unanswered posts | View active topics It is currently Thu Mar 28, 2024 10:15 am



Reply to topic  [ 18 posts ]  Go to page Previous  1, 2
 Memory Addresses 
Author Message

Joined: Wed Jan 09, 2013 6:54 pm
Posts: 1780
BigEd wrote:
I can't find it now, but I'm pretty sure I read a story recently of an effort back in the day to write and debug a fast copy routine...

Found it: http://blog.moertel.com/posts/2013-12-1 ... -hack.html (it's 6809)
Cheers
Ed


Sat Jan 25, 2014 7:42 pm
Profile

Joined: Tue Dec 31, 2013 2:01 am
Posts: 116
Location: Sacramento, CA, United States
BigEd wrote:

Nice link, Ed! The 6809 can be quite versatile in the hands of a true 8-bit hacker, but the technique described is very closely coupled to the 6809 architecture. Although I always somewhat admired the 6800 as "the grand-daddy" of all the 6xxx family (with which my brain feels the most comfortable) it can't be ignored that its instruction set can be brutally inefficient for some of the simplest tasks. Another example is pushing and pulling the X register:
Code:
... from Bob Uiterwyk's 6800 BASIC interpreter ...
 02CA DF 38    PUSHX   STX  PUSHTX
 02CC DE 3A            LDX  XSTACK
 02CE 09               DEX
 02CF 09               DEX
 02D0 DF 3A            STX  XSTACK
 02D2 36               PSHA
 02D3 96 38            LDAA PUSHTX
 02D5 A7 00            STAA 0,X
 02D7 96 39            LDAA PUSHTX+1
 02D9 A7 01            STAA 1,X
 02DB 32               PULA
 02DC DE 38            LDX  PUSHTX
 02DE 39               RTS
 02DF DE 3A    PULLX   LDX  XSTACK
 02E1 EE 00            LDX  0,X
 02E3 7C 00 3B         INC  XSTACK+1
 02E6 7C 00 3B         INC  XSTACK+1
 02E9 39               RTS
 

The 6809 equivalents would benefit by at least an order of magnitude from the availability of the U register, with a simple pshu X and pulu X.

Similar things can be stated regarding 6502 vs. 65802. Garth and saipan59 discussed this at length here, but the best message that I got from it is that the updated versions of each family were much improved from the originals, in a variety of ways.

Mike


Sun Jan 26, 2014 8:02 pm
Profile

Joined: Wed Jan 09, 2013 6:54 pm
Posts: 1780
BigEd wrote:
BigEd wrote:
I can't find it now, but I'm pretty sure I read a story recently of an effort back in the day to write and debug a fast copy routine...

Found it: http://blog.moertel.com/posts/2013-12-1 ... -hack.html (it's 6809)
Cheers
Ed

Because I landed on the previous page and had forgotten that I'd found the lost article, I went looking again. And found something similar for the Z80 in the Spectrum, for the game Starion, by David Webb, apparently. There's an interview with him here.


Fri Aug 21, 2015 8:26 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 18 posts ]  Go to page Previous  1, 2

Who is online

Users browsing this forum: No registered users and 9 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group
Designed by ST Software