diff options
author | Michael Chastain <mec@google.com> | 2003-02-03 16:07:31 +0000 |
---|---|---|
committer | Michael Chastain <mec@google.com> | 2003-02-03 16:07:31 +0000 |
commit | 9ba61c5d3ad064fdd1f430c3f4639bc88c6bab21 (patch) | |
tree | 84210db2d8eacb909726e982edb2a376dfcf458f /gdb | |
parent | 2d188dd3bb022fdf108c2decc1ecb338165a708d (diff) | |
download | gdb-9ba61c5d3ad064fdd1f430c3f4639bc88c6bab21.zip gdb-9ba61c5d3ad064fdd1f430c3f4639bc88c6bab21.tar.gz gdb-9ba61c5d3ad064fdd1f430c3f4639bc88c6bab21.tar.bz2 |
2003-02-01 Michael Chastain <mec@shout.net>
* gdb.base/advance.c (marker1): New marker function.
* gdb.base/advance.exp: When the 'advance' command lands on the
return breakpoint, it can legitimately stop on either the
current line or the next line. Accommodate both outcomes.
* gdb.base/until.exp: Likewise.
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/testsuite/ChangeLog | 8 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/advance.c | 5 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/advance.exp | 6 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/until.exp | 2 |
4 files changed, 19 insertions, 2 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 82f3843..5c5ee5b 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2003-02-01 Michael Chastain <mec@shout.net> + + * gdb.base/advance.c (marker1): New marker function. + * gdb.base/advance.exp: When the 'advance' command lands on the + return breakpoint, it can legitimately stop on either the + current line or the next line. Accommodate both outcomes. + * gdb.base/until.exp: Likewise. + 2003-02-02 Andrew Cagney <ac131313@redhat.com> 2002-11-10 Jason Molenda (jason-cl@molenda.com): diff --git a/gdb/testsuite/gdb.base/advance.c b/gdb/testsuite/gdb.base/advance.c index 2ae3cc5..8066dee 100644 --- a/gdb/testsuite/gdb.base/advance.c +++ b/gdb/testsuite/gdb.base/advance.c @@ -29,6 +29,10 @@ int func3 () x = 4; } +void marker1 () +{ +} + int main () { @@ -38,6 +42,7 @@ main () b = 3; /* advance this location */ func (c); /* stop here after leaving current frame */ + marker1 (); /* stop here after leaving current frame */ func3 (); /* break here */ result = bar (b + foo (c)); return 0; /* advance malformed */ diff --git a/gdb/testsuite/gdb.base/advance.exp b/gdb/testsuite/gdb.base/advance.exp index aea5a6d..e5061d8 100644 --- a/gdb/testsuite/gdb.base/advance.exp +++ b/gdb/testsuite/gdb.base/advance.exp @@ -63,8 +63,12 @@ gdb_test "advance func" \ # Verify that "advance <funcname>" when funcname is NOT called by the current # frame, stops at the end of the current frame. # +# gdb can legitimately stop on either the current line or the next line, +# depending on whether the machine instruction for 'call' on the current +# line has more instructions after it or not. +# gdb_test "advance func3" \ - "in main.*func \\(c\\).*stop here after leaving current frame..."\ + "(in main|).*(func \\(c\\)|marker1 \\(\\)).*stop here after leaving current frame..."\ "advance function not called by current frame" # break at main again diff --git a/gdb/testsuite/gdb.base/until.exp b/gdb/testsuite/gdb.base/until.exp index 8159332..f646c6d 100644 --- a/gdb/testsuite/gdb.base/until.exp +++ b/gdb/testsuite/gdb.base/until.exp @@ -76,6 +76,6 @@ delete_breakpoints # stop at main, the caller, where we put the 'guard' breakpoint. # gdb_test "until marker3" \ - "$hex in main.*argc.*argv.*envp.*at.*${srcfile}:82.*marker2 \\(43\\)." \ + "($hex in |)main.*argc.*argv.*envp.*at.*${srcfile}:(82.*marker2 \\(43\\)|83.*marker3 \\(.stack., .trace.\\))." \ "until func, not called by current frame" |