Package ghidra.trace.database.memory
Interface InternalTraceMemoryOperations
- All Superinterfaces:
TraceMemoryOperations
- All Known Implementing Classes:
DBTraceMemoryManager,DBTraceMemorySpace
-
Method Summary
Modifier and TypeMethodDescriptiondefault intgetBytes(TracePlatform platform, long snap, Register register, ByteBuffer buf) Get the most-recent bytes of a given register at the given timegetLock()getSpace()For register mapping conventionsdefault TraceMemoryStategetState(TracePlatform platform, long snap, Register register) Assert that a register's range has a single state at the given snap and get that stategetStates(TracePlatform platform, long snap, Register register) Break the register's range into smaller ranges each mapped to its state at the given snapdefault RegisterValuegetValue(TracePlatform platform, long snap, Register register) Get the most-recent value of a given register at the given timedefault RegisterValuegetViewValue(TracePlatform platform, long snap, Register register) Get the most-recent value of a given register at the given timedefault intputBytes(TracePlatform platform, long snap, Register register, ByteBuffer buf) default voidremoveValue(TracePlatform platform, long snap, Register register) static TraceMemoryStaterequireOne(Collection<Map.Entry<TraceAddressSnapRange, TraceMemoryState>> states, Register register) default voidsetState(TracePlatform platform, long snap, Register register, TraceMemoryState state) Set the state of a given register at a given timedefault intsetValue(TracePlatform platform, long snap, RegisterValue value) Methods inherited from interface ghidra.trace.model.memory.TraceMemoryOperations
findBytes, getAddressesWithState, getAddressesWithState, getAddressesWithState, getAddressesWithState, getBlockSize, getBufferAt, getBufferAt, getBytes, getBytes, getMostRecentStateEntry, getMostRecentStates, getMostRecentStates, getSnapOfMostRecentChangeToBlock, getState, getState, getStates, getStates, getTrace, getValue, getViewBytes, getViewMostRecentStateEntry, getViewMostRecentStateEntry, getViewState, getViewValue, isKnown, pack, putBytes, putBytes, removeBytes, removeValue, setState, setState, setState, setState, setState, setValue
-
Method Details
-
requireOne
static TraceMemoryState requireOne(Collection<Map.Entry<TraceAddressSnapRange, TraceMemoryState>> states, Register register) -
getSpace
AddressSpace getSpace()For register mapping conventions- Returns:
- the address space
-
getLock
ReadWriteLock getLock() -
setState
Description copied from interface:TraceMemoryOperationsSet the state of a given register at a given timeSetting state to
TraceMemoryState.KNOWNvia this method is not recommended. Setting bytes will automatically update the state accordingly.- Specified by:
setStatein interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the timeregister- the registerstate- the state
-
getState
Description copied from interface:TraceMemoryOperationsAssert that a register's range has a single state at the given snap and get that state- Specified by:
getStatein interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the timeregister- the register to examine- Returns:
- the state
-
getStates
default Collection<Map.Entry<TraceAddressSnapRange,TraceMemoryState>> getStates(TracePlatform platform, long snap, Register register) Description copied from interface:TraceMemoryOperationsBreak the register's range into smaller ranges each mapped to its state at the given snapIf the register is memory mapped, this will delegate to the appropriate space.
- Specified by:
getStatesin interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the timeregister- the register to examine- Returns:
- the map of ranges to states
-
putBytes
- Specified by:
putBytesin interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the snapregister- the register to modifybuf- the buffer of bytes to write- Returns:
- the number of bytes written
- See Also:
-
setValue
- Specified by:
setValuein interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the snapvalue- the register value- Returns:
- the number of bytes written
- See Also:
-
getValue
Description copied from interface:TraceMemoryOperationsGet the most-recent value of a given register at the given timeIf the register is memory mapped, this will delegate to the appropriate space.
- Specified by:
getValuein interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the timeregister- the register- Returns:
- the value
-
getViewValue
Description copied from interface:TraceMemoryOperationsGet the most-recent value of a given register at the given timeIf the register is memory mapped, this will delegate to the appropriate space.
- Specified by:
getViewValuein interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the timeregister- the register- Returns:
- the value
-
getBytes
Description copied from interface:TraceMemoryOperationsGet the most-recent bytes of a given register at the given timeIf the register is memory mapped, this will delegate to the appropriate space.
- Specified by:
getBytesin interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the timeregister- the registerbuf- the destination buffer- Returns:
- the number of bytes read
-
removeValue
- Specified by:
removeValuein interfaceTraceMemoryOperations- Parameters:
platform- the platform whose language defines the registersnap- the snapregister- the register- See Also:
-