Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* Assumptions on the number of hw watchpoints for some testcases
@ 2010-09-16 14:56 Luis Machado
  2010-09-16 15:42 ` Eli Zaretskii
  0 siblings, 1 reply; 2+ messages in thread
From: Luis Machado @ 2010-09-16 14:56 UTC (permalink / raw)
  To: gdb

Hi,

Recently i've noticed that some of the newer watchpoint-related
(watchpoint.exp, watchthreads.exp and local-watch-wrong-thread.exp for
example) testcases were failing due to the testcases themselves not
respecting the fact that PPC server processors only have a single HW
watchpoint register. Some of the testcases check for "watch *0x0" as a
means to tell if the platform actually supports doing "watch *var" in
HW. That doesn't work correctly on PPC server processors since "watch
*0x0" will use a HW watchpoint and "watch *var" will fall back to two SW
watchpoints...

I may declare watchthreads.exp unsupported for PPC server as it has a
strong assumption that the target can do 2 HW watchpoints or i can write
a different testcase relying on a single HW watchpoint.

As for the others, i'll try to make the tests more flexible.

I don't think GDB has a handy maint command to tell the testcases how
many HW watches a target can use.

Regards,
Luis


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

* Re: Assumptions on the number of hw watchpoints for some testcases
  2010-09-16 14:56 Assumptions on the number of hw watchpoints for some testcases Luis Machado
@ 2010-09-16 15:42 ` Eli Zaretskii
  0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2010-09-16 15:42 UTC (permalink / raw)
  To: luisgpm; +Cc: gdb

> From: Luis Machado <luisgpm@linux.vnet.ibm.com>
> Reply-To: luisgpm@linux.vnet.ibm.com
> Date: Thu, 16 Sep 2010 11:56:10 -0300
> 
> I don't think GDB has a handy maint command to tell the testcases how
> many HW watches a target can use.

It doesn't, and it can't: the amount of HW watches available depends
on the alignment and size of the region being watched, and sometimes
on other factors.

The only way of dealing intelligently with these limitations is to
modify the test cases so that they dynamically detect when the HW
resources are exhausted and skip the affected tests.  Not sure how
much labor that would need or whether it's worth the hassle.


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

end of thread, other threads:[~2010-09-16 15:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-09-16 14:56 Assumptions on the number of hw watchpoints for some testcases Luis Machado
2010-09-16 15:42 ` Eli Zaretskii

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