This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 1/3] Target remote mode fork and exec events
- From: Don Breazeal <donb at codesourcery dot com>
- To: Pedro Alves <palves at redhat dot com>, "gdb-patches at sourceware dot org" <gdb-patches at sourceware dot org>
- Date: Fri, 20 Nov 2015 08:49:55 -0800
- Subject: Re: [PATCH 1/3] Target remote mode fork and exec events
- Authentication-results: sourceware.org; auth=none
- References: <1446854188-496-1-git-send-email-donb at codesourcery dot com> <1446854188-496-2-git-send-email-donb at codesourcery dot com> <564F1A6A dot 3030301 at redhat dot com>
On 11/20/2015 5:04 AM, Pedro Alves wrote:
> Hi Don,
>
> Thanks for doing this. Starting to look at the series.
Thanks!
>
> On 11/06/2015 11:56 PM, Don Breazeal wrote:
>> This patch implements support for fork and exec events with target remote
>> mode Linux targets. For such targets with Linux kernels 2.5.46 and later,
>> this enables follow-fork-mode, detach-on-fork and fork and exec
>> catchpoints.
>
>> Note that follow-exec-mode is not supported, because target
>> remote mode does not support the 'run' command.
>
> Not sure I don't understand this part/comment.
I assume that we agree that the 'run' command is not supported in target
remote mode.
Maybe a better way to have stated this would be that follow-exec-mode is
of limited used in target remote mode, since the 'run' command is not
supported. The point being that the main reason a user would want to
set follow-exec-mode would be to get control over which inferior is run
when a 'run' command is executed.
I have to admit that it is incorrect to say that it is unsupported,
since setting follow-exec-mode *will* control whether a new inferior or
the same inferior is used for the execed program. But there isn't much
you can do differently without the 'run' command. Using
follow-exec-mode 'new' there *is* a record of what programs have been
run, which could be useful.
Is that a more accurate description, or am I misunderstanding something?
I'll get to work on the rest of this, hopefully sometime next week.
thanks
--Don