This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] "tfind" across unavailable-stack frames.
- From: Yao Qi <yao at codesourcery dot com>
- To: Pedro Alves <palves at redhat dot com>
- Cc: <gdb-patches at sourceware dot org>
- Date: Sat, 14 Dec 2013 14:21:11 +0800
- Subject: Re: [PATCH] "tfind" across unavailable-stack frames.
- Authentication-results: sourceware.org; auth=none
- References: <1366214779 dot 30939 dot 1 at abidh-ubunto1104> <516F11B9 dot 8030202 at redhat dot com> <52AB48B6 dot 6040206 at redhat dot com>
On 12/14/2013 01:49 AM, Pedro Alves wrote:
> gdb/
> 2013-12-13 Pedro Alves <palves@redhat.com>
>
> * frame.h (enum frame_id_stack_status): New enum.
> (struct frame_id) <stack_addr>: Adjust comment.
> <stack_addr_p>: Delete field, replaced with ...
> <stack_status>: ... this new field.
> (frame_id_build_unavailable_stack): Declare.
> * frame.c (frame_addr_hash, fprint_field, outer_frame_id)
> (frame_id_build_special): Adjust.
> (frame_id_build_unavailable_stack): New function.
> (frame_id_build, frame_id_build_wild): Adjust.
> (frame_id_p, frame_id_eq, frame_id_inner): Adjust to take into
> account frames with unavailable stack.
>
> * amd64-tdep.c (amd64_frame_this_id)
> (amd64_sigtramp_frame_this_id, amd64_epilogue_frame_this_id): Use
> frame_id_build_unavailable_stack.
> * dwarf2-frame.c (dwarf2_frame_this_id): Likewise.
Do we need to update tailcall_frame_this_id as well? I can't find an
easy way to reproduce it on tailcall frame (using
gdb.arch/amd64-tailcall-* cases).
Patch looks right to me, two nits on comments below,
> @@ -169,6 +187,12 @@ extern struct frame_id frame_id_build_special (CORE_ADDR stack_addr,
> CORE_ADDR code_addr,
> CORE_ADDR special_addr);
>
> +/* Construct a frame ID representing a frame where the stack address
> + exists, but is unavailable. The first parameter is the frame's
Remove "first"? since we only have one parameter here.
> + constant code address (typically the entry point). The special
> + identifier address is set to indicate a wild card. */
> +extern struct frame_id frame_id_build_unavailable_stack (CORE_ADDR code_addr);
> +
What does the last sentence mean in the comments?
--
Yao (éå)