summaryrefslogtreecommitdiff
path: root/src/sim
diff options
context:
space:
mode:
authorStephen Hines <hines@cs.fsu.edu>2008-02-06 16:32:40 -0500
committerStephen Hines <hines@cs.fsu.edu>2008-02-06 16:32:40 -0500
commit6cc1573923754ecb406d03ab4d807f928737c294 (patch)
tree08e407623fedf71b04b128eb93734d4f51988b36 /src/sim
parent0ccf9a2c3751f160d7d51153ef468a60b4daf8d0 (diff)
downloadgem5-6cc1573923754ecb406d03ab4d807f928737c294.tar.xz
Make the Event::description() a const function
--HG-- extra : convert_revision : c7768d54d3f78685e93920069f5485083ca989c0
Diffstat (limited to 'src/sim')
-rw-r--r--src/sim/debug.cc4
-rw-r--r--src/sim/eventq.cc2
-rw-r--r--src/sim/eventq.hh4
-rw-r--r--src/sim/sim_events.cc6
-rw-r--r--src/sim/sim_events.hh6
5 files changed, 11 insertions, 11 deletions
diff --git a/src/sim/debug.cc b/src/sim/debug.cc
index c189117bd..b4f4cd9dc 100644
--- a/src/sim/debug.cc
+++ b/src/sim/debug.cc
@@ -63,7 +63,7 @@ class DebugBreakEvent : public Event
DebugBreakEvent(EventQueue *q, Tick _when);
void process(); // process event
- virtual const char *description();
+ virtual const char *description() const;
};
//
@@ -87,7 +87,7 @@ DebugBreakEvent::process()
const char *
-DebugBreakEvent::description()
+DebugBreakEvent::description() const
{
return "debug break";
}
diff --git a/src/sim/eventq.cc b/src/sim/eventq.cc
index 65e115256..2c679be1e 100644
--- a/src/sim/eventq.cc
+++ b/src/sim/eventq.cc
@@ -230,7 +230,7 @@ dumpMainQueue()
const char *
-Event::description()
+Event::description() const
{
return "generic";
}
diff --git a/src/sim/eventq.hh b/src/sim/eventq.hh
index 6fbba46d5..a454e5d64 100644
--- a/src/sim/eventq.hh
+++ b/src/sim/eventq.hh
@@ -219,7 +219,7 @@ class Event : public Serializable, public FastAlloc
/// Return a C string describing the event. This string should
/// *not* be dynamically allocated; just a const char array
/// describing the event class.
- virtual const char *description();
+ virtual const char *description() const;
/// Dump the current event data
void dump();
@@ -280,7 +280,7 @@ DelayFunction(Tick when, T *object)
: Event(&mainEventQueue), object(o)
{ setFlags(this->AutoDestroy); schedule(when); }
void process() { (object->*F)(); }
- const char *description() { return "delay"; }
+ const char *description() const { return "delay"; }
};
new DelayEvent(when, object);
diff --git a/src/sim/sim_events.cc b/src/sim/sim_events.cc
index 1949e88dd..09087ef84 100644
--- a/src/sim/sim_events.cc
+++ b/src/sim/sim_events.cc
@@ -65,7 +65,7 @@ SimLoopExitEvent::process()
const char *
-SimLoopExitEvent::description()
+SimLoopExitEvent::description() const
{
return "simulation loop exit";
}
@@ -123,7 +123,7 @@ CountedExitEvent::process()
const char *
-CountedExitEvent::description()
+CountedExitEvent::description() const
{
return "counted exit";
}
@@ -153,7 +153,7 @@ CheckSwapEvent::process()
}
const char *
-CheckSwapEvent::description()
+CheckSwapEvent::description() const
{
return "check swap";
}
diff --git a/src/sim/sim_events.hh b/src/sim/sim_events.hh
index 94e2540b1..58ec963c0 100644
--- a/src/sim/sim_events.hh
+++ b/src/sim/sim_events.hh
@@ -68,7 +68,7 @@ class SimLoopExitEvent : public Event
void process(); // process event
- virtual const char *description();
+ virtual const char *description() const;
};
class CountedDrainEvent : public SimLoopExitEvent
@@ -104,7 +104,7 @@ class CountedExitEvent : public Event
void process(); // process event
- virtual const char *description();
+ virtual const char *description() const;
};
//
@@ -122,7 +122,7 @@ class CheckSwapEvent : public Event
void process(); // process event
- virtual const char *description();
+ virtual const char *description() const;
};
#endif // __SIM_SIM_EVENTS_HH__