systemc-clang 2.0.0
Parsing SystemC constructs
|
#include <HDLBody.h>
Public Member Functions | |
HDLBody (clang::DiagnosticsEngine &diag_engine, const ASTContext &ast_context, hdecl_name_map_t &mod_vname_map, hfunc_name_map_t &allmethodecls, overridden_method_map_t &overridden_method_map) | |
virtual | ~HDLBody () |
void | Run (Stmt *stmt, hNodep &h_top, HDLBodyMode runmode, HDLType *HDLt_userclassesp=NULL) |
bool | TraverseStmt (Stmt *stmt) |
bool | VisitCXXOperatorCallExpr (CXXOperatorCallExpr *opcall) |
bool | VisitCXXMemberCallExpr (CXXMemberCallExpr *callexpr) |
bool | VisitCallExpr (CallExpr *callexpr) |
bool | VisitCXXTemporaryObjectExpr (CXXTemporaryObjectExpr *stmt) |
bool | VisitReturnStmt (ReturnStmt *stmt) |
bool | VisitInitListExpr (InitListExpr *stmt) |
bool | VisitCaseStmt (CaseStmt *stmt) |
bool | VisitDefaultStmt (DefaultStmt *stmt) |
bool | VisitBreakStmt (BreakStmt *stmt) |
bool | VisitContinueStmt (ContinueStmt *stmt) |
bool | VisitCompoundStmt (CompoundStmt *compoundStmt) |
bool | VisitDeclStmt (DeclStmt *declstmt) |
bool | ProcessVarDecl (VarDecl *vardecl) |
bool | VisitBinaryOperator (BinaryOperator *expr) |
bool | VisitUnaryOperator (UnaryOperator *expr) |
bool | VisitConditionalOperator (ConditionalOperator *expr) |
bool | VisitIntegerLiteral (IntegerLiteral *lit) |
bool | VisitCXXBoolLiteralExpr (CXXBoolLiteralExpr *b) |
bool | VisitDeclRefExpr (DeclRefExpr *expr) |
bool | VisitArraySubscriptExpr (ArraySubscriptExpr *expr) |
bool | VisitMemberExpr (MemberExpr *memberexpr) |
bool | VisitIfStmt (IfStmt *ifs) |
bool | VisitForStmt (ForStmt *fors) |
bool | VisitSwitchStmt (SwitchStmt *switchs) |
bool | VisitWhileStmt (WhileStmt *whiles) |
bool | VisitDoStmt (DoStmt *whiles) |
bool | ProcessSwitchCase (SwitchCase *cases) |
string | FindVname (NamedDecl *vard) |
void | AddVnames (hNodep &hvns) |
string | FindFname (FunctionDecl *funcd) |
void | GetWaitArg (hNodep &h_callp, Expr *callarg) |
hNodep | NormalizeAssignmentChain (hNodep hinp) |
void | NormalizeSwitchStmt (hNodep hswitchbody) |
Public Attributes | |
hfunc_name_map_t | methodecls |
clang::DiagnosticsEngine & | diag_e |
hdecl_name_map_t | vname_map |
overridden_method_map_t & | overridden_method_map_ |
Private Member Functions | |
bool | isUserClass (const Type *classrectype) |
bool | isLogicalOp (clang::OverloadedOperatorKind opc) |
bool | isAssignOp (hNodep hp) |
bool | isArrayRef (hNodep hp) |
string | generate_vname (string nm) |
Private Attributes | |
hNodep | h_ret |
hdecl_name_map_t & | mod_vname_map_ |
bool | add_info |
const string | nextstate_string = "_scclang_nextstate_" |
HDLBodyMode | thismode |
hfunc_name_map_t & | allmethodecls_ |
HDLType * | HDLt_userclassesp_ |
util | lutil |
const ASTContext & | ast_context_ |
systemc_hdl::HDLBody::HDLBody | ( | clang::DiagnosticsEngine & | diag_engine, |
const ASTContext & | ast_context, | ||
hdecl_name_map_t & | mod_vname_map, | ||
hfunc_name_map_t & | allmethodecls, | ||
overridden_method_map_t & | overridden_method_map ) |
Definition at line 63 of file HDLBody.cpp.
|
virtual |
Definition at line 104 of file HDLBody.cpp.
void systemc_hdl::HDLBody::AddVnames | ( | hNodep & | hvns | ) |
Definition at line 1294 of file HDLBody.cpp.
string systemc_hdl::HDLBody::FindFname | ( | FunctionDecl * | funcd | ) |
Definition at line 1285 of file HDLBody.cpp.
string systemc_hdl::HDLBody::FindVname | ( | NamedDecl * | vard | ) |
Definition at line 1276 of file HDLBody.cpp.
|
inlineprivate |
void systemc_hdl::HDLBody::GetWaitArg | ( | hNodep & | h_callp, |
Expr * | callarg ) |
Definition at line 1332 of file HDLBody.cpp.
|
inlineprivate |
|
inlineprivate |
|
private |
Definition at line 856 of file HDLBody.cpp.
|
inlineprivate |
Definition at line 1315 of file HDLBody.cpp.
void systemc_hdl::HDLBody::NormalizeSwitchStmt | ( | hNodep | hswitchbody | ) |
Definition at line 1344 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::ProcessSwitchCase | ( | SwitchCase * | cases | ) |
Definition at line 1146 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::ProcessVarDecl | ( | VarDecl * | vardecl | ) |
Definition at line 332 of file HDLBody.cpp.
void systemc_hdl::HDLBody::Run | ( | Stmt * | stmt, |
hNodep & | h_top, | ||
HDLBodyMode | runmode, | ||
HDLType * | HDLt_userclassesp = NULL ) |
Definition at line 75 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::TraverseStmt | ( | Stmt * | stmt | ) |
Definition at line 111 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitArraySubscriptExpr | ( | ArraySubscriptExpr * | expr | ) |
Definition at line 670 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitBinaryOperator | ( | BinaryOperator * | expr | ) |
Definition at line 453 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitBreakStmt | ( | BreakStmt * | stmt | ) |
Definition at line 270 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCallExpr | ( | CallExpr * | callexpr | ) |
Definition at line 1042 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCaseStmt | ( | CaseStmt * | stmt | ) |
Definition at line 234 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCompoundStmt | ( | CompoundStmt * | compoundStmt | ) |
Definition at line 284 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitConditionalOperator | ( | ConditionalOperator * | expr | ) |
Definition at line 543 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitContinueStmt | ( | ContinueStmt * | stmt | ) |
Definition at line 277 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCXXBoolLiteralExpr | ( | CXXBoolLiteralExpr * | b | ) |
Definition at line 566 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCXXMemberCallExpr | ( | CXXMemberCallExpr * | callexpr | ) |
Definition at line 688 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCXXOperatorCallExpr | ( | CXXOperatorCallExpr * | opcall | ) |
Definition at line 871 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitCXXTemporaryObjectExpr | ( | CXXTemporaryObjectExpr * | stmt | ) |
Definition at line 199 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitDeclRefExpr | ( | DeclRefExpr * | expr | ) |
Definition at line 574 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitDeclStmt | ( | DeclStmt * | declstmt | ) |
Process local variable and signal declarations, promoting to module level with unique names
Definition at line 315 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitDefaultStmt | ( | DefaultStmt * | stmt | ) |
Definition at line 257 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitDoStmt | ( | DoStmt * | whiles | ) |
Definition at line 1255 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitForStmt | ( | ForStmt * | fors | ) |
Definition at line 1111 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitIfStmt | ( | IfStmt * | ifs | ) |
Definition at line 1084 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitInitListExpr | ( | InitListExpr * | stmt | ) |
Definition at line 214 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitIntegerLiteral | ( | IntegerLiteral * | lit | ) |
Definition at line 558 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitMemberExpr | ( | MemberExpr * | memberexpr | ) |
Definition at line 967 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitReturnStmt | ( | ReturnStmt * | stmt | ) |
Definition at line 224 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitSwitchStmt | ( | SwitchStmt * | switchs | ) |
Definition at line 1175 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitUnaryOperator | ( | UnaryOperator * | expr | ) |
Definition at line 515 of file HDLBody.cpp.
bool systemc_hdl::HDLBody::VisitWhileStmt | ( | WhileStmt * | whiles | ) |
Definition at line 1228 of file HDLBody.cpp.
|
private |
|
private |
hfunc_name_map_t systemc_hdl::HDLBody::methodecls |
|
private |
|
private |
overridden_method_map_t& systemc_hdl::HDLBody::overridden_method_map_ |
|
private |
hdecl_name_map_t systemc_hdl::HDLBody::vname_map |