| Charles A. Crayne 2005-04-26, 3:57 pm |
| On Wed, 20 Apr 2005 19:11:48 +0000 (UTC)
"Jim Leonard" <spamtrap@crayne.org> wrote:
:Geez, I hadn't considered index registers at all... I was still in
:AX/BX/CX/DX land in terms of mindset. I have much to learn :)
Let me expand a bit upon my previous, short, answer.
The Intel 'X86' product line actually started with the Intel 8008, which
had no direct memory addressing mode. Instead, all memory accesses were
indexed by concatenating the 'H' and 'L' registers. Therefore, to read
from, or write to, a memory location, one had to do something like this:
NXTMVE, LHI MOVENO/256
LLI MOVENO
LAM /MOVE NUMBER
Since H and L were independent 8-bit registers, to properly increment the
memory pointer, one had to do something like this:
CAL INCPTR
. . .
INCPTR, INL /NEXT ADDR
RFZ /SAME PAGE
INH /NEXT PAGE
RET
Note that I am using the original Intel mnemonics here. If you can't guess
the MASM equivalent, say so, and I will translate for you.
-- Chuck
|