[patch/rfc] KFAIL gdb.c++/annota2.exp watch triggered on a.x

David Carlton
2003-01-03T21:36:11Z

Here's a patch to KFAIL the test "watch triggered on a.x" in
gdb.c++/annota2.exp, corresponding to PR breakpoints/38. The test
fails consistently on all the configurations that Michael tests.

This is an obvious candidate for KFAILing. My only question is when
it should currently be expected to pass. The PR indicates that it
might pass on some platforms; on the other hand, it fails reliably
on i686-pc-linux-gnu. So what I did was change the two existing
instances of

{ pass "watch triggered on a.x" }

to

{ setup_kfail "gdb/38" "i686*-*-*"
pass "watch triggered on a.x" }

but I made the new KFAIL case unconditional. That seemed to be the
safest thing: that way, any FAIL or KPASS message is interesting.

I'm also a little worried that there are two pass regexps listed
whereas I'm only listing one fail regexp; it seems plausible to me
that I should add a second fail regexp. But I don't want to do that
without seeing such a pattern in the wild.

I'll commit this on Wednesday unless somebody disagrees with how I'm
handling when to {K,}{FAIL,PASS} or unless somebody turns up more
KFAIL regexps.

David Carlton
carlton@math.stanford.edu

2003-01-03 David Carlton <carlton@math.stanford.edu>

* gdb.c++/annota2.exp: KFAIL "watch triggered on a.x".
Add copyright year 2003.

Index: annota2.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.c++/annota2.exp,v
retrieving revision 1.8
diff -u -p -r1.8 annota2.exp
--- annota2.exp 20 Dec 2002 18:37:15 -0000 1.8
+++ annota2.exp 3 Jan 2003 21:18:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002
+# Copyright 1999, 2000, 2001, 2002, 2003
# Free Software Foundation, Inc.

# This program is free software; you can redistribute it and/or modify
@@ -194,9 +194,13 @@ gdb_expect {
send_gdb "next\n"
gdb_expect {
-re "\r\n\032\032post-prompt\r\n\r\n\032\032starting\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032watchpoint 3\r\nWatchpoint 3: a.x\r\n\r\nOld value = 0\r\nNew value = 1\r\n\r\n\032\032frame-begin 0 $hex\r\n\r\n\032\032frame-function-name\r\nmain\r\n\032\032frame-args\r\n \\(\\)\r\n\032\032frame-source-begin\r\n at \r\n\032\032frame-source-file\r\n.*$srcfile\r\n\032\032frame-source-file-end\r\n:\r\n\032\032frame-source-line\r\n$decimal\r\n\032\032frame-source-end\r\n\r\n\r\n\032\032source .*$srcfile.*beg:$hex\r\n\r\n\032\032frame-end\r\n\r\n\032\032stopped\r\n$gdb_prompt$" \
- { pass "watch triggered on a.x" }
+ { setup_kfail "gdb/38" "i686*-*-*"
+ pass "watch triggered on a.x" }
-re "\r\n\032\032post-prompt\r\n\r\n\032\032starting\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032watchpoint 3\r\n\.*atchpoint 3: a.x\r\n\r\nOld value = 0\r\nNew value = 1\r\n\r\n\032\032frame-begin 0 $hex\r\n\r\n\032\032frame-function-name\r\nmain\r\n\032\032frame-args\r\n \\(\\)\r\n\032\032frame-source-begin\r\n at \r\n\032\032frame-source-file\r\n.*$srcfile\r\n\032\032frame-source-file-end\r\n:\r\n\032\032frame-source-line\r\n$decimal\r\n\032\032frame-source-end\r\n\r\n\r\n\032\032source .*$srcfile.*beg:$hex\r\n\r\n\032\032frame-end\r\n\r\n\032\032stopped\r\n.*$gdb_prompt$" \
- { pass "watch triggered on a.x" }
+ { setup_kfail "gdb/38" "i686*-*-*"
+ pass "watch triggered on a.x" }
+ -re "\r\n\032\032post-prompt\r\n\r\n\032\032starting\r\n\r\n\032\032frames-invalid\r\n\r\n\032\032source .*$srcfile.*beg:$hex\r\n\r\n\032\032frame-end\r\n\r\n\032\032stopped\r\n$gdb_prompt$" \
+ { kfail "gdb/38" "watch triggered on a.x" }
-re ".*$gdb_prompt$" { fail "watch triggered on a.x" }
timeout { fail "watch triggered on a.x (timeout)" }
}