29a30,31
> #include <vector>
>
30a33
> #include "systemc/core/object.hh"
35a39,45
> namespace
> {
>
> std::vector<sc_object *> top_level_objects;
>
> } // anonymous namespace
>
39,40c49
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return "sc_object";
---
> return _gem5_object->name();
46,47c55
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return "sc_object";
---
> return _gem5_object->basename();
50,55d57
< const char *
< sc_object::kind() const
< {
< return "sc_object";
< }
<
59c61
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> _gem5_object->print(out);
65c67
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> _gem5_object->dump(out);
71,72c73
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return *(const std::vector<sc_object *> *)nullptr;
---
> return _gem5_object->get_child_objects();
78,79c79
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return *(const std::vector<sc_event *> *)nullptr;
---
> return _gem5_object->get_child_events();
85,86c85
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return NULL;
---
> return _gem5_object->get_parent_object();
90c89
< sc_object::add_attribute(sc_attr_base &)
---
> sc_object::add_attribute(sc_attr_base &attr)
92,93c91
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return false;
---
> return _gem5_object->add_attribute(attr);
97c95
< sc_object::get_attribute(const std::string &)
---
> sc_object::get_attribute(const std::string &name)
99,100c97
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return NULL;
---
> return _gem5_object->get_attribute(name);
104c101
< sc_object::remove_attribute(const std::string &)
---
> sc_object::remove_attribute(const std::string &name)
106,107c103
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return NULL;
---
> return _gem5_object->remove_attribute(name);
113c109
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> return _gem5_object->remove_all_attributes();
119,120c115
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return 0;
---
> return _gem5_object->num_attributes();
126,127c121
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return *(sc_attr_cltn *)NULL;
---
> return _gem5_object->attr_cltn();
133,134c127
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return *(sc_attr_cltn *)NULL;
---
> return _gem5_object->attr_cltn();
140,141c133
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return nullptr;
---
> return _gem5_object->simcontext();
146c138
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> _gem5_object = new sc_gem5::Object(this);
151c143
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> _gem5_object = new sc_gem5::Object(this, name);
154c146
< sc_object::sc_object(const sc_object &arg)
---
> sc_object::sc_object(const sc_object &other)
156c148
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> _gem5_object = new sc_gem5::Object(this, *other._gem5_object);
160c152
< sc_object::operator = (const sc_object &)
---
> sc_object::operator = (const sc_object &other)
161a154
> *_gem5_object = *other._gem5_object;
167c160
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
---
> delete _gem5_object;
173,174c166
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return *(const std::vector<sc_object *> *)nullptr;
---
> return sc_gem5::topLevelObjects;
178c170
< sc_find_object(const char *)
---
> sc_find_object(const char *name)
180,181c172
< warn("%s not implemented.\n", __PRETTY_FUNCTION__);
< return NULL;
---
> return sc_gem5::findObject(name);