ilang  0.9.1
ILAng: A Modeling and Verification Platform for SoCs
Static Public Member Functions | List of all members
ilang::AbsKnob Class Reference

Static Public Member Functions

static void InsertVar (const ExprPtr e, ExprSet &vars)
 Add all dependent vars of the expr to the set.
 
static ExprSet GetVar (const ExprPtr e)
 Get the set of all dependent vars of the expr.
 
static void InsertStt (const InstrCnstPtr instrs, ExprSet &stts)
 Add all state vars of the host (excluding child) to the set.
 
static void InsertSttTree (const InstrCnstPtr instrs, ExprSet &stts)
 Add all state vars of the host (including child) to the set.
 
static void InsertVar (const InstrLvlAbsCnstPtr m, ExprSet &vars)
 Add all vars of the ILA (excluding child) to the set.
 
static void InsertStt (const InstrLvlAbsCnstPtr m, ExprSet &stts)
 Add all state vars of the ILA (excluding child) to the set.
 
static void InsertInp (const InstrLvlAbsCnstPtr m, ExprSet &inps)
 Add all input vars of the ILA (excluding child) to the set.
 
static void InsertVarTree (const InstrLvlAbsCnstPtr top, ExprSet &vars)
 Add all vars of the ILA (including child) to the set.
 
static void InsertSttTree (const InstrLvlAbsCnstPtr top, ExprSet &stts)
 Add all state vars of the ILA (including child) to the set.
 
static void InsertInpTree (const InstrLvlAbsCnstPtr top, ExprSet &inps)
 Add all input vars of the ILA (including child) to the set.
 
static ExprSet GetVar (const InstrLvlAbsCnstPtr m)
 Get the set of all vars of the ILA (excluding child).
 
static ExprSet GetStt (const InstrLvlAbsCnstPtr m)
 Get the set of all state vars of the ILA (excluding child).
 
static ExprSet GetInp (const InstrLvlAbsCnstPtr m)
 Get the set of all input vars of the ILA (excluding child).
 
static ExprSet GetVarTree (const InstrLvlAbsCnstPtr top)
 Get the set of all vars of the ILA (including child).
 
static ExprSet GetSttTree (const InstrLvlAbsCnstPtr top)
 Get the set of all state vars of the ILA (including child).
 
static ExprSet GetInpTree (const InstrLvlAbsCnstPtr top)
 Get the set of all input vars of the ILA (including child).
 
static void DuplInp (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst)
 
static void DuplStt (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst)
 
static void InsertInstr (const InstrLvlAbsCnstPtr m, InstrVec &instrs)
 Add all instructions of the ILA (excluding child) to the set.
 
static void InsertInstrTree (const InstrLvlAbsCnstPtr top, InstrVec &instrs)
 Add all instructions of the ILA (including child) to the set.
 
static InstrVec GetInstr (const InstrLvlAbsCnstPtr m)
 Get the set of instructions of the ILA (excluding child).
 
static InstrVec GetInstrTree (const InstrLvlAbsCnstPtr top)
 Get the set of instructions of the ILA (including child).
 
static ExprPtr Rewrite (const ExprPtr e, const ExprMap &rule)
 Rewrite an expression by replacing based on the rule. More...
 
static void RewriteInstr (const InstrCnstPtr instr_src, const InstrPtr instr_dst, const ExprMap &expr_map)
 Rewrite an instruction by replacing based on the rule.
 
static void FlattenIla (const InstrLvlAbsPtr ila_ptr_)
 Flatten the given ILA, the initial conditions will be added to the top the child instructions will also be added to the top, but their (hierarchical) valid conditions will be added to their decode condition Some usage hint: this function is intended to generate an ILA for Verilog generator or other verification model generator. You can first use ExtrDeptModl to extract the dependent model and use this to flatten the that model and send to the generator.
 
static InstrLvlAbsPtr ExtrDeptModl (const InstrPtr instr, const std::string &name)
 Return a new ILA that contains the dependant instructions and child-ILAs of an instruction (defined by sub-programs).
 
static InstrLvlAbsPtr CopyIlaTree (const InstrLvlAbsCnstPtr src, const std::string &dst_name)
 Copy and ILA (including child).
 
static void DuplInp (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst, ExprMap &expr_map)
 Duplicate input vars from src to dst while updating the mapping.
 
static void DuplStt (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst, ExprMap &expr_map)
 Duplicate state vars from src to dst while updating the mapping.
 
static ExprPtr DuplFetch (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst, const ExprMap &expr_map)
 Duplicate fetch from src to dst if defined (rewritten w.r.t. mapping).
 
static ExprPtr DuplValid (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst, const ExprMap &expr_map)
 Duplicate valid from src to dst if defined (rewritten w.r.t. mapping).
 
static void DuplInit (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst, const ExprMap &expr_map)
 Duplicate initial conditions from src to dst (rewritten w.r.t. mapping).
 
static InstrPtr DuplInstr (const InstrCnstPtr instr_src, const InstrLvlAbsPtr dst, const ExprMap &expr_map, const CnstIlaMap &ila_map)
 Duplicate an instruction to dst (rewritten w.r.t. mapping).
 
static void DuplInstrSeq (const InstrLvlAbsCnstPtr src, const InstrLvlAbsPtr dst)
 Duplicate instruction sequence to dst. NOT IMPLEMENTED YET.
 

Member Function Documentation

◆ Rewrite()

static ExprPtr ilang::AbsKnob::Rewrite ( const ExprPtr  e,
const ExprMap rule 
)
static

Rewrite an expression by replacing based on the rule.

  • If leaves contain non-var nodes, will replace with no further traverse.

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