summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Lim <ktlim@umich.edu>2006-06-07 15:17:34 -0400
committerKevin Lim <ktlim@umich.edu>2006-06-07 15:17:34 -0400
commit6915513b972524de5b73edbf7cddeaeb84504703 (patch)
treeac0b0028359e1a08b251d6cb1c251e7ccb8144f3
parent3e191b14776c7a2c967e80c24331b27a50b8df77 (diff)
downloadgem5-6915513b972524de5b73edbf7cddeaeb84504703.tar.xz
Move checker's exec_context.hh to match the other changes. Also add in some more comments.
src/cpu/thread_context.hh: Add more comments. --HG-- rename : src/cpu/checker/exec_context.hh => src/cpu/checker/thread_context.hh extra : convert_revision : 008a030b0254241118edb033c848e771e09ec8c0
-rw-r--r--src/cpu/checker/thread_context.hh (renamed from src/cpu/checker/exec_context.hh)0
-rw-r--r--src/cpu/thread_context.hh12
2 files changed, 11 insertions, 1 deletions
diff --git a/src/cpu/checker/exec_context.hh b/src/cpu/checker/thread_context.hh
index 48890584d..48890584d 100644
--- a/src/cpu/checker/exec_context.hh
+++ b/src/cpu/checker/thread_context.hh
diff --git a/src/cpu/thread_context.hh b/src/cpu/thread_context.hh
index ac2b44ba8..e3bb7d9c3 100644
--- a/src/cpu/thread_context.hh
+++ b/src/cpu/thread_context.hh
@@ -65,7 +65,7 @@ namespace Kernel {
* The ThreadContext is slightly different than the ExecContext. The
* ThreadContext provides access to an individual thread's state; an
* ExecContext provides ISA access to the CPU (meaning it is
- * implicitly multithreaded on MT systems). Additionally the
+ * implicitly multithreaded on SMT systems). Additionally the
* ThreadState is an abstract class that exactly defines the
* interface; the ExecContext is a more implicit interface that must
* be implemented so that the ISA can access whatever state it needs.
@@ -254,6 +254,16 @@ class ThreadContext
RegFile::ContextVal val) = 0;
};
+/**
+ * ProxyThreadContext class that provides a way to implement a
+ * ThreadContext without having to derive from it. ThreadContext is an
+ * abstract class, so anything that derives from it and uses its
+ * interface will pay the overhead of virtual function calls. This
+ * class is created to enable a user-defined Thread object to be used
+ * wherever ThreadContexts are used, without paying the overhead of
+ * virtual function calls when it is used by itself. See
+ * simple_thread.hh for an example of this.
+ */
template <class TC>
class ProxyThreadContext : public ThreadContext
{