"gdb --config" to show the xxHash option
Commit Message
I've noticed that HAVE_LIBXXHASH is not reflected in the --config
output. Okay to commit the below? including to the GDB 9 branch?
Comments
On Wed, Dec 18, 2019 at 11:04 AM Eli Zaretskii <eliz@gnu.org> wrote:
>
> I've noticed that HAVE_LIBXXHASH is not reflected in the --config
> output. Okay to commit the below? including to the GDB 9 branch?
As the person who added this flag, this sounds reasonable to me. What
are the criteria for adding stuff to this list? I didn't add it
because there's no user-visible effect other than performance.
Christian
> diff --git a/gdb/ChangeLog b/gdb/ChangeLog
> index 91b81f2..98c9361 100644
> --- a/gdb/ChangeLog
> +++ b/gdb/ChangeLog
> @@ -1,3 +1,8 @@
> +2019-12-18 Eli Zaretskii <eliz@gnu.org>
> +
> + * top.c (print_gdb_configuration): Print "--with-xxhash" or
> + "--without-xxhash" according to HAVE_LIBXXHASH.
> +
> 2019-12-17 Christian Biesinger <cbiesinger@google.com>
>
> * bsd-kvm.c: Include gdbsupport/pathstuff.h.
> diff --git a/gdb/top.c b/gdb/top.c
> index bc300e4..796a423 100644
> --- a/gdb/top.c
> +++ b/gdb/top.c
> @@ -1496,6 +1496,15 @@ This GDB was configured as follows:\n\
> --without-mpfr\n\
> "));
> #endif
> +#if HAVE_LIBXXHASH
> + fprintf_filtered (stream, _("\
> + --with-xxhash\n\
> +"));
> +#else
> + fprintf_filtered (stream, _("\
> + --without-xxhash\n\
> +"));
> +#endif
> #ifdef WITH_PYTHON_PATH
> fprintf_filtered (stream, _("\
> --with-python=%s%s\n\
> From: Christian Biesinger <cbiesinger@google.com>
> Date: Wed, 18 Dec 2019 11:57:18 -0600
> Cc: gdb-patches <gdb-patches@sourceware.org>
>
> On Wed, Dec 18, 2019 at 11:04 AM Eli Zaretskii <eliz@gnu.org> wrote:
> >
> > I've noticed that HAVE_LIBXXHASH is not reflected in the --config
> > output. Okay to commit the below? including to the GDB 9 branch?
>
> As the person who added this flag, this sounds reasonable to me. What
> are the criteria for adding stuff to this list? I didn't add it
> because there's no user-visible effect other than performance.
The original idea was to provide a means for end-users to report to us
how their GDB was configured, to facilitate investigation of issues.
So I think any optional feature should be reflected in the output of
"gdb --config".
>>>>> "Eli" == Eli Zaretskii <eliz@gnu.org> writes:
Eli> I've noticed that HAVE_LIBXXHASH is not reflected in the --config
Eli> output. Okay to commit the below? including to the GDB 9 branch?
This is ok. Thanks.
I think it's fine for the gdb 9 branch as well.
Tom
@@ -1,3 +1,8 @@
+2019-12-18 Eli Zaretskii <eliz@gnu.org>
+
+ * top.c (print_gdb_configuration): Print "--with-xxhash" or
+ "--without-xxhash" according to HAVE_LIBXXHASH.
+
2019-12-17 Christian Biesinger <cbiesinger@google.com>
* bsd-kvm.c: Include gdbsupport/pathstuff.h.
@@ -1496,6 +1496,15 @@ This GDB was configured as follows:\n\
--without-mpfr\n\
"));
#endif
+#if HAVE_LIBXXHASH
+ fprintf_filtered (stream, _("\
+ --with-xxhash\n\
+"));
+#else
+ fprintf_filtered (stream, _("\
+ --without-xxhash\n\
+"));
+#endif
#ifdef WITH_PYTHON_PATH
fprintf_filtered (stream, _("\
--with-python=%s%s\n\