Go to the documentation of this file.
52 _name(
name), _sc_mod(nullptr), _obj(nullptr), _ended(false),
53 _deprecatedConstructor(false), bindingIndex(0)
55 panic_if(_new_module,
"Previous module not finished.\n");
62 if (_new_module ==
this)
63 _new_module =
nullptr;
78 _modules.push_back(
this);
81 _new_module =
nullptr;
95 if (_modules.empty() || _modules.back() !=
this)
98 panic_if(_new_module,
"Pop with unfinished module.\n");
108 "Trying to bind %d interfaces/ports to %d ports.\n",
109 proxies.size(),
ports.size());
111 auto proxyIt = proxies.begin();
112 auto portIt =
ports.begin();
114 for (; proxyIt != proxies.end(); proxyIt++, portIt++) {
115 auto proxy = *proxyIt;
117 if (proxy->interface())
118 port->vbind(*proxy->interface());
120 port->vbind(*proxy->port());
132 e->before_end_of_elaboration();
151 e->end_of_elaboration();
166 e->start_of_simulation();
181 e->end_of_simulation();
192 if (_modules.empty())
194 return _modules.back();
UniqueNameGen globalNameGen
std::vector<::sc_core::sc_export_base * > exports
sc_core::sc_object * sc_obj()
std::vector<::sc_core::sc_port_base * > ports
const char * name() const
const char SC_ID_END_MODULE_NOT_CALLED_[]
sc_core::sc_module * sc_mod() const
void finish(Object *this_obj)
static void popParentModule()
virtual void end_of_simulation()
#define SC_REPORT_ERROR(msg_type, msg)
void bindPorts(std::vector< const ::sc_core::sc_bind_proxy * > &proxies)
static void pushParentModule(Module *m)
Module * newModuleChecked()
const std::string & name()
virtual void end_of_elaboration()
#define SC_REPORT_WARNING(msg_type, msg)
#define panic_if(cond,...)
Conditional panic macro that checks the supplied condition and only panics if the condition is true a...
const char SC_ID_MODULE_NAME_STACK_EMPTY_[]
virtual void before_end_of_elaboration()
bool _deprecatedConstructor
std::list< Module * > allModules
virtual void start_of_simulation()
void beforeEndOfElaboration()
sc_core::sc_module * _sc_mod
std::string csprintf(const char *format, const Args &...args)
Generated on Wed Sep 30 2020 14:02:14 for gem5 by doxygen 1.8.17