<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Thu, 24 Jun 1993 14:22:59 +0100
From   : Mik Davis <davism@...>
Subject: Re: Unrolling loops & fast routines

>Mik,
>
>The only way to get the routine as fast as the above is to use it to
>copy from and to page aligned buffers. The easiest way to guarantee
>that you can do this is to DIM more memory than you need, and use
>another variable as your base:

  Yes, I realised last night that it was far simpler to do

DIM buffer_space% 2048
buffer%=buffer_space%-1
REPEAT
buffer%=buffer%+1
UNTIL buffer% MOD 256 =0

  than to mess about with multi-byte arithmetic

>If you _always_ want to copy from the same buffer to screen memory,
>then the preamble at the start of the routine can be reduced, making
>the code:

>Note:
>1  Your code will not work if you are using a second processor.

  Yes, I'm working on that one... 

>2  Your code will give strange results if the screen has H/W
>   scrolled since the last time the screen was cleared.

  It won't have, I can guarantee that

>Hope that this has been helpful!

  Yes, Thanks, my software is working fine now. 

        Mik Davis at Aston University. E-Mail davism@...
May a Misguided Platypus lay its Eggs in your Jockey Shorts
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>