TIP: Click on subject to list as thread! ANSI
echo: power_bas
to: ALL
from: KROGG
date: 1998-03-31 23:57:00
subject: Re: pb3.5:asm shl di,6

From: Krogg 
Subject: Re: pb3.5:asm shl  di,6   why dont it werk?
 
Tech@SoftByteLabs.com wrote:
>
> On Tue, 31 Mar 1998 12:12:38 -0500, Krogg
>  wrote:
>
> >I was testing(for speed) some inline asm code for plotting points to mode
> >13h in powerbasic 3.5 and ran in to an error trying the following:
> >asm     mov     ax,&ha000
> >asm     mov     es,ax
> >asm     mov     bx,y%
> >asm     mov     di,bx
> >asm     xchg    bh,bl
>
> >asm     shl     di,6     <------------this line gives error
>
> Change it to this...
>
> asm     mov     cl, 6
> asm     shl     di, cl
>
> SHL can only use 1 or CL
>
> >asm     add     di,bx
> >asm     add     di,x%
> >asm     mov     al, col?
> >asm     mov     [es:di],al
> >this is what i get  "Error 497: Assembler syntax error"
> >I dunno why it wont work.
> >I really wanted to test this code because it uses the shl instead of a
> >mul,the shl is supposed to be faster.Can anyone shed some light on this 
or
> >me?
> >
> >
I dont see my reply come up yet but as to
mov [es:di],al   <-------needed to be an integer
i changed it to
stosb
the sad thing is that the rouitine is slower than the one using muls
maybe the stosb op is slower than the mov one?
 
--
                      THE
                  
        /\         \\     //         /\
       /  \         \\   //         /  \
      / /\/        /""""""\         \/\ \
     / /  SEE HIS (  /   \ \  SEE HIS  \ \
     \ \   FACE    \/ \/   SMILE   / /
      \ \          /   W   \          / /
       \ \        /\_|||||_/\        / /
       /  \      //   |||   \\      /  \
      / /\ \    //     '     \\    / /\ \
     / / / /      \ \ \ \
     \ \/  \_______________________/  \/ /
      \_________________________________/
         krogg.no.to.spam@inspace.net
          Remove no.to.spam to reply
 http://www.inspace.net/~carcher/krogg/aani.htm
  Gory javascript animations for your enjoyment
 
*** QwkNews (tm) v2.1
 * [TN71] Toast House Import
--- GEcho 1.20/Pro
---------------
* Origin: Toast House Remote (1:100/561)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.