Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: Pedro Alves <pedro@codesourcery.com>
Cc: Tristan Gingold <gingold@adacore.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode
Date: Tue, 13 Dec 2011 17:24:00 -0000	[thread overview]
Message-ID: <20111213172318.GA9565@host2.jankratochvil.net> (raw)
In-Reply-To: <201112122013.51990.pedro@codesourcery.com>

On Mon, 12 Dec 2011 21:13:51 +0100, Pedro Alves wrote:
> Maybe we should still have something like
> 
> if { istarget [ia64*-*-*] || .... } {
>   set_board_info gdb,no_hardware_watchpoints 1
> }
> 
> somewhere gdbserver specific.

The correct would be if gdbserver sends hardware watchpoints support in the
qSupported reply and GDB can print the response in some way.

In reality proposing to add to
	http://sourceware.org/gdb/wiki/TestingGDB#Native_Board_File
your proposed:
	# Some FSF gdbserver targets can't do hardware watchpoints.
	if [istarget "ia64*-*-*"] {
	  set_board_info gdb,no_hardware_watchpoints 1
	}


> Some ports, like ia64 gdbserver
> don't support watchpoints.  I think you can test a native
> gdbserver with this board on ia64-linux, but this isn't really
> native board specific --- a cross test should find watchpoints
> support disabled too.  Maybe in gdbserver-support.exp?  WDYT?

I do not find gdbserver-support.exp appropriate as the problem of missing ia64
watchpoints in FSF gdbserver does not apply to other implementations of
gdbserver while gdbserver-support.exp still gets used for non-FSF gdbservers.

Unless there is qSupported I find the board file appropriate, as it describes
the specific gdb<->gdbserver setup.

But I am far from experienced with advanced gdbserver stuff.


> > +load_lib gdbserver-support.exp
> > +
> > +if {[skip_hw_watchpoint_access_tests]
> > +    || (![istarget "i?86-*-linux*"] && ![istarget "x86_64-*-linux*"])
> > +    || ([is_remote target] && [skip_gdbserver_tests])} {
> > +    return 0
> > +}
> 
> > +
> > +if [is_remote target] {
> > +    gdbserver_start_extended
> > +}
> 
> Hmm, I'm not sure if this is really a good idea to spread
> gdbserver_start_extended around like this.  I think it would be
> better to skip the test if testing against plain "target remote".
> I mean, you may be remote testing against qemu, for example.  Having
> the test spawn GDBserver and actually run would be misleading.  Once
> we have a board that tests the whole testsuite with extended-remote
> working, then we'll clearly want the present board to skip tests
> it doesn't support.  (the gdb.server/ tests being the exception.)
> WDYT?

I have described this in:
	http://sourceware.org/ml/gdb-patches/2011-12/msg00088.html

Personally I would prefer always to follow the rules from there:
   * Some testcases skip themselves if their mode/board is not satisfied.
     --- if [is_remote target] then { return 0 }
 * If a testcase is compatible with any mode/board it uses the mode/board
   specified by user for the testsuite.

Therefore gdb.server/ would get whole skipped during the normal run.
Currently I run the testsuite already in multiple modes and some testcases run
in duplicate configurations that way, costing needless time+power=money.


As a less ambitious change if you do not like gdbserver_start_extended in this
testcase we can change it.  But gdb.server/ext-*.exp do exactly the same so
they have to be changed all together. we can introduce new:
	set_board_info gdb,extended_protocol_supported 1



Thanks,
Jan


  reply	other threads:[~2011-12-13 17:23 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-05 16:46 Pedro Alves
2011-12-05 17:06 ` Eli Zaretskii
2011-12-09 16:30   ` New tests to watch regions larger than a machine word (Re: [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode) Pedro Alves
2011-12-09 19:11     ` Eli Zaretskii
2011-12-13 16:12       ` Pedro Alves
2011-12-05 21:24 ` [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode Jan Kratochvil
2011-12-09 16:45   ` Pedro Alves
2011-12-09 16:47     ` Tristan Gingold
2011-12-09 19:23     ` Eli Zaretskii
2011-12-13 16:26       ` Pedro Alves
2011-12-11 23:39     ` Jan Kratochvil
2011-12-12 11:53       ` Pedro Alves
2011-12-12 14:49         ` Jan Kratochvil
2011-12-12  0:14     ` Jan Kratochvil
2011-12-12 17:23       ` Pedro Alves
2011-12-12 18:38         ` Jan Kratochvil
2011-12-12 20:14           ` Jan Kratochvil
2011-12-12 20:30             ` Pedro Alves
2011-12-13 17:24               ` Jan Kratochvil [this message]
2011-12-13 18:49                 ` Pedro Alves
2011-12-13 19:25                   ` Jan Kratochvil
2011-12-16 16:16                     ` Pedro Alves
2012-01-20 19:51                       ` testsuite: native/non-extended/extended modes [Re: [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode] Jan Kratochvil
2012-01-20 19:53                         ` Pedro Alves
2012-01-20 19:57                           ` Jan Kratochvil
2011-12-12 20:34             ` [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode Pedro Alves
2011-12-12 21:39               ` Jan Kratochvil
2011-12-13 16:21                 ` Fix PR remote/13492 (Re: [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode) Pedro Alves
2011-12-13 17:23                   ` Fix PR remote/13492 Jan Kratochvil
2011-12-13 16:33                 ` [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode Pedro Alves
2011-12-13 18:57                   ` Jan Kratochvil
2011-12-14 17:35                     ` Pedro Alves
2011-12-14 17:42                       ` Pedro Alves
2011-12-15  8:48                         ` Regression for T (Stopped) processes [Re: [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode] Jan Kratochvil
2011-12-15 12:44                           ` Pedro Alves
2011-12-15 15:33                             ` Jan Kratochvil
2011-12-13 22:27                   ` [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode Jan Kratochvil

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=20111213172318.GA9565@host2.jankratochvil.net \
    --to=jan.kratochvil@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=gingold@adacore.com \
    --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