From c105d2304c84c578137ac8e249f66c20a6b7e94b Mon Sep 17 00:00:00 2001 From: Michael Snyder Date: Fri, 5 May 2000 21:50:23 +0000 Subject: [PATCH] 2000-04-28 Michael Snyder * gdb.base/break.exp: When compiled with -O2 optimization, gdb may not stop at the first line of main, due to code motion. --- gdb/testsuite/ChangeLog | 5 +++++ gdb/testsuite/gdb.base/break.exp | 2 ++ 2 files changed, 7 insertions(+) diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 2d7aaf6afe..f49fa6b76b 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -4,6 +4,11 @@ Mon May 1 15:37:58 2000 Andrew Cagney * gdb.c++/templates.cc: Properly check for GCC version number. * lib/compiler.cc: Likewise +2000-04-28 Michael Snyder + + * gdb.base/break.exp: When compiled with -O2 optimization, + gdb may not stop at the first line of main, due to code motion. + 2000-04-26 Michael Snyder * gdb.base/call-ar-st.exp: Bail out if target is sparclet. diff --git a/gdb/testsuite/gdb.base/break.exp b/gdb/testsuite/gdb.base/break.exp index ce36c21bcc..aaad20a737 100644 --- a/gdb/testsuite/gdb.base/break.exp +++ b/gdb/testsuite/gdb.base/break.exp @@ -858,6 +858,8 @@ if ![target_info exists use_gdb_stub] { } -re "Starting program.*Breakpoint \[0-9\]+,.*main .*argc.*argv.* at .*$srcfile:75.*75\[\t \]+if .argc.* \{.*$gdb_prompt $"\ { pass "run until function breakpoint, optimized file" } + -re "Starting program.*Breakpoint \[0-9\]+,.*main .*argc.*argv.* at .*$gdb_prompt $"\ + { pass "run until function breakpoint, optimized file (code motion)" } -re ".*$gdb_prompt $" { fail "run until function breakpoint, optimized file" } timeout { fail "run until function breakpoint, optimized file (timeout)" } } -- 2.11.0