avrora.sim
Interface Simulator.Probe

All Known Implementing Classes:
GDBServer.GDBMonitor.StartupProbe, GDBServer.GDBMonitor.StepProbe, MulticastProbe, ProbeTest.TestProbe, ProfileMonitor.Monitor.CCProbe, ProgramTimeProfiler, SequenceProbe, Simulator.Probe.Empty, TraceMonitor.Monitor.GlobalProbe, VisualRegMonitor.VisualMonitor
Enclosing interface:
Simulator

public static interface Simulator.Probe

The Simulator.Probe interface represents a programmer-defined probe that can be inserted at a particular instruction in the program. or at every instruction. Probes can be usedfor profiling, analysis, or program understanding. The fireBefore() and fireAfter() methods are called before and after the target instruction executes in simulation. Probes can also be inserted in the "main loop" of the interpreter, so that the probe fires before and after every instruction executed.


Nested Class Summary
static class Simulator.Probe.Empty
          The Simulator.Probe.Empty class is a simple base class for probes that do not implement one or more methods.
 
Method Summary
 void fireAfter(State state, int pc)
          The fireAfter() method is called after the probed instruction executes.
 void fireBefore(State state, int pc)
          The fireBefore() method is called before the probed instruction executes.
 

Method Detail

fireBefore

public void fireBefore(State state,
                       int pc)
The fireBefore() method is called before the probed instruction executes.

Parameters:
state - the state of the simulation
pc - the address at which this instruction resides

fireAfter

public void fireAfter(State state,
                      int pc)
The fireAfter() method is called after the probed instruction executes.

Parameters:
state - the state of the simulation
pc - the address at which this instruction resides