diff options
author | Ron Dreslinski <rdreslin@umich.edu> | 2006-02-20 23:26:39 -0500 |
---|---|---|
committer | Ron Dreslinski <rdreslin@umich.edu> | 2006-02-20 23:26:39 -0500 |
commit | d96de69abc02b40e1dec4843a7a7b7e30749f4fa (patch) | |
tree | 0c3fd42012ec416fcabdc8691f2ccd202ee98865 /cpu | |
parent | b74f1b829d14e43256fb4a9efd3b951e81ad12d2 (diff) | |
download | gem5-d96de69abc02b40e1dec4843a7a7b7e30749f4fa.tar.xz |
Add in a new translating port that allows syscalls to translate addresses via the page table before accessing the memory port.
Other compile issues cleaned up.
SConscript:
Changes to compile the new Translating Port.
Split out memtester and eio support, will rework them back in after first getting a simpleCPU to work
arch/alpha/alpha_linux_process.cc:
arch/alpha/alpha_tru64_process.cc:
sim/syscall_emul.cc:
sim/syscall_emul.hh:
Changes to use the new translating Port.
cpu/exec_context.cc:
cpu/exec_context.hh:
Create a translating port in each execution context.
sim/process.cc:
Fix the way we do proxy memory
--HG--
extra : convert_revision : 3d33218fe8b425a5d9ce24757f1112b4aa6001fd
Diffstat (limited to 'cpu')
-rw-r--r-- | cpu/exec_context.cc | 2 | ||||
-rw-r--r-- | cpu/exec_context.hh | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/cpu/exec_context.cc b/cpu/exec_context.cc index a281609f4..10894230b 100644 --- a/cpu/exec_context.cc +++ b/cpu/exec_context.cc @@ -37,6 +37,7 @@ #include "base/output.hh" #include "cpu/profile.hh" #include "kern/kernel_stats.hh" +#include "mem/translating_port.hh" #include "sim/serialize.hh" #include "sim/sim_exit.hh" #include "sim/system.hh" @@ -85,6 +86,7 @@ ExecContext::ExecContext(BaseCPU *_cpu, int _thread_num, System *_system, asid(_asid), func_exe_inst(0), storeCondFailures(0) { + port = new TranslatingPort(cpu->memPort, process->pTable); memset(®s, 0, sizeof(RegFile)); } #endif diff --git a/cpu/exec_context.hh b/cpu/exec_context.hh index c40b00e4c..3d40c06f0 100644 --- a/cpu/exec_context.hh +++ b/cpu/exec_context.hh @@ -35,8 +35,8 @@ #include "sim/host.hh" #include "sim/serialize.hh" #include "targetarch/byte_swap.hh" +#include "mem/translating_port.hh" -class Memory; class BaseCPU; #if FULL_SYSTEM @@ -122,6 +122,9 @@ class ExecContext int cpu_id; System *system; + + /// Port that syscalls can use to access memory (provides translation step). + TranslatingPort *port; // Memory *mem; #if FULL_SYSTEM |