Package ghidra.test.processors.support
Class PCodeTestAbstractControlBlock
java.lang.Object
ghidra.test.processors.support.PCodeTestAbstractControlBlock
- Direct Known Subclasses:
PCodeTestControlBlock,PCodeTestGroupControlBlock
PCodeTestAbstractControlBlock data is models the general capabilities
of the TestInfo data structure which is used for different puposes as handled
by extensions of this class.-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final AddressSpaceprotected final AddressSpaceprotected final Structureprotected final Addressprotected final intprotected final Program -
Method Summary
Modifier and TypeMethodDescriptionprotected voidapplyU4Data(Address addr) protected longemuRead(EmulatorHelper emu, Address addr, int size) protected StringemuReadString(EmulatorHelper emu, Address strPtrAddr) protected voidemuWrite(EmulatorHelper emu, Address addr, int size, long value) getFunctionInfo(int functionIndex) getFunctionInfo(String functionName) protected AddressgetMirroredDataAddress(EmulatorTestRunner emuTestRunner, Address addr) intprotected intgetStructureComponent(Structure testInfoStruct, String fieldName) protected AddressreadCodePointer(MemBuffer buffer, int bufferOffset, boolean updateReference) protected voidreadControlBlock(boolean applyStruct) protected AddressreadDataPointer(MemBuffer buffer, int bufferOffset, boolean updateReference) protected AddressCheck for a Data pointer at the specified address and return the referenced address.protected AddressreadPointer(int controlBlockOffset)
-
Field Details
-
program
-
codeSpace
-
dataSpace
-
pointerSize
protected final int pointerSize -
infoStructAddr
-
infoProgramStruct
-
-
Method Details
-
getInfoStructureAddress
-
getFunctionInfo
-
getFunctionInfo
-
getNumberFunctions
public int getNumberFunctions() -
readDefinedDataPointer
Check for a Data pointer at the specified address and return the referenced address.- Parameters:
addr- address of stored pointer- Returns:
- pointer referenced address or null if no pointer found
-
readCodePointer
protected Address readCodePointer(MemBuffer buffer, int bufferOffset, boolean updateReference) throws MemoryAccessException - Throws:
MemoryAccessException
-
readDataPointer
-
readPointer
- Throws:
MemoryAccessException
-
applyU4Data
-
getStructureComponent
-
readControlBlock
protected void readControlBlock(boolean applyStruct) throws ghidra.test.processors.support.PCodeTestAbstractControlBlock.InvalidControlBlockException, CodeUnitInsertionException - Throws:
ghidra.test.processors.support.PCodeTestAbstractControlBlock.InvalidControlBlockExceptionCodeUnitInsertionException
-
emuReadString
-
emuRead
-
emuWrite
-
getMirroredDataAddress
-