GP-2480 Add sleigh compiler support for inst_next2

This commit is contained in:
ghidra1 2022-08-18 17:27:39 -04:00
parent 39baf3a691
commit 8d4a6c213e
84 changed files with 3623 additions and 2807 deletions

View file

@ -105,14 +105,14 @@ public class DebuggerStateEditingPluginIntegrationTest extends AbstractGhidraHea
assertTrue(
helper.patchInstructionAction.isAddToPopup(listingProvider.getActionContext(null)));
Instruction ins =
helper.patchInstructionAt(tb.addr(0x00400123), "imm r0,#0x0", "imm r0,#1234");
helper.patchInstructionAt(tb.addr(0x00400123), "imm r0,#0x0", "imm r0,#0x3d2");
assertEquals(2, ins.getLength());
long snap = traceManager.getCurrent().getViewSnap();
assertTrue(DBTraceUtils.isScratch(snap));
byte[] bytes = new byte[2];
view.getMemory().getBytes(tb.addr(0x00400123), bytes);
assertArrayEquals(tb.arr(0x40, 1234), bytes);
assertArrayEquals(tb.arr(0x30, 0xd2), bytes);
}
@Test

View file

@ -86,8 +86,8 @@ public class DebuggerPcodeStepperProviderTest extends AbstractGhidraHeadedDebugg
Assembler asm = Assemblers.getAssembler(tb.trace.getFixedProgramView(0));
iit = asm.assemble(start,
"imm r0, #1234",
"imm r1, #2045"); // 11 bits unsigned
"imm r0, #0x3d2",
"imm r1, #911"); // 10 bits unsigned
}
imm1234 = iit.next();