summaryrefslogtreecommitdiff
path: root/src/sim/builder.hh
diff options
context:
space:
mode:
authorAli Saidi <saidi@eecs.umich.edu>2006-08-15 17:41:22 -0400
committerAli Saidi <saidi@eecs.umich.edu>2006-08-15 17:41:22 -0400
commited58f77c473cf6f35a17ba1448a12dbca089987d (patch)
tree00b9ecfc881086d1ceaa5e62073b1bb979fa6837 /src/sim/builder.hh
parent07488510713a1df61f6cefced7677047cfc0ef66 (diff)
downloadgem5-ed58f77c473cf6f35a17ba1448a12dbca089987d.tar.xz
fixes for gcc 4.1
Nate needs to fix sinic builder stuff Gabe needs to verify my fixes to decoder.isa OPT/DEBUG compiles for ALPHA_FS, ALPHA_SE, MIPS_SE, SPARC_SE with this changeset README: Fix the swig version in the readme src/SConscript: remove sinic until nate fixes the builder crap for it src/arch/alpha/system.hh: src/arch/mips/isa/includes.isa: src/arch/sparc/isa/decoder.isa: src/base/stats/visit.cc: src/base/timebuf.hh: src/dev/ide_disk.cc: src/dev/sinic.cc: src/mem/cache/miss/mshr.cc: src/mem/cache/miss/mshr_queue.cc: src/mem/packet.hh: src/mem/request.hh: src/sim/builder.hh: src/sim/system.hh: fixes for gcc 4.1 --HG-- extra : convert_revision : 3775427c0047b282574d4831dd602c96cac3ba17
Diffstat (limited to 'src/sim/builder.hh')
-rw-r--r--src/sim/builder.hh40
1 files changed, 40 insertions, 0 deletions
diff --git a/src/sim/builder.hh b/src/sim/builder.hh
index 2997fe5c3..aa0e3d17c 100644
--- a/src/sim/builder.hh
+++ b/src/sim/builder.hh
@@ -179,5 +179,45 @@ SimObjectClass the##OBJ_CLASS##Class(CLASS_NAME, \
/* see param.hh */ \
DEFINE_SIM_OBJECT_CLASS_NAME(CLASS_NAME, OBJ_CLASS)
+/* Macros that use the namespace for sinic... yuk. */
+#define BEGIN_DECLARE_SIM_OBJECT_PARAMS_WNS(NAME_SPACE, OBJ_CLASS) \
+class NAME_SPACE##OBJ_CLASS##Builder : public SimObjectBuilder \
+{ \
+ public:
+
+#define END_DECLARE_SIM_OBJECT_PARAMS_WNS(NAME_SPACE, OBJ_CLASS) \
+ \
+ NAME_SPACE##OBJ_CLASS##Builder(const std::string &iniSection); \
+ virtual ~NAME_SPACE##OBJ_CLASS##Builder() {} \
+ \
+ NAME_SPACE::OBJ_CLASS *create(); \
+};
+
+#define BEGIN_INIT_SIM_OBJECT_PARAMS_WNS(NAME_SPACE, OBJ_CLASS) \
+ NAME_SPACE::OBJ_CLASS##Builder::OBJ_CLASS##Builder(const std::string &iSec) \
+ : SimObjectBuilder(iSec),
+
+
+#define END_INIT_SIM_OBJECT_PARAMS_WNS(NAME_SPACE, OBJ_CLASS) \
+{ \
+}
+
+#define CREATE_SIM_OBJECT_WNS(NAME_SPACE, OBJ_CLASS) \
+NAME_SPACE::OBJ_CLASS *NAME_SPACE##OBJ_CLASS##Builder::create()
+
+#define REGISTER_SIM_OBJECT_WNS(NAME_SPACE, CLASS_NAME, OBJ_CLASS) \
+SimObjectBuilder * \
+new##NAME_SPACEi##OBJ_CLASS##Builder(const std::string &iniSection) \
+{ \
+ return new NAME_SPACE##OBJ_CLASS##Builder(iniSection); \
+} \
+ \
+SimObjectClass the##NAME_SPACE##OBJ_CLASS##Class(CLASS_NAME, \
+ new##NAME_SPACE##OBJ_CLASS##Builder); \
+ \
+/* see param.hh */ \
+DEFINE_SIM_OBJECT_CLASS_NAME(CLASS_NAME, NAME_SPACE##OBJ_CLASS)
+
+
#endif // __BUILDER_HH__