From: Pedro Alves <palves@redhat.com>
To: Yao Qi <qiyaoltc@gmail.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH 0/3] Use selftest.c in GDBserver
Date: Fri, 11 Aug 2017 17:11:00 -0000 [thread overview]
Message-ID: <5d074f53-2f39-4e87-ee48-c035aa2b81a3@redhat.com> (raw)
In-Reply-To: <1502465408-24668-1-git-send-email-yao.qi@linaro.org>
On 08/11/2017 04:30 PM, Yao Qi wrote:
> This patch series is split from "[PATCH 00/26 v3] Make GDB builtin
> target descriptions more flexible"
> https://sourceware.org/ml/gdb-patches/2017-07/msg00076.html, because,
> IMO, adding self/unit tests in GDBserver doesn't related much to my
> target description patches. My target description patches only use
> common/selftest.c to do some unit tests in GDBserver.
>
> I also want to include one patch to use self tests in GDBserver, but
> can't find a module in GDBserver to test.
Nice, I had skimmed version of the patches in the large series a couple
weeks back, and was planning on suggesting to move the gdb-specifics to
hooks implemented by the client. Which is exactly what you've done.
Moving to selftests namespace seems like a good idea to me too.
I guess you could have left QUIT in the gdb hook, though it's fine with me
to remove it.
I wonder whether "gdbserver --help" should really advertise --selftests,
given it's a maintenance command and essentially does nothing in
release mode.
Implementing gdb's version of "selftest::reset ()" in selftest-arch.c
directly feels a bit like an abstraction violation. The cleanest would I
guess be to add a new .c file with reset() that calls a new
selftest-arch.c:reset_arch(), but we can always do that later if we need to
reset other things.
Otherwise, LGTM.
Actually, I sent a couple comments to patch #3 now. But it's
all minor things.
Thanks,
Pedro Alves
prev parent reply other threads:[~2017-08-11 17:11 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-11 15:31 Yao Qi
2017-08-11 15:31 ` [PATCH 1/3] Put selftests api into selftests namespace Yao Qi
2017-08-11 15:31 ` [PATCH 2/3] Remove some GDB specific stuff from selftest.c Yao Qi
2017-08-11 15:31 ` [PATCH 3/3] GDBserver self tests Yao Qi
2017-08-11 16:01 ` Eli Zaretskii
2017-08-11 17:10 ` Pedro Alves
2017-08-18 8:16 ` Yao Qi
2017-08-11 17:11 ` Pedro Alves [this message]
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=5d074f53-2f39-4e87-ee48-c035aa2b81a3@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=qiyaoltc@gmail.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