On Thu, Jan 5, 2012 at 7:53 AM, Steve Reinhardt <[email protected]> wrote:
> So my proposal is:
> 1. Move MemObject methods into SimObject (getPort() etc.) and get rid of
> MemObject entirely.
> 2. Replace MemObject with SimObject in mem/port.{cc,hh} and similar places
> where it's just used to indicate a class that can have ports.
> 3. Create a new class SysComponent (I'm open to other names) that derives
> from SimObject, and doesn't do anything but add a system =
> Param.System(Parent.any) param.
> 4. Replace MemObject with SysComponent anywhere it's used as a base class.
> 5. (optional, but very desirable) Track down any non-MemObject derived
> class that has its own Param.System(Parent.any) param, make it derive from
> SysComponent too, and get rid of that explicit param.
>
Alternatively, we could keep MemObject to keep the distinction between
objects with and without ports, and have the hierarchy look like this:
SimObject
v
MemObject (adds the ability to have ports)
v
SysComponent (adds default system param)
Then System would probably be the only thing that derives directly from
MemObject and not SysComponent.
I'm not sure this is worth the mental complexity of maintaining three
classes where two would probably do, but it's a smaller change in the sense
that MemObject doesn't go away. I'm somewhat ambivalent between these two.
Steve
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev