This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA 1/4] Explicit locations
- From: Tom Tromey <tromey at redhat dot com>
- To: Keith Seitz <keiths at redhat dot com>
- Cc: "gdb-patches\ at sourceware dot org ml" <gdb-patches at sourceware dot org>
- Date: Wed, 21 Aug 2013 12:01:56 -0600
- Subject: Re: [RFA 1/4] Explicit locations
- References: <514B9E8F dot 6080306 at redhat dot com>
>>>>> "Keith" == Keith Seitz <keiths@redhat.com> writes:
Keith> This is a reboot of a series of patches I submitted several months
Keith> ago. The feature I am attempting to introduce will essentially allow
Keith> users to bypass the linespec parser.
I'm sorry for the long delay on this.
Keith> +/* An enumeration of the various ways to specify a stop event
Keith> + location (used with create_breakpoint). */
Keith> +
Keith> +enum event_location_type
Keith> + {
There's some inconsistency in Emacs and GNU here, but I think we
generally try to put that open brace in column 0.
I think event_location_type and friends could go in new .h and .c files.
breakpoint.c is already one of the largest files we have.
Keith> int
Keith> create_breakpoint (struct gdbarch *gdbarch,
Keith> - char *arg, char *cond_string,
Keith> + struct event_location *location, char *cond_string,
Keith> int thread, char *extra_string,
I think the intro comment needs an update.
The ownership of the passed-in location wasn't totally clear to me.
E.g., there's at least one spot initializing a location with a
non-malloc'd string; which I guess is fine provided the ownership rules
are clearly spelled out.
I think it would be good to spell out the plan for -probe arguments.
It seems like it would be good to integrate them. For one thing, maybe
that would make it so dprintf could work with probe locations...
Tom