https://bugs.kde.org/show_bug.cgi?id=511713
Bug ID: 511713
Summary: Refactor syscall argument handling
Classification: Developer tools
Product: valgrind
Version First unspecified
Reported In:
Platform: Compiled Sources
OS: All
Status: REPORTED
Severity: normal
Priority: NOR
Component: general
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
The FreeBSD code for syscall argument handling is excessively complicated,
especially with regards to syscalls SYS_syscall and SYS___syscall.
I don't like the 'klass' member of struct SyscallArgs, which uses
VG_FREEBSD_SYSCALL0 and VG_FREEBSD_SYSCALL198. That adds no information above
what we already have with __NR_syscall and __NR___syscall.
When we call do_syscall_for_client() for blocking syscalls the syscall number
gets changed to canonical and then back to the original. If we kept the
original syscall number we could avoid that redundant shuffle.
As well as cleaning the code this will also lead to sharing some of this code
with Darwin, which has the same requirements as FreeBSD but only partially
implements them. That should fix passing the layout info to the PRE wrapper in
Darwin which I believe is currently wrong, meaning that the scalar test is 'out
by one' for checking syscall syscal arguments.
--
You are receiving this mail because:
You are watching all bug changes.