diff --git a/src/sim/syscall_emul.cc b/src/sim/syscall_emul.cc index 913a26591a..4ab472aaf0 100644 --- a/src/sim/syscall_emul.cc +++ b/src/sim/syscall_emul.cc @@ -969,37 +969,6 @@ setpgidFunc(SyscallDesc *desc, int callnum, ThreadContext *tc, return 0; } -SyscallReturn -getpidPseudoFunc(SyscallDesc *desc, int callnum, ThreadContext *tc) -{ - // Make up a PID. There's no interprocess communication in - // fake_syscall mode, so there's no way for a process to know it's - // not getting a unique value. - - auto process = tc->getProcessPtr(); - return SyscallReturn(process->pid(), process->ppid()); -} - - -SyscallReturn -getuidPseudoFunc(SyscallDesc *desc, int callnum, ThreadContext *tc) -{ - // Make up a UID and EUID... it shouldn't matter, and we want the - // simulation to be deterministic. - - auto process = tc->getProcessPtr(); - return SyscallReturn(process->uid(), process->euid()); -} - - -SyscallReturn -getgidPseudoFunc(SyscallDesc *desc, int callnum, ThreadContext *tc) -{ - // Get current group ID. - auto process = tc->getProcessPtr(); - return SyscallReturn(process->gid(), process->egid()); -} - SyscallReturn getpidFunc(SyscallDesc *desc, int callnum, ThreadContext *tc) diff --git a/src/sim/syscall_emul.hh b/src/sim/syscall_emul.hh index 2fd5fa7e56..6be574ac88 100644 --- a/src/sim/syscall_emul.hh +++ b/src/sim/syscall_emul.hh @@ -503,20 +503,10 @@ futexFunc(SyscallDesc *desc, int callnum, ThreadContext *tc, return -ENOSYS; } - /// Pseudo Funcs - These functions use a different return convension, /// returning a second value in a register other than the normal return register SyscallReturn pipePseudoFunc(SyscallDesc *desc, int num, ThreadContext *tc); -/// Target getpidPseudo() handler. -SyscallReturn getpidPseudoFunc(SyscallDesc *desc, int num, ThreadContext *tc); - -/// Target getuidPseudo() handler. -SyscallReturn getuidPseudoFunc(SyscallDesc *desc, int num, ThreadContext *tc); - -/// Target getgidPseudo() handler. -SyscallReturn getgidPseudoFunc(SyscallDesc *desc, int num, ThreadContext *tc); - /// A readable name for 1,000,000, for converting microseconds to seconds. const int one_million = 1000000;