ilang  0.9.1
ILAng: A Modeling and Verification Platform for SoCs
Public Types | Public Member Functions | List of all members
ilang::VarUseFinder< T > Class Template Reference

Class of finding variable uses. So that we don't need to create pi variables for unused state variables. FIXME: currently there is no need to make a class for it, but in the future it is possible to use a hash table to avoid traverse the same sub-tree twice. More...

#include <ast_helper.h>

Public Types

typedef std::set< T > VarUseList
 Type of vector of ExprPtr with is_var() == true.
 
typedef std::function< T(const ExprPtr &)> ProcessFuncType
 Type of the function to process ExprPtr to T.
 

Public Member Functions

 VarUseFinder (ProcessFuncType f)
 Default constructor: do nothing.
 
 ~VarUseFinder ()
 Default destructor: do nothing.
 
void Traverse (const ExprPtr &expr, VarUseList &uses)
 Find variable uses for an expression.
 
void Traverse (const InstrPtr &i, VarUseList &uses)
 Find variable uses for an instruction (update + decode)
 
void Traverse (const InstrLvlAbsPtr &i, VarUseList &uses)
 Find variable uses for an ila (instruction + fetch + valid )
 

Detailed Description

template<class T>
class ilang::VarUseFinder< T >

Class of finding variable uses. So that we don't need to create pi variables for unused state variables. FIXME: currently there is no need to make a class for it, but in the future it is possible to use a hash table to avoid traverse the same sub-tree twice.


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