Package ghidra.debug.api.emulation

# Interface PcodeDebuggerRegistersAccess

All Superinterfaces:
  `PcodeDebuggerDataAccess`, `PcodeTraceDataAccess`, `PcodeTraceRegistersAccess`

public interface PcodeDebuggerRegistersAccess extends PcodeTraceRegistersAccess, PcodeDebuggerDataAccess
A data-access shim for a trace's registers and the debugger

- ## Method Summary

  Modifier and Type
  Method
  Description
  `CompletableFuture<Boolean>`
  `readFromTargetRegisters(AddressSetView unknown)`
  Instruct the associated recorder to read registers from the target
  `CompletableFuture<Boolean>`
  `writeTargetRegister(Address address, byte[] data)`
  Instruct the associated recorder to write target registers

  ### Methods inherited from interface ghidra.debug.api.emulation.PcodeDebuggerDataAccess

  `isLive`

  ### Methods inherited from interface ghidra.pcode.exec.trace.data.PcodeTraceDataAccess

  `getBytes, getLanguage, getPropertyAccess, getViewportState, intersectUnknown, intersectViewKnown, putBytes, setState, translate`

  ### Methods inherited from interface ghidra.pcode.exec.trace.data.PcodeTraceRegistersAccess

  `initializeThreadContext`

- ## Method Details

  - ### readFromTargetRegisters

    CompletableFuture<Boolean> readFromTargetRegisters(AddressSetView unknown)
    Instruct the associated recorder to read registers from the target
    Parameters:
      `unknown` - the address set (in the platform's `register` space) of registers to read
    Returns:
      a future which completes when the read is complete and its results recorded to the trace. It completes with true when any part of target state was successfully read. It completes with false if there is no target, or if the target was not read.

  - ### writeTargetRegister

    CompletableFuture<Boolean> writeTargetRegister(Address address, byte[] data)
    Instruct the associated recorder to write target registers

    In normal operation, this will also cause the recorder, upon a successful write, to record the same values into the destination trace. If this shim is not associated with a live session, the returned future completes immediately with false.

    Parameters:
      `address` - the address of the first byte to write (in the platform's `register` space)
      `data` - the bytes to write
    Returns:
      a future which completes when the write is complete and its results recorded to the trace. It completes with true when the target was written. It completes with false if there is no target, or if the target is not effected.