diff options
author | mrb0nk500 <b0nk@b0nk.xyz> | 2021-04-04 12:39:34 -0400 |
---|---|---|
committer | mrb0nk500 <b0nk@b0nk.xyz> | 2021-04-04 12:39:34 -0400 |
commit | 04cc80c19d763f6de4ef5c3baac5026e5e6969b3 (patch) | |
tree | 9407076966196a65faa786518a529f79daeefa76 /programs/sub-suite/subasm.s | |
parent | 35a18609864470b3dc49f3a9a6cb6ec93e57300d (diff) |
- Fixed a bug to do with how SIB operands were parsed
in the assembler.
- Rewrote more of the SuB Suite to use the new calling
convention.
- Fixed a bug to do with SIB operands in the
emulator's disassembler.
- Made the MMV instruction not require a loop prefix
for copying data.
Diffstat (limited to 'programs/sub-suite/subasm.s')
-rw-r--r-- | programs/sub-suite/subasm.s | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/programs/sub-suite/subasm.s b/programs/sub-suite/subasm.s index 56d13c2..ba8d2fb 100644 --- a/programs/sub-suite/subasm.s +++ b/programs/sub-suite/subasm.s @@ -139,8 +139,10 @@ subasm: mov s, (s) ; Get the command ID. cmp s, #7 ; Is the command ID greater than the command count? bcs @end ; Yes, so we're done. - lsl s, #1 ; No, so multiply the command ID by two. - lea.w s, (cmd_srt+s) ; Get the pointer, from the command subroutine table. +; lsl s, #1 ; No, so multiply the command ID by two. +; lea.w s, (cmd_srt+s) ; Get the pointer, from the command subroutine table. + lea b, cmd_srt ; No, so get the address of the command subroutine table. + mov.w s, (b+2*s) ; Get the pointer, from the command subroutine table. and #0 ; Reset A. tab ; Reset B. jsr s ; Run the command's subroutine. |