Article View: comp.arch
Article #1641Re: DECSYSTEM 20
From: Bruce Robertson
Date: Sun, 23 Jul 1989 22:56
Date: Sun, 23 Jul 1989 22:56
33 lines
1840 bytes
1840 bytes
In article <443@anasaz.UUCP> john@anasaz.UUCP (John Moore) writes: I found the ability to define multiple stacks to be very handy. A FORTH interpreter can be written in that instruction set that is very efficient. Also, I once wrote a binary tree balancing routine that used a pair of recursive co-routines. It took about 30 instructions for both routines. Try that with today's architectures! The 680x0 can use any of its 8 address registers as stack pointers for data. The only thing that makes its "stack pointer" register special is that the hardware uses it for subroutine calls, interrupts, etc. If you want to use one of the other stack pointers for flow control, you have to do it with an instruction sequence: ; Call subroutine using A0 as a stack. move.l #1f,-(a0) bra subroutine 1f: ; Return from subroutine through A0 (trashes a register) move.l (a0)+,a1 jmp (a1) In other words, a FORTH interpreter could be made as efficient on the 680x0, but the binary tree balancing routine might take a little more work. I like the way the PDP-11 treats the program counter as a general register. You can play a lot of tricks with that! -- Bruce Robertson Hundred Acre Software, Reno, NV Domain: bruce@pooh.com UUCP: ...!uunet!tahoe.unr.edu!heather!bruce
Technical Details
Message-ID:
<BRUCE.89Jul23155646@heather.pooh.com>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!tahoe!heather!bruceReferences:
<3256@wpi.wpi.edu> <EGDORF.89Jul21195924@zaphod.lanl.gov> <443@anasaz.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!tahoe!heather!bruce From: bruce@heather.pooh.com (Bruce Robertson) Newsgroups: comp.arch Subject: Re: DECSYSTEM 20 Message-ID: <BRUCE.89Jul23155646@heather.pooh.com> Date: 23 Jul 89 22:56:53 GMT References: <3256@wpi.wpi.edu> <EGDORF.89Jul21195924@zaphod.lanl.gov> <443@anasaz.UUCP> Sender: bruce@pooh.com (Bruce Robertson) Organization: Hundred Acre Software, Reno, NV Lines: 33 In-reply-to: john@anasaz.UUCP's message of 23 Jul 89 15:11:21 GMT