Commit 86d0c875 authored by André Hentschel's avatar André Hentschel Committed by Alexandre Julliard

winedbg: Simplify Coprocessor operators in the Thumb2 disassembler.

parent a0ae8b4b
...@@ -1058,15 +1058,11 @@ static UINT thumb2_disasm_coprocdat(UINT inst, ADDRESS64 *addr) ...@@ -1058,15 +1058,11 @@ static UINT thumb2_disasm_coprocdat(UINT inst, ADDRESS64 *addr)
{ {
WORD opc2 = (inst >> 5) & 0x07; WORD opc2 = (inst >> 5) & 0x07;
if (opc2)
dbg_printf("\n\tcdp%s\tp%u, #%u, cr%u, cr%u, cr%u, #%u", (inst & 0x10000000)?"2":"",
get_nibble(inst, 2), get_nibble(inst, 5), get_nibble(inst, 3),
get_nibble(inst, 4), get_nibble(inst, 0), opc2);
else
dbg_printf("\n\tcdp%s\tp%u, #%u, cr%u, cr%u, cr%u", (inst & 0x10000000)?"2":"", dbg_printf("\n\tcdp%s\tp%u, #%u, cr%u, cr%u, cr%u", (inst & 0x10000000)?"2":"",
get_nibble(inst, 2), get_nibble(inst, 5), get_nibble(inst, 3), get_nibble(inst, 2), get_nibble(inst, 5), get_nibble(inst, 3),
get_nibble(inst, 4), get_nibble(inst, 0)); get_nibble(inst, 4), get_nibble(inst, 0));
if (opc2) dbg_printf(", #%u", opc2);
return 0; return 0;
} }
...@@ -1075,15 +1071,11 @@ static UINT thumb2_disasm_coprocmov1(UINT inst, ADDRESS64 *addr) ...@@ -1075,15 +1071,11 @@ static UINT thumb2_disasm_coprocmov1(UINT inst, ADDRESS64 *addr)
WORD opc1 = (inst >> 21) & 0x07; WORD opc1 = (inst >> 21) & 0x07;
WORD opc2 = (inst >> 5) & 0x07; WORD opc2 = (inst >> 5) & 0x07;
if (opc2)
dbg_printf("\n\t%s%s\tp%u, #%u, %s, cr%u, cr%u, #%u", (inst & 0x00100000)?"mrc":"mcr",
(inst & 0x10000000)?"2":"", get_nibble(inst, 2), opc1,
tbl_regs[get_nibble(inst, 3)], get_nibble(inst, 4), get_nibble(inst, 0), opc2);
else
dbg_printf("\n\t%s%s\tp%u, #%u, %s, cr%u, cr%u", (inst & 0x00100000)?"mrc":"mcr", dbg_printf("\n\t%s%s\tp%u, #%u, %s, cr%u, cr%u", (inst & 0x00100000)?"mrc":"mcr",
(inst & 0x10000000)?"2":"", get_nibble(inst, 2), opc1, (inst & 0x10000000)?"2":"", get_nibble(inst, 2), opc1,
tbl_regs[get_nibble(inst, 3)], get_nibble(inst, 4), get_nibble(inst, 0)); tbl_regs[get_nibble(inst, 3)], get_nibble(inst, 4), get_nibble(inst, 0));
if (opc2) dbg_printf(", #%u", opc2);
return 0; return 0;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment