testsuite: Fix gdb.gdb/selftest.exp for C++-O2-g-built GDB
authorJan Kratochvil <jan.kratochvil@redhat.com>
Wed, 20 Jul 2016 14:26:44 +0000 (16:26 +0200)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Wed, 20 Jul 2016 14:26:44 +0000 (16:26 +0200)
tested on Fedora 24 x86_64 after:
        ./configure; make
That is: CFLAGS='-g -O2' CXXFLAGS='-g -O2'

FAIL: gdb.gdb/selftest.exp: unknown source line
FAIL: gdb.gdb/selftest.exp: step into xmalloc call

gdb/testsuite/ChangeLog
2016-07-20  Jan Kratochvil  <jan.kratochvil@redhat.com>

* gdb.gdb/selftest.exp (do_steps_and_nexts): Add "next over TRY" and
"step into captured_main (args)".

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.gdb/selftest.exp

index 3a1bdfd08260f59dad92f58ca729edc29a4afd64..e7d935e0608939549357cfaec9f174dd49e56008 100644 (file)
@@ -1,3 +1,8 @@
+2016-07-20  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+       * gdb.gdb/selftest.exp (do_steps_and_nexts): Add "next over TRY" and
+       "step into captured_main (args)".
+
 2016-07-20  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        * gdb.btrace/tailcall-only.exp: Use is_lp64_target check.
index 809045ae0d47aa8c9ae1eddea5020ec2fcb0bd7c..2fdd9e3539fae673553c4729ef0f11953858d6f3 100644 (file)
@@ -111,6 +111,14 @@ proc do_steps_and_nexts {} {
                set description "next over lim_at_start initialization"
                set command "next"
            }
+           -re ".*TRY.*$gdb_prompt $" {
+               set description "next over TRY"
+               set command "next"
+           }
+           -re ".*captured_main \\(args\\);.*$gdb_prompt $" {
+               set description "step into captured_main (args)"
+               set command "step"
+           }
            -re ".*count . 0x3.*$gdb_prompt $" {
                set description "next over conditional stack alignment code 1"
                set command "next"