<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Mon, 18 Jul 1994 16:46:29 GMT
From   : rtr@... \(\).bbc.co.uk (Richard Russell \(KW 36684\))
Subject: Re: Steve's emulators.

Chris,

> I have a bit of a problem which I think I could really speed up - how can 
> I do relative branches? What I'm doing at the moment (basically) is:
(code deleted)
> Is there a better way of doing this? In the 256^3 speed test this is *by 
> far* where I lose my speed.

If your problem is the fact that the displacement is only 8-bits, and you
therefore need to test its sign, you could convert the displacement to a 16-bit
(or even 32-bit) offset using CBW (and CWD if necessary) then do a 16-bit or
32-bit addition on P.  Another example of assembler winning out over C!

Richard.
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>