sl195@cc.usu.edu (A banana is not a toy) (01/03/91)
I'm trying to get SAS/C5.10's asm assembler to compile, and it won't take MOVE.L #0(A2,D0),D2 or MOVE.L (0,A2,D0),D2 any hints on making this work? (i.e. what's the obvious answer that's staring me in the face but I'm too spaced at the moment to see it?) THANKS in advance, netpeople!! -- All comments are my own, and many must be taken with a :-) =============================++++++++++++++++++++============================= | Demetrios Triandafilakos | James Knowles | "Remember, always remember,| | Shire of Cote du Ciel | BITNET: SL195@USU | my son -- a banana is not | | Principality of Artemesia | INTERNET: | a toy." | | Kingdom of Atenvelt | sl195@cc.usu.edu | - The Wise Guru | =============================++++++++++++++++++++============================= Be all that you can be - see your local SCA Knight Marshal now.
lphillips@lpami.wimsey.bc.ca (Larry Phillips) (01/04/91)
In <1991Jan2.164434.45993@cc.usu.edu>, sl195@cc.usu.edu (A banana is not a toy) writes: >I'm trying to get SAS/C5.10's asm assembler to compile, and it won't take > > MOVE.L #0(A2,D0),D2 >or > MOVE.L (0,A2,D0),D2 > >any hints on making this work? (i.e. what's the obvious answer that's >staring me in the face but I'm too spaced at the moment to see it?) Well, it sort of depends on what it is you are trying to do. The '#' would seem to indicate that you want to move the address of something to d2, while the second one looks like you want to move the contents of that address to d2. Though you probably want to do the latter, I'll mention both operations... move.l a0,d2 add.l d0,d2 The above will get you the address generated by the address in a0, indexed by the value in d0, and will place the result in d2. More likely you are trying to do... move.l 0(a0,d0),d2 Which will move the contents of the longword at the address contained in a0, indexed by the value in d0 -larry -- The best way to accelerate an MsDos machine is at 32 ft/sec/sec. +-----------------------------------------------------------------------+ | // Larry Phillips | | \X/ lphillips@lpami.wimsey.bc.ca -or- uunet!van-bc!lpami!lphillips | | COMPUSERVE: 76703,4322 -or- 76703.4322@compuserve.com | +-----------------------------------------------------------------------+
ccplumb@rose.uwaterloo.ca (Colin Plumb) (01/11/91)
In article <1991Jan2.164434.45993@cc.usu.edu> sl195@cc.usu.edu (A banana is not a toy) writes: >I'm trying to get SAS/C5.10's asm assembler to compile, and it won't take > > MOVE.L #0(A2,D0),D2 >or > MOVE.L (0,A2,D0),D2 > >any hints on making this work? (i.e. what's the obvious answer that's >staring me in the face but I'm too spaced at the moment to see it?) > >THANKS in advance, netpeople!! I use move.l 0(a2,d0.l),d2 Note that you can use word or long index registers (word is sign-extended to 32 bits), so you need to specify the size. This is Manx-acceptable syntax. (I wrote a lot of "and.l 4(a4,d4.w),d5" code in a wierd inner loop a while back, so I was glad for the addressing mode's idiosyncracies.) -- -Colin