From: Pedro Alves <palves@redhat.com>
To: Marc Khouzam <marc.khouzam@ericsson.com>
Cc: "'Mircea Gherzan'" <mircea.gherzan@intel.com>,
"'gdb-patches@sourceware.org'"
<gdb-patches@sourceware.org>,
"'mgherzan@gmail.com'" <mgherzan@gmail.com>
Subject: Re: [PATCH] Add the -catch-load and -catch-unload MI commands.
Date: Mon, 10 Sep 2012 14:09:00 -0000 [thread overview]
Message-ID: <504DF49D.7070700@redhat.com> (raw)
In-Reply-To: <F7CE05678329534C957159168FA70DEC5E116C3AD4@EUSAACMS0703.eamcs.ericsson.se>
On 08/30/2012 06:52 PM, Marc Khouzam wrote:
>
>> -----Original Message-----
>> From: Mircea Gherzan [mailto:mircea.gherzan@intel.com]
>> Sent: Thursday, August 30, 2012 1:47 PM
>> To: Marc Khouzam
>> Cc: 'gdb-patches@sourceware.org'; 'mgherzan@gmail.com'
>> Subject: Re: [PATCH] Add the -catch-load and -catch-unload MI
>> commands.
>>
>> On 30.08.2012 16:43, Marc Khouzam wrote:
>>>
>>>> -----Original Message-----
>>>> From: gdb-patches-owner@sourceware.org
>>>> [mailto:gdb-patches-owner@sourceware.org] On Behalf Of
>> Mircea Gherzan
>>>> Sent: Thursday, August 30, 2012 5:52 AM
>>>> To: gdb-patches@sourceware.org
>>>> Cc: mgherzan@gmail.com; Mircea Gherzan
>>>> Subject: [PATCH] Add the -catch-load and -catch-unload MI commands.
>>>>
>>>> They are equivalent to "catch load" and "catch unload" from CLI.
>>>>
>>>> Rationale: GUIs might be interested in catching solib load or
>>>> unload events.
>>>
>>> I think this can be done with:
>>> -gdb-set stop-on-solib-events 1
>>>
>>> although I don't believe there is support for regex as
>>> "catch load [regex]".
Yeah, and with catch load, gdb doesn't need to stop at each
and every internal libc solib event, even if nothing seemingly
interesting (in the user's perspective) happened.
>>
>> It's precisely this kind of support that I'm aiming at.
>>
>>> That being said, it may be better to have an MI command to
>> perform the
>>> "catch" command intead of specifically "catch load".
>>> For example, in Eclipse, we use "catch catch", "catch throw",
>>> "catch exec", "catch fork", "catch vfork", "catch syscall".
>>
>> Please, can you propose a format for such a command family? I
>> see it like:
>>
>> -catch --load [params] <regex>
>> -catch --unload [params] <regex>
>
> The GDB experts would know better, but I'm thinking of something
> like:
>
> -break-catch <load|unload|catch|throw|exec|fork|vfork|syscall> [regexp]
I don't this would be a good idea compared to separate commands. Each
of those catch variants takes different parameters/options. I'm not
seeing what putting them all under the same roof would buy.
In the CLI, although "catch exec", "catch fork", "catch syscall", etc.
have the same prefix, they're really implemented as separate commands
as well.
--
Pedro Alves
next prev parent reply other threads:[~2012-09-10 14:09 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-30 9:52 Mircea Gherzan
2012-08-30 14:44 ` Marc Khouzam
2012-08-30 17:47 ` Mircea Gherzan
2012-08-30 17:52 ` Marc Khouzam
2012-09-10 14:09 ` Pedro Alves [this message]
2012-09-10 14:48 ` Mircea Gherzan
2012-09-10 15:04 ` Marc Khouzam
2012-09-11 16:38 ` Tom Tromey
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=504DF49D.7070700@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=marc.khouzam@ericsson.com \
--cc=mgherzan@gmail.com \
--cc=mircea.gherzan@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox