TIP: Click on subject to list as thread! ANSI
echo: 80xxx
to: NICK COONS
from: CRAIG HART
date: 1997-02-11 09:09:00
subject: SHL.

 > Hi Tom!
 >> For 386+, use SHLD (but then you could simply use EAX as well).
 >        Is there a special 32-bit version of every instruction for use
 > with
 > extended registers?  Example:  SHLD as opposed to SHL.
Make no mistake.. the 32 bit version of SHL is SHL. SHLD is an entirely
different instruction.
Opcode: SHLD dest,src,count     (386+)
SHLD shifts "dest" to the left "count" times, but instead of adding 0 as the 
shifted-in bit, the contents of "src" (MSB first) are used as the shifted-in 
bits. only the 5 lowest bits of "count" are used, so the most you can shift 
in is 32 bits (but more is superfolous[sp?]). "src" is left unaltered.
"dest" can be register or memory, 16 or 32-bit
"src" can be register 16 or 32-bit
"count" an be a constant, or CL register, and is always 8-bit.
now, if "src" = 0, SHLD is the same as SHL.
the advantage of this opcode? mostly in register manipulation, or fixed point 
math.
    Craig
--- FMail/386 1.0g
---------------
* Origin: Communications Barrier BBS (03) 9585 1112, 24hrs (3:632/533)

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™.