This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH, c++ testsuite] Fix a few failures in gdb.cp/virtfunc.exp
- From: Luis Machado <lgustavo at codesourcery dot com>
- To: Tom Tromey <tromey at redhat dot com>
- Cc: "'gdb-patches at sourceware dot org'" <gdb-patches at sourceware dot org>
- Date: Tue, 04 Jun 2013 10:53:00 +0200
- Subject: Re: [PATCH, c++ testsuite] Fix a few failures in gdb.cp/virtfunc.exp
- References: <51AC8CA2 dot 3030008 at codesourcery dot com> <87vc5vmamh dot fsf at fleche dot redhat dot com>
- Reply-to: lgustavo at codesourcery dot com
On 06/03/2013 06:17 PM, Tom Tromey wrote:
"Luis" == Luis Machado <lgustavo@codesourcery.com> writes:
Luis> 2013-06-03 Luis Machado <lgustavo@codesourcery.com>
Luis> * gdb.cp/virtfunc.exp (make_one_vtable_result): Handle extra output
Luis> from targets that use function descriptors in the virtual tables.
Ok. Thanks for looking at this.
Before checking in the patch, i figured out the rest of the problems.
Newer GDB's seem to have fixed a problem with displaying thunks in the
virtual tables. Older ones did not demangle those names properly.
With that said, ppc64 uses dot symbols for those thunks, so we need to
account for those in the testcase as well.
Here's the updated patch. I escaped dot once (\.) instead of twice. So
hopefully this is the correct way. I often get confused with escaping in
dejagnu.
With this fix, i see only a single failure for virtfunc.exp on ppc64.
The other failure is more involved and i'm still chasing the root cause.
Luis
2013-06-04 Luis Machado <lgustavo@codesourcery.com>
* gdb.cp/virtfunc.exp (make_one_vtable_result): Handle extra output
from targets that use function descriptors in the virtual tables.
Handle presence of dot symbols.
diff --git a/gdb/testsuite/gdb.cp/virtfunc.exp b/gdb/testsuite/gdb.cp/virtfunc.exp
index 2509cc7..1c2268a 100644
--- a/gdb/testsuite/gdb.cp/virtfunc.exp
+++ b/gdb/testsuite/gdb.cp/virtfunc.exp
@@ -234,7 +234,7 @@ proc make_one_vtable_result {name args} {
set result "vtable for '${name}' @ $hex .subobject @ $hex.:$nls"
set count 0
foreach func $args {
- append result ".${count}.: $hex <$func..>${nls}"
+ append result ".${count}.:( @$hex:)? $hex <(\.)?$func..>${nls}"
incr count
}