From: Stan Shebs <stan@codesourcery.com>
To: Pedro Alves <pedro@codesourcery.com>
Cc: Stan Shebs <stan@codesourcery.com>, gdb-patches@sourceware.org
Subject: Re: tracing broken if target doesn't do disconnected tracing
Date: Wed, 07 Apr 2010 20:21:00 -0000 [thread overview]
Message-ID: <4BBCE927.3070401@codesourcery.com> (raw)
In-Reply-To: <201004071507.18770.pedro@codesourcery.com>
Pedro Alves wrote:
> On Wednesday 07 April 2010 14:32:49, Stan Shebs wrote:
>
>> Yeah, it's been troubling me too. User-settable variables are GDB's
>> traditional way of instructing GDB about user preferences, but the
>> canned method of phrase construction is too lame to express what is
>> really going on, which is "I prefer that targets to continue tracing
>> after disconnect, whether or not the current target can actually do so".
>> We could use something other than set/show, or invent a better method to
>> produce output - there are other set/shows for which the verbiage is
>> rather contorted.
>>
>
> Hmm, can you expand on what lameness you're referring to exactly?
> Is it a technical limitation?
>
It's the requirement to describe the variable with a noun phrase like
"foo bar of baz", so that the output can be "foo bar of baz is on" etc.
For simple settings the algorithm is reasonable, but as the concept gets
more complicated, the phrasing gets more tortured.
> These commands seem to fall in a close category:
>
> (gdb) apropos willingness
> set can-use-hw-watchpoints -- Set debugger's willingness to use watchpoint hardware
> set displaced-stepping -- Set debugger's willingness to use displaced stepping
> show can-use-hw-watchpoints -- Show debugger's willingness to use watchpoint hardware
> show displaced-stepping -- Show debugger's willingness to use displaced stepping
>
> Maybe we could follow suit similarly, or instead say something
> like: "Show whether GDB prefers to/that/whether ..."
>
These are perfect examples of the same problem - "willingness" is not
the right word. What these flags really mean is "use if possible", but
that's a verb in an imperative form plus a conditional, and it doesn't
have a direct equivalent as a noun phrase. Ideally, the "use if
possible" would be augmented with "and it's possible" or "but it's not
possible for reason X" so that the user can see both that the setting is
as desired, and whether the debugger is able to respect it.
Not a difficult extension to the command definition machinery, just have
to spend some time on it.
Stan
next prev parent reply other threads:[~2010-04-07 20:21 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-05 0:01 Pedro Alves
2010-04-05 1:08 ` Stan Shebs
2010-04-05 11:04 ` Pedro Alves
2010-04-07 1:34 ` Stan Shebs
2010-04-07 11:40 ` Pedro Alves
2010-04-07 13:33 ` Stan Shebs
2010-04-07 13:47 ` Pedro Alves
2010-04-07 14:07 ` Pedro Alves
2010-04-07 20:21 ` Stan Shebs [this message]
2010-04-07 22:06 ` Pedro Alves
2010-04-07 13:35 ` Pedro Alves
2010-04-07 22:04 ` Stan Shebs
2010-04-08 17:25 ` Pedro Alves
2010-04-08 18:19 ` Stan Shebs
2010-04-08 18:32 ` Pedro Alves
2010-04-08 19:10 ` Stan Shebs
2010-04-09 3:10 ` Stan Shebs
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=4BBCE927.3070401@codesourcery.com \
--to=stan@codesourcery.com \
--cc=gdb-patches@sourceware.org \
--cc=pedro@codesourcery.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