summaryrefslogtreecommitdiff
path: root/src/arch/x86/linux/process.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch/x86/linux/process.hh')
-rw-r--r--src/arch/x86/linux/process.hh32
1 files changed, 27 insertions, 5 deletions
diff --git a/src/arch/x86/linux/process.hh b/src/arch/x86/linux/process.hh
index e224374d4..e80b86537 100644
--- a/src/arch/x86/linux/process.hh
+++ b/src/arch/x86/linux/process.hh
@@ -68,18 +68,40 @@ namespace X86ISA {
/// A process with emulated x86/Linux syscalls.
class X86LinuxProcess : public X86LiveProcess
{
+ protected:
+ SyscallDesc *syscallDescs;
+
+ const int Num_Syscall_Descs;
+
+ /// Constructor.
+ X86LinuxProcess(LiveProcessParams * params, ObjectFile *objFile,
+ SyscallDesc *_syscallDescs, int numSyscallDescs) :
+ X86LiveProcess(params, objFile), syscallDescs(_syscallDescs),
+ Num_Syscall_Descs(numSyscallDescs)
+ {}
+
+ public:
+ SyscallDesc* getDesc(int callnum);
+};
+
+class X86_64LinuxProcess : public X86LinuxProcess
+{
public:
/// Constructor.
- X86LinuxProcess(LiveProcessParams * params, ObjectFile *objFile);
+ X86_64LinuxProcess(LiveProcessParams * params, ObjectFile *objFile);
/// Array of syscall descriptors, indexed by call number.
static SyscallDesc syscallDescs[];
+};
- SyscallDesc* getDesc(int callnum);
-
- const int Num_Syscall_Descs;
+class I386LinuxProcess : public X86LinuxProcess
+{
+ public:
+ /// Constructor.
+ I386LinuxProcess(LiveProcessParams * params, ObjectFile *objFile);
- void handleTrap(int trapNum, ThreadContext *tc);
+ /// Array of syscall descriptors, indexed by call number.
+ static SyscallDesc syscallDescs[];
};
} // namespace X86ISA