This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch v7 05/24] frame: artificial frame id's
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Markus Metzger <markus dot t dot metzger at intel dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 11 Dec 2013 20:58:47 +0100
- Subject: Re: [patch v7 05/24] frame: artificial frame id's
- Authentication-results: sourceware.org; auth=none
- References: <1385735899-12481-1-git-send-email-markus dot t dot metzger at intel dot com> <1385735899-12481-6-git-send-email-markus dot t dot metzger at intel dot com>
On Fri, 29 Nov 2013 15:38:00 +0100, Markus Metzger wrote:
> --- a/gdb/frame.c
> +++ b/gdb/frame.c
> @@ -504,6 +504,19 @@ frame_id_build_wild (CORE_ADDR stack_addr)
> return id;
> }
>
/* See frame.h. */
> +struct frame_id
> +frame_id_build_artificial (CORE_ADDR code_addr,
> + CORE_ADDR special_addr)
> +{
> + struct frame_id id = null_frame_id;
> +
> + id.code_addr = code_addr;
> + id.code_addr_p = 1;
> + id.special_addr = special_addr;
> + id.special_addr_p = 1;
> + return id;
> +}
> +
> int
> frame_id_p (struct frame_id l)
> {
[...]
> --- a/gdb/frame.h
> +++ b/gdb/frame.h
> @@ -174,6 +174,12 @@ extern struct frame_id frame_id_build_special (CORE_ADDR stack_addr,
> as the special identifier address are set to indicate wild cards. */
> extern struct frame_id frame_id_build_wild (CORE_ADDR stack_addr);
>
> +/* Construct an artificial frame ID. The first parameter is the frame's
> + constant code address (typically the entry point), and the second the
the function entry point
> + frame's special identifier address. */
> +extern struct frame_id frame_id_build_artificial (CORE_ADDR code_addr,
> + CORE_ADDR special_addr);
> +
> /* Returns non-zero when L is a valid frame (a valid frame has a
> non-zero .base). The outermost frame is valid even without an
> ID. */
> --
> 1.8.3.1
Thanks,
Jan