Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* gdb.base/watchpoint-solib.exp
@ 2008-07-13 15:09 Mark Kettenis
  2008-07-13 16:49 ` gdb.base/watchpoint-solib.exp Vladimir Prus
  0 siblings, 1 reply; 6+ messages in thread
From: Mark Kettenis @ 2008-07-13 15:09 UTC (permalink / raw)
  To: vladimir; +Cc: gdb

Hi Vladimir,

The watchpoint-solib.exp test seems to assume hardware watchpoints:

  gdb_test "watch g" "Hardware watchpoint 3: g" "set watchpoint on g"

Is this intentional, or should this be changed to accept "normal"
software watchpoints too?

Thanks,

Mark


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb.base/watchpoint-solib.exp
  2008-07-13 15:09 gdb.base/watchpoint-solib.exp Mark Kettenis
@ 2008-07-13 16:49 ` Vladimir Prus
  2008-07-13 17:06   ` gdb.base/watchpoint-solib.exp Mark Kettenis
  0 siblings, 1 reply; 6+ messages in thread
From: Vladimir Prus @ 2008-07-13 16:49 UTC (permalink / raw)
  To: gdb

Mark Kettenis wrote:

> Hi Vladimir,
> 
> The watchpoint-solib.exp test seems to assume hardware watchpoints:
> 
>   gdb_test "watch g" "Hardware watchpoint 3: g" "set watchpoint on g"
> 
> Is this intentional, or should this be changed to accept "normal"
> software watchpoints too?

Hi Mark,

this test was added by http://article.gmane.org/gmane.comp.gdb.patches/37556
and that commits changes the way the memory locations to watch are stored
and handled for watchpoint. Since software watchpoints do not actually have
any memory locations to watch, I suspect that the crash this test is supposed
to guard against did not happen with software watchpoints. Are you on a target
with no hardware breakpoints?

- Volodya



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb.base/watchpoint-solib.exp
  2008-07-13 16:49 ` gdb.base/watchpoint-solib.exp Vladimir Prus
@ 2008-07-13 17:06   ` Mark Kettenis
  2008-07-13 17:53     ` gdb.base/watchpoint-solib.exp Vladimir Prus
  0 siblings, 1 reply; 6+ messages in thread
From: Mark Kettenis @ 2008-07-13 17:06 UTC (permalink / raw)
  To: vladimir; +Cc: gdb

> From: Vladimir Prus <vladimir@codesourcery.com>
> Date:  Sun, 13 Jul 2008 20:48:39 +0400
> 
> Mark Kettenis wrote:
> 
> > Hi Vladimir,
> > 
> > The watchpoint-solib.exp test seems to assume hardware watchpoints:
> > 
> >   gdb_test "watch g" "Hardware watchpoint 3: g" "set watchpoint on g"
> > 
> > Is this intentional, or should this be changed to accept "normal"
> > software watchpoints too?
> 
> Hi Mark,
> 
> this test was added by
> http://article.gmane.org/gmane.comp.gdb.patches/37556 and that
> commits changes the way the memory locations to watch are stored and
> handled for watchpoint. Since software watchpoints do not actually
> have any memory locations to watch, I suspect that the crash this
> test is supposed to guard against did not happen with software
> watchpoints.

Ah, if you want to explicity test hardware watchpoints, perhaps we
should test that the target supports them and skip the test otherwise.

> Are you on a target with no hardware breakpoints?

Yes I am.  OpenBSD doesn't support hardware watchpoints on any of its
platforms.  But even many Linux targets don't support hardware
watchpoints.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb.base/watchpoint-solib.exp
  2008-07-13 17:06   ` gdb.base/watchpoint-solib.exp Mark Kettenis
@ 2008-07-13 17:53     ` Vladimir Prus
  2008-07-13 18:21       ` gdb.base/watchpoint-solib.exp Daniel Jacobowitz
  0 siblings, 1 reply; 6+ messages in thread
From: Vladimir Prus @ 2008-07-13 17:53 UTC (permalink / raw)
  To: Mark Kettenis; +Cc: gdb

On Sunday 13 July 2008 21:04:56 Mark Kettenis wrote:
> > From: Vladimir Prus <vladimir@codesourcery.com>
> > Date:  Sun, 13 Jul 2008 20:48:39 +0400
> > 
> > Mark Kettenis wrote:
> > 
> > > Hi Vladimir,
> > > 
> > > The watchpoint-solib.exp test seems to assume hardware watchpoints:
> > > 
> > >   gdb_test "watch g" "Hardware watchpoint 3: g" "set watchpoint on g"
> > > 
> > > Is this intentional, or should this be changed to accept "normal"
> > > software watchpoints too?
> > 
> > Hi Mark,
> > 
> > this test was added by
> > http://article.gmane.org/gmane.comp.gdb.patches/37556 and that
> > commits changes the way the memory locations to watch are stored and
> > handled for watchpoint. Since software watchpoints do not actually
> > have any memory locations to watch, I suspect that the crash this
> > test is supposed to guard against did not happen with software
> > watchpoints.
> 
> Ah, if you want to explicity test hardware watchpoints, perhaps we
> should test that the target supports them and skip the test otherwise.

Is there a read-made way to check if hardware watchpoints are supported?

- Volodya


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb.base/watchpoint-solib.exp
  2008-07-13 17:53     ` gdb.base/watchpoint-solib.exp Vladimir Prus
@ 2008-07-13 18:21       ` Daniel Jacobowitz
  2008-07-16  2:48         ` gdb.base/watchpoint-solib.exp Michael Snyder
  0 siblings, 1 reply; 6+ messages in thread
From: Daniel Jacobowitz @ 2008-07-13 18:21 UTC (permalink / raw)
  To: Vladimir Prus; +Cc: Mark Kettenis, gdb

On Sun, Jul 13, 2008 at 09:53:16PM +0400, Vladimir Prus wrote:
> Is there a read-made way to check if hardware watchpoints are supported?

Yes, check most of the other watchpoint tests.  I think it's
can_use_hw_watchpoints.


-- 
Daniel Jacobowitz
CodeSourcery


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb.base/watchpoint-solib.exp
  2008-07-13 18:21       ` gdb.base/watchpoint-solib.exp Daniel Jacobowitz
@ 2008-07-16  2:48         ` Michael Snyder
  0 siblings, 0 replies; 6+ messages in thread
From: Michael Snyder @ 2008-07-16  2:48 UTC (permalink / raw)
  To: Daniel Jacobowitz; +Cc: Vladimir Prus, Mark Kettenis, gdb

On Sun, 2008-07-13 at 14:21 -0400, Daniel Jacobowitz wrote:
> On Sun, Jul 13, 2008 at 09:53:16PM +0400, Vladimir Prus wrote:
> > Is there a read-made way to check if hardware watchpoints are supported?
> 
> Yes, check most of the other watchpoint tests.  I think it's
> can_use_hw_watchpoints

    if {[target_info exists gdb,no_hardware_watchpoints]} {



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2008-07-16  2:48 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-07-13 15:09 gdb.base/watchpoint-solib.exp Mark Kettenis
2008-07-13 16:49 ` gdb.base/watchpoint-solib.exp Vladimir Prus
2008-07-13 17:06   ` gdb.base/watchpoint-solib.exp Mark Kettenis
2008-07-13 17:53     ` gdb.base/watchpoint-solib.exp Vladimir Prus
2008-07-13 18:21       ` gdb.base/watchpoint-solib.exp Daniel Jacobowitz
2008-07-16  2:48         ` gdb.base/watchpoint-solib.exp Michael Snyder

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox