layout->uu_arg8 = -1; /* impossible value */
#elif defined(VGP_x86_freebsd)
+ // libc converts syscall_syscall to canonical form
+ // (it just needs to pop the ret address, pop the sysno into eax
+ // do the syscall
+ // and push back the ret address)
layout->o_sysno = OFFSET_x86_EAX;
// syscall parameters are on stack in C convention
layout->s_arg1 = sizeof(UWord) * 1;
in the SyscallArgs structure.
2. Get the syscall argument layout
+Call getSyscallArgLayout()
This just initialises the fields of the SyscallArgLayout structure. The layout
will be different depending if it is a normal syscall or a syscall syscall.
It cannot be canonicalised - we can shuffle around the values but we can't
change to using the guest signal mask, do the syscall, restore the Valgrind
signal mask and request the global lock again.
-A call to putSyscallArgsIntoGuestState is made. The PRE may have changed
+A call to putSyscallArgsIntoGuestState() is made. The PRE may have changed
some of the arguments so we need to put the arguments back into
VexGuestArchState.
6. Perform a non-blocking syscall.
-This is much simpler. It performs the syscall via VG_(do_syscall).
+This is much simpler. It performs the syscall via VG_(do_syscall)().
The arguments are passed via struct SyscallArgs (possibly modified by the PRE
wrapper).