using namespace std;
-Tru64System::Tru64System(const string _name, MemoryController *_memCtrl,
- PhysicalMemory *_physmem, const string &kernel_path,
- const string &console_path, const string &palcode,
- const string &boot_osflags)
- : System(_name, _memCtrl, _physmem)
+Tru64System::Tru64System(const string _name, const int _init_param,
+ MemoryController *_memCtrl, PhysicalMemory *_physmem,
+ const string &kernel_path, const string &console_path,
+ const string &palcode, const string &boot_osflags)
+ : System(_name, _init_param, _memCtrl, _physmem)
{
kernelSymtab = new SymbolTable;
consoleSymtab = new SymbolTable;
SimObjectParam<MemoryController *> mem_ctl;
SimObjectParam<PhysicalMemory *> physmem;
+ Param<int> init_param;
Param<string> kernel_code;
Param<string> console_code;
INIT_PARAM(mem_ctl, "memory controller"),
INIT_PARAM(physmem, "phsyical memory"),
+ INIT_PARAM_DFLT(init_param, "numerical value to pass into simulator", 0),
INIT_PARAM(kernel_code, "file that contains the kernel code"),
INIT_PARAM(console_code, "file that contains the console code"),
INIT_PARAM(pal_code, "file that contains palcode"),
CREATE_SIM_OBJECT(Tru64System)
{
- Tru64System *sys = new Tru64System(getInstanceName(), mem_ctl, physmem,
- kernel_code, console_code, pal_code,
- boot_osflags);
+ Tru64System *sys = new Tru64System(getInstanceName(), init_param, mem_ctl,
+ physmem, kernel_code, console_code,
+ pal_code, boot_osflags);
return sys;
}
class System : public SimObject
{
public:
+ const int init_param;
MemoryController *memCtrl;
PhysicalMemory *physmem;
void registerExecContext(ExecContext *xc);
public:
- System(const std::string name, MemoryController *, PhysicalMemory *);
+ System(const std::string _name, const int _init_param,
+ MemoryController *, PhysicalMemory *);
~System();
virtual void init(ExecContext *xc) = 0;