summaryrefslogtreecommitdiff
path: root/cpu/cpu_exec_context.hh
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2006-04-06 15:00:11 -0400
committerGabe Black <gblack@eecs.umich.edu>2006-04-06 15:00:11 -0400
commit6a962f8343d0e7f138baa4034633c986eecc9edf (patch)
treef16fdcc7455b0e7cd14af660ebdeb029db3c669a /cpu/cpu_exec_context.hh
parent3124c5b7bb0cdcb3b16b52533c6a3e50a5970152 (diff)
parent6240f8c4bcf12e3367905adfba066bb14f79262a (diff)
downloadgem5-6a962f8343d0e7f138baa4034633c986eecc9edf.tar.xz
Merge m5.eecs.umich.edu:/bk/newmem
into ewok.(none):/home/gblack/m5/newmem --HG-- extra : convert_revision : bd6352647798275a12d52d55a129cdddd8e25423
Diffstat (limited to 'cpu/cpu_exec_context.hh')
-rw-r--r--cpu/cpu_exec_context.hh32
1 files changed, 23 insertions, 9 deletions
diff --git a/cpu/cpu_exec_context.hh b/cpu/cpu_exec_context.hh
index b023fdcf8..feaf29d12 100644
--- a/cpu/cpu_exec_context.hh
+++ b/cpu/cpu_exec_context.hh
@@ -48,7 +48,9 @@ class BaseCPU;
class FunctionProfile;
class ProfileNode;
-class MemoryController;
+class FunctionalPort;
+class PhysicalPort;
+
#else // !FULL_SYSTEM
@@ -56,6 +58,7 @@ class MemoryController;
#include "mem/page_table.hh"
class TranslatingPort;
+
#endif // FULL_SYSTEM
//
@@ -126,11 +129,13 @@ class CPUExecContext
AlphaITB *itb;
AlphaDTB *dtb;
- // the following two fields are redundant, since we can always
- // look them up through the system pointer, but we'll leave them
- // here for now for convenience
- MemoryController *memctrl;
-// PhysicalMemory *physmem;
+ /** A functional port outgoing only for functional accesses to physical
+ * addresses.*/
+ FunctionalPort *physPort;
+
+ /** A functional port, outgoing only, for functional accesse to virtual
+ * addresses. That doen't require execution context information */
+ VirtualPort *virtPort;
FunctionProfile *profile;
ProfileNode *profileNode;
@@ -238,19 +243,28 @@ class CPUExecContext
Fault translateInstReq(CpuRequestPtr &req)
{
- return itb->translate(req);
+ return itb->translate(req, proxy);
}
Fault translateDataReadReq(CpuRequestPtr &req)
{
- return dtb->translate(req, false);
+ return dtb->translate(req, proxy, false);
}
Fault translateDataWriteReq(CpuRequestPtr &req)
{
- return dtb->translate(req, true);
+ return dtb->translate(req, proxy, true);
}
+ FunctionalPort *getPhysPort() { return physPort; }
+
+ /** Return a virtual port. If no exec context is specified then a static
+ * port is returned. Otherwise a port is created and returned. It must be
+ * deleted by deleteVirtPort(). */
+ VirtualPort *getVirtPort(ExecContext *xc);
+
+ void delVirtPort(VirtualPort *vp);
+
#else
TranslatingPort *getMemPort() { return port; }