diff options
author | Gabe Black <gblack@eecs.umich.edu> | 2006-02-19 02:34:52 -0500 |
---|---|---|
committer | Gabe Black <gblack@eecs.umich.edu> | 2006-02-19 02:34:52 -0500 |
commit | 0e4a80df1a471671b6ef7003e29124b6835ade42 (patch) | |
tree | 1d2c44d8c3462dd94c0fbf6e4f149e026c901aa8 /cpu/exec_context.hh | |
parent | a48c24b61eedf580645ff0294b225d1e69a9444b (diff) | |
parent | 463aa6d49d49ba9c383f07207df57bad75c58ec9 (diff) | |
download | gem5-0e4a80df1a471671b6ef7003e29124b6835ade42.tar.xz |
Merge gblack@m5.eecs.umich.edu:/bk/multiarch
into ewok.(none):/home/gblack/m5/multiarch
--HG--
extra : convert_revision : 090b30a7f70294e1aeb13ba0bc15da4061bdf348
Diffstat (limited to 'cpu/exec_context.hh')
-rw-r--r-- | cpu/exec_context.hh | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/cpu/exec_context.hh b/cpu/exec_context.hh index 845f9264b..f11d69273 100644 --- a/cpu/exec_context.hh +++ b/cpu/exec_context.hh @@ -35,6 +35,7 @@ #include "sim/host.hh" #include "sim/serialize.hh" #include "arch/isa_traits.hh" +//#include "arch/isa_registers.hh" #include "sim/byteswap.hh" // forward declaration: see functional_memory.hh @@ -66,6 +67,11 @@ namespace Kernel { class Binning; class Statistics; } class ExecContext { + protected: + typedef TheISA::RegFile RegFile; + typedef TheISA::Addr Addr; + typedef TheISA::MachInst MachInst; + typedef TheISA::MiscRegFile MiscRegFile; public: enum Status { @@ -433,15 +439,15 @@ class ExecContext void trap(Fault fault); #if !FULL_SYSTEM - IntReg getSyscallArg(int i) + TheISA::IntReg getSyscallArg(int i) { - return regs.intRegFile[ArgumentReg0 + i]; + return regs.intRegFile[TheISA::ArgumentReg0 + i]; } // used to shift args for indirect syscall - void setSyscallArg(int i, IntReg val) + void setSyscallArg(int i, TheISA::IntReg val) { - regs.intRegFile[ArgumentReg0 + i] = val; + regs.intRegFile[TheISA::ArgumentReg0 + i] = val; } void setSyscallReturn(SyscallReturn return_value) @@ -453,11 +459,11 @@ class ExecContext if (return_value.successful()) { // no error regs.intRegFile[RegA3] = 0; - regs.intRegFile[ReturnValueReg] = return_value.value(); + regs.intRegFile[TheISA::ReturnValueReg] = return_value.value(); } else { // got an error, return details - regs.intRegFile[RegA3] = (IntReg) -1; - regs.intRegFile[ReturnValueReg] = -return_value.value(); + regs.intRegFile[RegA3] = (TheISA::IntReg) -1; + regs.intRegFile[TheISA::ReturnValueReg] = -return_value.value(); } } |