This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
RE: [PATCH] Propagate record_print_flags
- From: "Metzger, Markus T" <markus dot t dot metzger at intel dot com>
- To: Simon Marchi <simon dot marchi at ericsson dot com>, "gdb-patches at sourceware dot org" <gdb-patches at sourceware dot org>
- Date: Thu, 1 Mar 2018 14:30:25 +0000
- Subject: RE: [PATCH] Propagate record_print_flags
- Authentication-results: sourceware.org; auth=none
- Dlp-product: dlpe-windows
- Dlp-reaction: no-action
- Dlp-version: 11.0.0.116
- References: <1519912053-26118-1-git-send-email-simon.marchi@ericsson.com>
Hello Simon,
> These flags are returned as an int by get_call_history_modifiers, and
> get cast back to record_print_flags in the btrace code. Instead, we can
> make the arguments of that type from start to end.
>
> gdb/ChangeLog:
>
> * record.c (get_call_history_modifiers): Return a
> record_print_flags.
> (cmd_record_call_history): Adjust.
> * record-btrace.c (record_btrace_call_history): Adjust.
> (record_btrace_call_history_range): Adjust.
> (record_btrace_call_history_from): Adjust.
> * target-debug.h (target_debug_print_record_print_flags): New.
> * target-delegates.c: Re-generate.
> * target.c (target_call_history): Change flags type.
> (target_call_history_from): Likewise.
> (target_call_history_range): Likewise.
> * target.h (struct target_ops) <target_call_history>: Likewise.
> (target_call_history_from): Likewise.
> (target_call_history_range): Likewise.
Looks good to me.
> @@ -172,6 +172,8 @@
> target_debug_do_print (host_address_to_string (X.data ()))
> #define target_debug_print_inferior_p(inf) \
> target_debug_do_print (host_address_to_string (inf))
> +#define target_debug_print_record_print_flags(X) \
> + target_debug_do_print (plongest (X))
Should we print them as hex?
Regards,
Markus.
Intel Deutschland GmbH
Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de
Managing Directors: Christin Eisenschmid, Christian Lamprechter
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928