* [expr] [patch] testsuite: Fix gdb.cp/exception.exp false regression
@ 2010-01-27 20:34 Jan Kratochvil
2010-01-28 19:45 ` Jan Kratochvil
0 siblings, 1 reply; 4+ messages in thread
From: Jan Kratochvil @ 2010-01-27 20:34 UTC (permalink / raw)
To: archer
Hi,
patch fixes
-FAIL: gdb.cp/exception.exp: backtrace after first throw
+PASS: gdb.cp/exception.exp: backtrace after first throw
-FAIL: gdb.cp/exception.exp: backtrace after first catch
+PASS: gdb.cp/exception.exp: backtrace after first catch
-FAIL: gdb.cp/exception.exp: backtrace after second throw
+PASS: gdb.cp/exception.exp: backtrace after second throw
-FAIL: gdb.cp/exception.exp: backtrace after second catch
+PASS: gdb.cp/exception.exp: backtrace after second catch
caused by the branch changing:
-#0 __cxa_throw (obj=<value optimized out>, tinfo=<value optimized out>, dest=<value optimized out>) at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:70
+#0 __cxxabiv1::__cxa_throw (obj=<value optimized out>, tinfo=<value optimized out>, dest=<value optimized out>) at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:70
Tested on x86_64-fedora12-linux-gnu.
OK to check-in?
Thanks,
Jan
2010-01-27 Jan Kratochvil <jan.kratochvil@redhat.com>
* gdb.cp/exception.exp (nws): New.
(backtrace after first throw, backtrace after second throw): Require
a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Require
a namespace before __cxa_begin_catch.
--- a/gdb/testsuite/gdb.cp/exception.exp
+++ b/gdb/testsuite/gdb.cp/exception.exp
@@ -32,6 +32,7 @@
# Replace them with gdb_get_line_number.
set ws "\[\r\n\t \]+"
+set nws "\[^\r\n\t \]+"
set nl "\[\r\n\]+"
if $tracelevel then {
@@ -146,7 +147,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after first throw"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_throw.*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+${ws}($hex in |)${nws}::__cxa_throw.*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
@@ -168,7 +169,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after first catch"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_begin_catch.*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+${ws}($hex in |)${nws}::__cxa_begin_catch.*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
@@ -190,7 +191,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after second throw"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_throw.*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+${ws}($hex in |)${nws}::__cxa_throw.*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
@@ -212,7 +213,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after second catch"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_begin_catch.*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+${ws}($hex in |)${nws}::__cxa_begin_catch.*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [expr] [patch] testsuite: Fix gdb.cp/exception.exp false regression
2010-01-27 20:34 [expr] [patch] testsuite: Fix gdb.cp/exception.exp false regression Jan Kratochvil
@ 2010-01-28 19:45 ` Jan Kratochvil
2010-01-28 21:00 ` Keith Seitz
0 siblings, 1 reply; 4+ messages in thread
From: Jan Kratochvil @ 2010-01-28 19:45 UTC (permalink / raw)
To: archer; +Cc: Keith Seitz
Hi,
patch fixes
-FAIL: gdb.cp/exception.exp: backtrace after first throw
+PASS: gdb.cp/exception.exp: backtrace after first throw
-FAIL: gdb.cp/exception.exp: backtrace after first catch
+PASS: gdb.cp/exception.exp: backtrace after first catch
-FAIL: gdb.cp/exception.exp: backtrace after second throw
+PASS: gdb.cp/exception.exp: backtrace after second throw
-FAIL: gdb.cp/exception.exp: backtrace after second catch
+PASS: gdb.cp/exception.exp: backtrace after second catch
caused by the branch changing:
-#0 __cxa_throw (obj=<value optimized out>, tinfo=<value optimized out>, dest=<value optimized out>) at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:70
+#0 __cxxabiv1::__cxa_throw (obj=<value optimized out>, tinfo=<value optimized out>, dest=<value optimized out>) at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:70
The previous patch had a regression if you did not have gcc-debuginfo
(-> libstdc++ .debug) installed as in such case GDB still prints:
#0 0x00000035722b8570 in __cxa_throw () from /usr/lib64/libstdc++.so.6^M
Tested on x86_64-fedora12-linux-gnu.
OK to check-in?
Thanks,
Jan
2010-01-28 Jan Kratochvil <jan.kratochvil@redhat.com>
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
--- a/gdb/testsuite/gdb.cp/exception.exp
+++ b/gdb/testsuite/gdb.cp/exception.exp
@@ -146,7 +146,9 @@ gdb_test_multiple "continue" $name {
set name "backtrace after first throw"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_throw.*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+.*\[\[:<:\]\]__cxa_throw\[\[:>:\]\].*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
+ # Either __cxxabiv1::__cxa_throw or __cxa_throw can be printed
+ # depending on debug info presence.
pass $name
}
}
@@ -168,7 +170,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after first catch"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_begin_catch.*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+.*\[\[:<:\]\]__cxa_begin_catch\[\[:>:\]\].*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
@@ -190,7 +192,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after second throw"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_throw.*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+.*\[\[:<:\]\]__cxa_throw\[\[:>:\]\].*#\[0-9\]+${ws}$hex in foo \\(i=20\\) at .*${srcfile}:\[0-9\]+\r\n#\[0-9\]+${ws}$hex in main \\(.*\\) at .*${srcfile}:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
@@ -212,7 +214,7 @@ gdb_test_multiple "continue" $name {
set name "backtrace after second catch"
gdb_test_multiple "backtrace" $name {
- -re ".*#\[0-9\]+${ws}($hex in |)__cxa_begin_catch.*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
+ -re ".*#\[0-9\]+.*\[\[:<:\]\]__cxa_begin_catch\[\[:>:\]\].*#\[0-9\]+${ws}$hex in main \\(.*\\) at .*$srcfile:\[0-9\]+\r\n$gdb_prompt $" {
pass $name
}
}
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [expr] [patch] testsuite: Fix gdb.cp/exception.exp false regression
2010-01-28 19:45 ` Jan Kratochvil
@ 2010-01-28 21:00 ` Keith Seitz
2010-01-28 21:09 ` Jan Kratochvil
0 siblings, 1 reply; 4+ messages in thread
From: Keith Seitz @ 2010-01-28 21:00 UTC (permalink / raw)
To: Jan Kratochvil; +Cc: archer
On 01/28/2010 11:45 AM, Jan Kratochvil wrote:
> Hi,
>
> patch fixes
>
> -FAIL: gdb.cp/exception.exp: backtrace after first throw
> +PASS: gdb.cp/exception.exp: backtrace after first throw
> -FAIL: gdb.cp/exception.exp: backtrace after first catch
> +PASS: gdb.cp/exception.exp: backtrace after first catch
> -FAIL: gdb.cp/exception.exp: backtrace after second throw
> +PASS: gdb.cp/exception.exp: backtrace after second throw
> -FAIL: gdb.cp/exception.exp: backtrace after second catch
> +PASS: gdb.cp/exception.exp: backtrace after second catch
>
> caused by the branch changing:
>
> -#0 __cxa_throw (obj=<value optimized out>, tinfo=<value optimized out>, dest=<value optimized out>) at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:70
> +#0 __cxxabiv1::__cxa_throw (obj=<value optimized out>, tinfo=<value optimized out>, dest=<value optimized out>) at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:70
Okay, that one works for me, too. Please commit. I will be including
this as part of my dwarf2_physname patch upstream.
Thanks!
Keith
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [expr] [patch] testsuite: Fix gdb.cp/exception.exp false regression
2010-01-28 21:00 ` Keith Seitz
@ 2010-01-28 21:09 ` Jan Kratochvil
0 siblings, 0 replies; 4+ messages in thread
From: Jan Kratochvil @ 2010-01-28 21:09 UTC (permalink / raw)
To: Keith Seitz; +Cc: archer
On Thu, 28 Jan 2010 22:00:33 +0100, Keith Seitz wrote:
> Okay, that one works for me, too. Please commit. I will be including
> this as part of my dwarf2_physname patch upstream.
Checked-in:
1bbc591325a56cddf65f8943f578d901e07b854d
Thanks,
Jan
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-01-28 21:09 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-27 20:34 [expr] [patch] testsuite: Fix gdb.cp/exception.exp false regression Jan Kratochvil
2010-01-28 19:45 ` Jan Kratochvil
2010-01-28 21:00 ` Keith Seitz
2010-01-28 21:09 ` Jan Kratochvil
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).