gem5  v20.1.0.0
Public Member Functions | Private Attributes | List of all members
ProbeManager Class Reference

ProbeManager is a conduit class that lives on each SimObject, and is used to match up probe listeners with probe points. More...

#include <probe.hh>

Public Member Functions

 ProbeManager (SimObject *obj)
 
virtual ~ProbeManager ()
 
bool addListener (std::string pointName, ProbeListener &listener)
 Add a ProbeListener to the ProbePoint named by pointName. More...
 
bool removeListener (std::string pointName, ProbeListener &listener)
 Remove a ProbeListener from the ProbePoint named by pointName. More...
 
void addPoint (ProbePoint &point)
 Add a ProbePoint to this SimObject ProbeManager. More...
 

Private Attributes

const M5_CLASS_VAR_USED SimObjectobject
 Required for sensible debug messages. More...
 
std::vector< ProbePoint * > points
 Vector for name look-up. More...
 

Detailed Description

ProbeManager is a conduit class that lives on each SimObject, and is used to match up probe listeners with probe points.

Definition at line 150 of file probe.hh.

Constructor & Destructor Documentation

◆ ProbeManager()

ProbeManager::ProbeManager ( SimObject obj)
inline

Definition at line 159 of file probe.hh.

◆ ~ProbeManager()

virtual ProbeManager::~ProbeManager ( )
inlinevirtual

Definition at line 162 of file probe.hh.

Member Function Documentation

◆ addListener()

bool ProbeManager::addListener ( std::string  pointName,
ProbeListener listener 
)

Add a ProbeListener to the ProbePoint named by pointName.

If the name doesn't resolve a ProbePoint return false.

Parameters
pointNamethe name of the ProbePoint to add the ProbeListener to.
listenerthe ProbeListener to add.
Returns
true if added, false otherwise.

Definition at line 83 of file probe.cc.

References DPRINTFR, SimObject::name(), object, MipsISA::p, and points.

Referenced by ProbeListener::ProbeListener().

◆ addPoint()

void ProbeManager::addPoint ( ProbePoint point)

Add a ProbePoint to this SimObject ProbeManager.

Parameters
pointthe ProbePoint to add.

Definition at line 117 of file probe.cc.

References DPRINTFR, ProbePoint::getName(), SimObject::name(), object, MipsISA::p, and points.

Referenced by ProbePoint::ProbePoint().

◆ removeListener()

bool ProbeManager::removeListener ( std::string  pointName,
ProbeListener listener 
)

Remove a ProbeListener from the ProbePoint named by pointName.

If the name doesn't resolve a ProbePoint return false.

Parameters
pointNamethe name of the ProbePoint to remove the ProbeListener from.
listenerthe ProbeListener to remove.
Returns
true if removed, false otherwise.

Definition at line 100 of file probe.cc.

References DPRINTFR, SimObject::name(), object, MipsISA::p, and points.

Referenced by ProbeListener::~ProbeListener().

Member Data Documentation

◆ object

const M5_CLASS_VAR_USED SimObject* ProbeManager::object
private

Required for sensible debug messages.

Definition at line 154 of file probe.hh.

Referenced by addListener(), addPoint(), and removeListener().

◆ points

std::vector<ProbePoint *> ProbeManager::points
private

Vector for name look-up.

Definition at line 156 of file probe.hh.

Referenced by addListener(), addPoint(), and removeListener().


The documentation for this class was generated from the following files:

Generated on Wed Sep 30 2020 14:02:29 for gem5 by doxygen 1.8.17