This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v3 2/3] Add an optional "alias" attribute to syscall entries.
> Cc: palves@redhat.com, gdb-patches@sourceware.org
> From: John Baldwin <jhb@FreeBSD.org>
> Date: Wed, 28 Nov 2018 10:00:48 -0800
>
> Oh, I was just referring to Pedro's version being shorter. I'm fine with
> moving it. This is a bit longer as it restores a bit of the FreeBSD-specific
> note about syscall ABIs but that seemed relevant when moving it:
>
> diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
> index 944a2c4383..c60c2b80c4 100644
> --- a/gdb/doc/gdb.texinfo
> +++ b/gdb/doc/gdb.texinfo
> @@ -22329,6 +22329,7 @@ configurations.
> * Cygwin Native:: Features specific to the Cygwin port
> * Hurd Native:: Features specific to @sc{gnu} Hurd
> * Darwin:: Features specific to Darwin
> +* FreeBSD:: Features specific to FreeBSD
> @end menu
>
> @node BSD libkvm Interface
> @@ -23214,6 +23215,26 @@ better understand the cause of a fault. The default is off.
> Show the current state of exceptions trapping.
> @end table
>
> +@node FreeBSD
> +@subsection FreeBSD
> +@cindex FreeBSD
> +
> +When the ABI of a system call is changed in the FreeBSD kernel, this
> +is implemented by leaving a compatibility system call using the old
> +ABI at the existing number and allocating a new system call number for
> +the version using the new ABI. As a convenience, when a system call
> +is caught by name, compatibility system calls are also caught.
> +
> +For example, FreeBSD 12 introduced a new variant of the @code{kevent}
> +system call and catching the @code{kevent} system call by name catches
> +both variants:
> +
> +@smallexample
> +(@value{GDBP}) catch syscall kevent
> +Catchpoint 1 (syscalls 'freebsd11_kevent' [363] 'kevent' [560])
> +(@value{GDBP})
> +@end smallexample
This is fine with me, but let's hear what Pedro thinks.