A point in a trace.

Execution points allow accessing the various machine states reached during an execution. Each Point provides an access to the machine's Cpu context and Memory. Generally speaking a point corresponds to the execution of a CPU instruction, but a point may also be generated on interruptions triggered by external devices.

Internally reven manages execution points through a pair of indexes:

  • The sequence index which is the basic block execution count in the trace.
  • The instruction index inside the basic block.

This object abstracts away this implementation detail through the Point interface. This allows the user to transparently use iterators on a trace without bothering with dynamic basic block (aka sequence) consideration.

Method __init__
Method memory_accesses The memory accesses performed by the instruction.
Method trace Property: The trace this point belongs to.
Method memory The memory at this point in the trace.
Method cpu The CPU at this point in the trace.
Method sequence_index Property: The sequence index in the trace (number of basic block executed).
Method instruction_index Property: The instruction index in the point basic block.
Method previous The previously executed trace point.
Method next The next executed trace point.
Method comment The comments at this point.
Method push_comment
Method instruction Property: The point instruction.
Method basic_block Property: The point basic block.
Method symbol Property: The point symbol.
Method previous_sequence Get the first point of the previous sequence.
Method next_sequence Get the first point of the next sequence.
Method __lt__
Method __eq__ Undocumented
Method __ne__ Undocumented
Method __gt__
Method __ge__
Method __le__
Method __repr__ Undocumented
Method _rvn Undocumented
Method _rvn_point Undocumented
Method _sequence
def __init__(self, trace, index, instruction_index):
ParameterstraceThe point trace.
indexThe sequence index.
instruction_indexThe instruction index.
RaisesValueErrorif the sequence index is negative or greater than the sequence count in the trace.
ValueErrorif the instruction index is negative or greater than the instruction count in the sequence.
@property
def _rvn(self):
Undocumented
@property
def _rvn_point(self):
Undocumented
@property
def _sequence(self):
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
def memory_accesses(self):

The memory accesses performed by the instruction.

ReturnsA list of MemoryAccess objects.
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
@property
def trace(self):

Property: The trace this point belongs to.

def memory(self, default_segment=None):

The memory at this point in the trace.

Parametersdefault_segmentThe default segment selector value used to access data by logical address in this memory object. If none, will be the current value of ds.
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
def cpu(self):

The CPU at this point in the trace.

Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
@property
def sequence_index(self):

Property: The sequence index in the trace (number of basic block executed).

@property
def instruction_index(self):

Property: The instruction index in the point basic block.

def previous(self):

The previously executed trace point.

ReturnsThe previous point or None if this is the first point in the trace.
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
def next(self):

The next executed trace point.

ReturnsThe next point or None if this is the last point in the trace.
def comment(self):

The comments at this point.

This is similar to a static instruction's comment, but is only displayed at this point. Note the following current limitations on dynamic comments:

  • Dynamic comments at a point cannot be removed. Setting the comment again pushes to a list of dynamic comments at this point.
  • The same dynamic comment cannot be pushed twice. Duplicates will be ignored
  • Dynamic comments in Axion will be displayed like the "Trace infos" ("; msg" at the right of the instruction). There is currently no way to add dynamic comments from Axion.

In its current state, the dynamic comment feature is experimental, and its use is discouraged.

def push_comment(self, text):
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
@property
def instruction(self):

Property: The point instruction.

@property
def basic_block(self):

Property: The point basic block.

@property
def symbol(self):

Property: The point symbol.

def previous_sequence(self):

Get the first point of the previous sequence.

Returnsthe first point of the previous sequence, or None if this point belongs to the first sequence.
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
def next_sequence(self):

Get the first point of the next sequence.

Returnsthe first point of the next sequence or None if this point belongs to the last sequence.
Raisesreven_api.ServiceNotAllowedDuringExecutionErrorIf this method is called during the execution.
RuntimeErrorIf the connection is lost, in case of bad input, or in case of internal service error.
def __lt__(self, other):
RaisesValueErrorif the two points are from different traces
def __eq__(self, other):
Undocumented
def __ne__(self, other):
Undocumented
def __gt__(self, other):
RaisesValueErrorif the two points are from different traces
def __ge__(self, other):
RaisesValueErrorif the two points are from different traces
def __le__(self, other):
RaisesValueErrorif the two points are from different traces
def __repr__(self):
Undocumented
API Documentation for reven, generated by pydoctor at 2018-06-06 16:31:21.