Skip to content

Commit

Permalink
Merge pull request #6 from emoon/master
Browse files Browse the repository at this point in the history
Fixed bugs in cas2 and mul (64-bit) disassembly
  • Loading branch information
kstenerud committed Sep 20, 2015
2 parents 19cb001 + ad677ba commit 27365e8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions m68kdasm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1191,7 +1191,7 @@ f e d c b a 9 8 7 6 5 4 3 2 1 0
uint extension;
LIMIT_CPU_TYPES(M68020_PLUS);
extension = read_imm_32();
sprintf(g_dasm_str, "cas2.w D%d:D%d:D%d:D%d, (%c%d):(%c%d); (2+)",
sprintf(g_dasm_str, "cas2.w D%d:D%d, D%d:D%d, (%c%d):(%c%d); (2+)",
(extension>>16)&7, extension&7, (extension>>22)&7, (extension>>6)&7,
BIT_1F(extension) ? 'A' : 'D', (extension>>28)&7,
BIT_F(extension) ? 'A' : 'D', (extension>>12)&7);
Expand All @@ -1202,7 +1202,7 @@ static void d68020_cas2_32(void)
uint extension;
LIMIT_CPU_TYPES(M68020_PLUS);
extension = read_imm_32();
sprintf(g_dasm_str, "cas2.l D%d:D%d:D%d:D%d, (%c%d):(%c%d); (2+)",
sprintf(g_dasm_str, "cas2.l D%d:D%d, D%d:D%d, (%c%d):(%c%d); (2+)",
(extension>>16)&7, extension&7, (extension>>22)&7, (extension>>6)&7,
BIT_1F(extension) ? 'A' : 'D', (extension>>28)&7,
BIT_F(extension) ? 'A' : 'D', (extension>>12)&7);
Expand Down Expand Up @@ -2239,7 +2239,7 @@ static void d68020_mull(void)
extension = read_imm_16();

if(BIT_A(extension))
sprintf(g_dasm_str, "mul%c.l %s, D%d-D%d; (2+)", BIT_B(extension) ? 's' : 'u', get_ea_mode_str_32(g_cpu_ir), extension&7, (extension>>12)&7);
sprintf(g_dasm_str, "mul%c.l %s, D%d:D%d; (2+)", BIT_B(extension) ? 's' : 'u', get_ea_mode_str_32(g_cpu_ir), extension&7, (extension>>12)&7);
else
sprintf(g_dasm_str, "mul%c.l %s, D%d; (2+)", BIT_B(extension) ? 's' : 'u', get_ea_mode_str_32(g_cpu_ir), (extension>>12)&7);
}
Expand Down

0 comments on commit 27365e8

Please sign in to comment.