sim: Mark System::getThreadContext method as const
authorGiacomo Travaglini <giacomo.travaglini@arm.com>
Thu, 19 Sep 2019 13:54:04 +0000 (14:54 +0100)
committerGiacomo Travaglini <giacomo.travaglini@arm.com>
Wed, 2 Oct 2019 15:56:42 +0000 (15:56 +0000)
Change-Id: Ic0ce1b098cfe0ce6ea37986a8a55002a5c18a66c
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/21304
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Maintainer: Jason Lowe-Power <jason@lowepower.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/sim/system.hh

index d7a3b20085a29c0c26dfb0dbd29652dd553d05c8..c618e394445aeaa95cc1b71bf2c850999722cf55 100644 (file)
@@ -200,7 +200,7 @@ class System : public SimObject
     std::vector<ThreadContext *> threadContexts;
     const bool multiThread;
 
-    ThreadContext *getThreadContext(ContextID tid)
+    ThreadContext *getThreadContext(ContextID tid) const
     {
         return threadContexts[tid];
     }