This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [patch, rfc, 6.0] Change frame predicates to sniffers
- From: Michael Elizabeth Chastain <mec at shout dot net>
- To: ac131313 at redhat dot com, gdb-patches at sources dot redhat dot com
- Date: Sat, 12 Jul 2003 15:19:33 -0400
- Subject: Re: [patch, rfc, 6.0] Change frame predicates to sniffers
My test bed says: no regressions, no improvements.
Tested on native i686-pc-linux-gnu, gcc v2 and v3 (several flavors
of v3), -gdwarf-2 and -gstabs+.
> Can anyone point me at testcases that will magically start passing with
> this fixed?
If you want test scripts, try:
gdb.base/corefile.exp: backtrace in corefile.exp
gdb.base/corefile.exp: print func2::coremaker_local
gdb.mi/mi-syn-frame.exp: 407-stack-list-frames
gdb.threads/pthreads.exp: check backtrace from main thread
gdb.threads/pthreads.exp: apply backtrace command to all three threads
gdb.threads/pthreads.exp: check backtrace from thread 2
Or download the attachments from pr gdb/1250, pr gdb/1253,
and pr gdb/1255, and play with those.
Michael C
===
2003-07-11 Andrew Cagney <cagney@redhat.com>
* frame.c (get_frame_id): Use frame_unwind_find_by_frame.
(frame_register_unwind, create_new_frame): Ditto.
(legacy_get_prev_frame, get_frame_type): Ditto.
(get_frame_base_address): Use frame_base_find_by_frame.
(get_frame_locals_address): Use frame_base_find_by_frame.
(get_frame_args_address): Use frame_base_find_by_frame.
* frame-base.h (frame_base_sniffer_ftype): Declare.
(frame_base_append_sniffer): Declare.
(frame_base_find_by_frame): Replace frame_base_find_by_pc.
* frame-base.c (append_predicate): Add a "sniffer" parameter.
(frame_base_append_sniffer): New function.
(frame_base_append_predicate): Add a NULL sniffer.
(frame_base_find_by_frame): Replace "frame_base_find_by_pc".
(struct frame_base_table): Add "sniffer".
(frame_base_free): Free the "sniffer" table.
* frame-unwind.h (frame_unwind_sniffer_ftype): Define.
(frame_unwind_append_sniffer): Declare.
(frame_unwind_find_by_frame): Replace frame_unwind_find_by_pc.
* frame-unwind.c (frame_unwind_free): Free the "sniffer" table.
(struct frame_unwind_table): Add "sniffer", delete "middle".
(append_predicate): Add "sniffer" parameter, append the sniffer.
(frame_unwind_init): Update append_predicate call.
(frame_unwind_append_sniffer): New function.
(frame_unwind_append_predicate): Update append_predicate call.
(frame_unwind_find_by_frame): Replace frame_unwind_find_by_pc.