[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ARM and 6502
Rubywand <rubywand@swbell.net> wrote:
> There are some instructions which would be very nice to have. One
>would be an address-relative JSR. Another is some way to handle data and
>code address bank switching. (Another is a way to set up multiple large
>stacks.) Anyway, it looks like ARM makes it possible to define a 'super
>6502'. Is this the case?
I would consider a set of 'macros' that are called like any other 6502 routine,
but run pure ARM. A good example is miltiply. Change the JSR to your multiply
routine to a "trap" that runs the ARM multiply instruction. Here we get a huge
advantage in speed. I think my best 16 bit multiply was between 400 and 500
cycles where the ARM uses a Boothe algorithm multiplier so it would be about 16
ARM cycles. You could build up a library of routines like this and slowly
transition to pure ARM code kind of like the way Apple went from 68000 to
PowerPC. Once you are doing ARM instead of emulation, we are talking running
hundreds of times faster.
I'm still looking at the best way to get started and I think it is with a
simple 7 series ARM on a card for a slot and an assembler or something and a
way to write to it from the Apple side.
Charlie