summaryrefslogtreecommitdiff
path: root/src/cpu/o3
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2014-03-07 15:56:23 -0500
committerAndreas Hansson <andreas.hansson@arm.com>2014-03-07 15:56:23 -0500
commit62fe81e9c1ab09f1b401231f58d9c34008c7b558 (patch)
tree732e6ac33b6be91999dfeb3b95f1d98746146b9d /src/cpu/o3
parentc4a8e5c36cbc30feee6ecd5c706e3275301b25ef (diff)
downloadgem5-62fe81e9c1ab09f1b401231f58d9c34008c7b558.tar.xz
cpu: Make CPU and ThreadContext getters const
This patch merely tidies up the CPU and ThreadContext getters by making them const where appropriate.
Diffstat (limited to 'src/cpu/o3')
-rwxr-xr-xsrc/cpu/o3/thread_context.hh6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cpu/o3/thread_context.hh b/src/cpu/o3/thread_context.hh
index 27f8e9561..ef72fdb03 100755
--- a/src/cpu/o3/thread_context.hh
+++ b/src/cpu/o3/thread_context.hh
@@ -96,14 +96,14 @@ class O3ThreadContext : public ThreadContext
virtual BaseCPU *getCpuPtr() { return cpu; }
/** Reads this CPU's ID. */
- virtual int cpuId() { return cpu->cpuId(); }
+ virtual int cpuId() const { return cpu->cpuId(); }
- virtual int contextId() { return thread->contextId(); }
+ virtual int contextId() const { return thread->contextId(); }
virtual void setContextId(int id) { thread->setContextId(id); }
/** Returns this thread's ID number. */
- virtual int threadId() { return thread->threadId(); }
+ virtual int threadId() const { return thread->threadId(); }
virtual void setThreadId(int id) { return thread->setThreadId(id); }
/** Returns a pointer to the system. */