changeset e4660687c49f in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=e4660687c49f
description:
        SE/FS: Include getMemPort in FS.

diffstat:

 src/cpu/checker/thread_context.hh |   4 ++--
 src/cpu/inorder/thread_context.hh |   4 ++--
 src/cpu/o3/thread_context.hh      |   4 ++--
 src/cpu/ozone/cpu.hh              |   4 ++--
 src/cpu/thread_context.hh         |   8 ++++----
 src/cpu/thread_state.cc           |  16 ++++++++++------
 src/cpu/thread_state.hh           |   6 +++---
 7 files changed, 25 insertions(+), 21 deletions(-)

diffs (178 lines):

diff -r 509e9bb84dfa -r e4660687c49f src/cpu/checker/thread_context.hh
--- a/src/cpu/checker/thread_context.hh Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/checker/thread_context.hh Sun Oct 16 05:06:40 2011 -0700
@@ -97,11 +97,11 @@
     TheISA::Kernel::Statistics *getKernelStats()
     { return actualTC->getKernelStats(); }
 #else
-    TranslatingPort *getMemPort() { return actualTC->getMemPort(); }
-
     Process *getProcessPtr() { return actualTC->getProcessPtr(); }
 #endif
 
+    TranslatingPort *getMemPort() { return actualTC->getMemPort(); }
+
     VirtualPort *getVirtPort()
     { return actualTC->getVirtPort(); }
 
diff -r 509e9bb84dfa -r e4660687c49f src/cpu/inorder/thread_context.hh
--- a/src/cpu/inorder/thread_context.hh Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/inorder/thread_context.hh Sun Oct 16 05:06:40 2011 -0700
@@ -143,12 +143,12 @@
         return this->thread->quiesceEvent;
     }
 #else
-    TranslatingPort *getMemPort() { return thread->getMemPort(); }
-
     /** Returns a pointer to this thread's process. */
     Process *getProcessPtr() { return thread->getProcessPtr(); }
 #endif
 
+    TranslatingPort *getMemPort() { return thread->getMemPort(); }
+
     VirtualPort *getVirtPort();
     FunctionalPort *getPhysPort() { return thread->getPhysPort(); }
 
diff -r 509e9bb84dfa -r e4660687c49f src/cpu/o3/thread_context.hh
--- a/src/cpu/o3/thread_context.hh      Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/o3/thread_context.hh      Sun Oct 16 05:06:40 2011 -0700
@@ -99,12 +99,12 @@
 
     virtual void connectMemPorts(ThreadContext *tc) { 
thread->connectMemPorts(tc); }
 #else
-    virtual TranslatingPort *getMemPort() { return thread->getMemPort(); }
-
     /** Returns a pointer to this thread's process. */
     virtual Process *getProcessPtr() { return thread->getProcessPtr(); }
 #endif
 
+    virtual TranslatingPort *getMemPort() { return thread->getMemPort(); }
+
     virtual VirtualPort *getVirtPort();
 
     virtual FunctionalPort *getPhysPort() { return thread->getPhysPort(); }
diff -r 509e9bb84dfa -r e4660687c49f src/cpu/ozone/cpu.hh
--- a/src/cpu/ozone/cpu.hh      Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/ozone/cpu.hh      Sun Oct 16 05:06:40 2011 -0700
@@ -124,11 +124,11 @@
         TheISA::Kernel::Statistics *getKernelStats()
         { return thread->getKernelStats(); }
 #else
-        TranslatingPort *getMemPort() { return thread->getMemPort(); }
-
         Process *getProcessPtr() { return thread->getProcessPtr(); }
 #endif
 
+        TranslatingPort *getMemPort() { return thread->getMemPort(); }
+
         VirtualPort *getVirtPort()
         { return thread->getVirtPort(); }
 
diff -r 509e9bb84dfa -r e4660687c49f src/cpu/thread_context.hh
--- a/src/cpu/thread_context.hh Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/thread_context.hh Sun Oct 16 05:06:40 2011 -0700
@@ -130,11 +130,11 @@
 
     virtual void connectMemPorts(ThreadContext *tc) = 0;
 #else
-    virtual TranslatingPort *getMemPort() = 0;
-
     virtual Process *getProcessPtr() = 0;
 #endif
 
+    virtual TranslatingPort *getMemPort() = 0;
+
     virtual VirtualPort *getVirtPort() = 0;
 
     virtual FunctionalPort *getPhysPort() = 0;
@@ -300,11 +300,11 @@
 
     void connectMemPorts(ThreadContext *tc) { actualTC->connectMemPorts(tc); }
 #else
-    TranslatingPort *getMemPort() { return actualTC->getMemPort(); }
-
     Process *getProcessPtr() { return actualTC->getProcessPtr(); }
 #endif
 
+    TranslatingPort *getMemPort() { return actualTC->getMemPort(); }
+
     VirtualPort *getVirtPort() { return actualTC->getVirtPort(); }
 
     FunctionalPort *getPhysPort() { return actualTC->getPhysPort(); }
diff -r 509e9bb84dfa -r e4660687c49f src/cpu/thread_state.cc
--- a/src/cpu/thread_state.cc   Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/thread_state.cc   Sun Oct 16 05:06:40 2011 -0700
@@ -53,9 +53,10 @@
       profile(NULL), profileNode(NULL), profilePC(0), quiesceEvent(NULL),
       kernelStats(NULL),
 #else
-      port(NULL), process(_process),
+      process(_process),
 #endif
-      virtPort(NULL), physPort(NULL), funcExeInst(0), storeCondFailures(0)
+      port(NULL), virtPort(NULL), physPort(NULL), funcExeInst(0),
+      storeCondFailures(0)
 {
 }
 
@@ -153,8 +154,8 @@
     if (profile)
         profile->sample(profileNode, profilePC);
 }
+#endif
 
-#else
 TranslatingPort *
 ThreadState::getMemPort()
 {
@@ -162,14 +163,17 @@
         return port;
 
     /* Use this port to for syscall emulation writes to memory. */
-    port = new TranslatingPort(csprintf("%s-%d-funcport", baseCpu->name(), 
_threadId),
-                               process, TranslatingPort::NextPage);
+    port = new TranslatingPort(csprintf("%s-%d-funcport", baseCpu->name(),
+                               _threadId),
+#if !FULL_SYSTEM
+                               process,
+#endif
+                               TranslatingPort::NextPage);
 
     connectToMemFunc(port);
 
     return port;
 }
-#endif
 
 void
 ThreadState::connectToMemFunc(Port *port)
diff -r 509e9bb84dfa -r e4660687c49f src/cpu/thread_state.hh
--- a/src/cpu/thread_state.hh   Sun Oct 16 05:06:40 2011 -0700
+++ b/src/cpu/thread_state.hh   Sun Oct 16 05:06:40 2011 -0700
@@ -110,11 +110,11 @@
     TheISA::Kernel::Statistics *getKernelStats() { return kernelStats; }
 #else
     Process *getProcessPtr() { return process; }
+#endif
 
     TranslatingPort *getMemPort();
 
     void setMemPort(TranslatingPort *_port) { port = _port; }
-#endif
 
     VirtualPort *getVirtPort() { return virtPort; }
 
@@ -187,11 +187,11 @@
     TheISA::Kernel::Statistics *kernelStats;
   protected:
 #else
-    TranslatingPort *port;
-
     Process *process;
 #endif
 
+    TranslatingPort *port;
+
     /** A functional port, outgoing only, for functional accesse to virtual
      * addresses. */
     VirtualPort *virtPort;
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to