syscall_emul: [patch 5/22] remove LiveProcess class and use Process instead

The EIOProcess class was removed recently and it was the only other class
which derived from Process. Since every Process invocation is also a
LiveProcess invocation, it makes sense to simplify the organization by
combining the fields from LiveProcess into Process.
This commit is contained in:
Brandon Potter
2016-11-09 14:27:40 -06:00
parent 7b6cf951e2
commit 3886c4a8f2
73 changed files with 582 additions and 644 deletions

View File

@@ -91,7 +91,7 @@ ClDriver::handshake(GpuDispatcher *_dispatcher)
}
int
ClDriver::open(LiveProcess *p, ThreadContext *tc, int mode, int flags)
ClDriver::open(Process *p, ThreadContext *tc, int mode, int flags)
{
int fd = p->allocFD(-1, filename, 0, 0, false);
FDEntry *fde = p->getFDEntry(fd);
@@ -101,7 +101,7 @@ ClDriver::open(LiveProcess *p, ThreadContext *tc, int mode, int flags)
}
int
ClDriver::ioctl(LiveProcess *process, ThreadContext *tc, unsigned req)
ClDriver::ioctl(Process *process, ThreadContext *tc, unsigned req)
{
int index = 2;
Addr buf_addr = process->getSyscallArg(tc, index);

View File

@@ -43,7 +43,7 @@
class GpuDispatcher;
class HsaCode;
class LiveProcess;
class Process;
class ThreadContext;
struct ClDriverParams;
@@ -53,8 +53,8 @@ class ClDriver final : public EmulatedDriver
public:
ClDriver(ClDriverParams *p);
void handshake(GpuDispatcher *_dispatcher);
int open(LiveProcess *p, ThreadContext *tc, int mode, int flags);
int ioctl(LiveProcess *p, ThreadContext *tc, unsigned req);
int open(Process *p, ThreadContext *tc, int mode, int flags);
int ioctl(Process *p, ThreadContext *tc, unsigned req);
const char* codeOffToKernelName(uint64_t code_ptr);
private: