]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
2003-05-16 David Carlton <carlton@bactrian.org>
authorDavid Carlton <carlton@bactrian.org>
Fri, 16 May 2003 16:10:54 +0000 (16:10 +0000)
committerDavid Carlton <carlton@bactrian.org>
Fri, 16 May 2003 16:10:54 +0000 (16:10 +0000)
* carlton_runnamespace: Run gdb.c++/rtti.exp, too.
* carlton_runtest (FASTTESTS): Add gdb.c++/breakpoint.exp and
gdb.c++/rtti.exp.
* gdb.c++/breakpoint.exp (test_breakpoint): Run to main for every
breakpoint.
* gdb.c++/rtti.exp: Add more KFAIL branches.

gdb/testsuite/ChangeLog
gdb/testsuite/carlton_runnamespace
gdb/testsuite/carlton_runtest
gdb/testsuite/gdb.c++/breakpoint.exp
gdb/testsuite/gdb.c++/rtti.exp

index df5c7f76ed781d5f63c378029ffdf2cbd6716b47..8f67f2ef7be9ede495ce833659e826789957efc9 100644 (file)
@@ -1,3 +1,12 @@
+2003-05-16  David Carlton  <carlton@bactrian.org>
+
+       * carlton_runnamespace: Run gdb.c++/rtti.exp, too.
+       * carlton_runtest (FASTTESTS): Add gdb.c++/breakpoint.exp and
+       gdb.c++/rtti.exp.
+       * gdb.c++/breakpoint.exp (test_breakpoint): Run to main for every
+       breakpoint.
+       * gdb.c++/rtti.exp: Add more KFAIL branches.
+
 2003-05-09  David Carlton  <carlton@bactrian.org>
 
        * gdb.c++/breakpoint.cc: New.
index e8ce420697c742341a790a847ed7ead72aeddae6..60e4dfe7a0f67d618e907951f73bad3dac905edb 100755 (executable)
@@ -6,13 +6,14 @@
 # stabs info, too?
 
 EXTRADEBUGPATH=/usr/local/testbed/gcc3/bin
+TESTS="gdb.c++/namespace.exp gdb.c++/rtti.exp"
 
 echo "Running tests using regular compiler."
-runtest gdb.c++/namespace.exp > /dev/null 2>&1
+runtest ${TESTS} > /dev/null 2>&1
 grep -v "^Test Run By" gdb.sum > /tmp/namespaceout
 diff -u {carlton_,/tmp/}namespaceout
 echo "Running tests using compiler with extra debug info."
-PATH=${EXTRADEBUGPATH}:${PATH} runtest gdb.c++/namespace.exp > /dev/null 2>&1
+PATH=${EXTRADEBUGPATH}:${PATH} runtest ${TESTS} > /dev/null 2>&1
 grep -v "^Test Run By" gdb.sum > /tmp/namespacedebugout
 diff -u {carlton_,/tmp/}namespacedebugout
 
index 806ea8cae39e0c701b5f3769900ba213e3a1b439..db4ad87c2ba357d9ec9108c00e3054a1e4b63428 100755 (executable)
@@ -24,7 +24,9 @@ FASTTESTS="gdb.base/assign.exp \
   gdb.c++/local.exp \
   gdb.c++/m-data.exp \
   gdb.c++/m-static.exp \
-  gdb.c++/method.exp"
+  gdb.c++/method.exp \
+  gdb.c++/breakpoint.exp \
+  gdb.c++/rtti.exp"
 
 # 6 seconds or more (usually around 10).
 MEDTESTS="gdb.base/exprs.exp \
index 3a132b03416e84250349be8c11c58479313264de..89231059a8424208367df6ecfd12475cb76532a6 100644 (file)
@@ -53,13 +53,15 @@ gdb_reinitialize_dir $srcdir/$subdir
 gdb_load ${binfile}
 
 proc test_breakpoint {name} {
-    gdb_breakpoint "${name}"
-    gdb_test "continue" "Continuing.\r\n\r\nBreakpoint \[0-9\]*, ${name}.*" "continue to ${name}"
-}
-
-if ![runto_main] then {
-    perror "couldn't run to breakpoint"
-    continue
+    # Restart the program every time, so that a single failure doesn't
+    # lead to a cascade.
+    if ![runto_main] then {
+       perror "couldn't run to main when testing ${name}"
+       continue
+    } else {
+       gdb_breakpoint "${name}"
+       gdb_test "continue" "Continuing.\r\n\r\nBreakpoint \[0-9\]*, ${name}.*" "continue to ${name}"
+    }
 }
 
 test_breakpoint "C1::Nested::foo"
index 6f79c711a7fb35e06a527c7c490249d381c5b7d4..e968e808041d0bfaafc39f00f02506ba35e86cb8 100644 (file)
@@ -88,13 +88,21 @@ gdb_test_multiple "print *e1" "print *e1" {
     -re "\\$\[0-9\]* = {<n1::Base1> = .*}\r\n$gdb_prompt $" {
        pass "print *e1"
     }
+    -re "\\$\[0-9\]* = {<.*Base1> = .*}\r\n$gdb_prompt $" {
+       # NOTE: carlton/2003-05-09: Sometimes, the DWARF reader gets
+       # confused about names.  I've seen just Base1 or
+       # n1::D1::C1::Base1.
+       kfail "gdb/TBA" "print *e2"
+    }
 }
 
 # NOTE: carlton/2003-05-02: This test fails on my branch because,
 # within rtt1.cc, GDB has no way of knowing that the class is called
 # 'n2::D2' instead of just 'D2'.  This is an artifical test case,
 # though: if we were using these classes in a more substantial way,
-# G++ would emit more debug info.
+# G++ would emit more debug info.  Arguably, the "incomplete type"
+# kfail should really be an xfail, because it works using a compiler
+# that generates DW_TAG_namespace tags.
 
 gdb_test_multiple "print *e2" "print *e2" {
     -re "warning: can't find class named `n2::D2', as given by C\\+\\+ RTTI.*$gdb_prompt $" {
@@ -106,6 +114,9 @@ gdb_test_multiple "print *e2" "print *e2" {
     -re "\\$\[0-9\]* = {<n2::Base2> = .*}\r\n$gdb_prompt $" {
        pass "print *e2"
     }
+    -re "\\$\[0-9\]* = {<.*Base2> = .*}\r\n$gdb_prompt $" {
+       kfail "gdb/TBA" "print *e2"
+    }
 }
 
 gdb_exit