This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[RFC] Skip hardware breakpoint tests on OpenBSD


The recently introduced skip_hw_breakpoint_tests procedure is a bit
flawed.  It lists hardware platforms that have hardware breakpoints,
but doesn't take into account that the OS running on those platforms
has to make that functionality available to GDB.  This isn't the case
on OpenBSD (and perhaps some other operating systems as well).  The
diff below makes sure the tests are skipped on OpenBSD.  However,
perhaps instead of whitelisting generic hardware platforms, we should
whitelis explicit hardware/OS combinations here?

Thoughts?

2011-03-09  Mark Kettenis  <kettenis@gnu.org>

        * lib/gdb.exp (skip_hw_breakpoint_tests): None of the OpenBSD
        targets actually implement hardware breakpoints, so return 1 for
        *-*-openbsd*.

Index: lib/gdb.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/lib/gdb.exp,v
retrieving revision 1.167
diff -u -p -r1.167 gdb.exp
--- lib/gdb.exp	9 Mar 2011 14:17:05 -0000	1.167
+++ lib/gdb.exp	9 Mar 2011 16:20:41 -0000
@@ -1795,6 +1795,11 @@ proc skip_hw_breakpoint_tests {} {
 	return 1
     }
 
+    # These targets don't support hardware breakpints
+    if { [istarget "*-*-openbsd*"] } {
+	return 1
+    }
+
     # These targets support hardware breakpoints natively
     if { [istarget "i?86-*-*"] 
 	 || [istarget "x86_64-*-*"]


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]