This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Add guality [p]type test.
- From: Tom Tromey <tromey at redhat dot com>
- To: Mark Wielaard <mjw at redhat dot com>
- Cc: Jakub Jelinek <jakub at redhat dot com>, gcc-patches at gcc dot gnu dot org, Jason Merrill <jason at redhat dot com>, Cary Coutant <ccoutant at google dot com>, Alexandre Oliva <aoliva at redhat dot com>
- Date: Thu, 03 Jul 2014 13:43:26 -0600
- Subject: Re: [PATCH] Add guality [p]type test.
- Authentication-results: sourceware.org; auth=none
- References: <1403265071 dot 6147 dot 5 dot camel at bordewijk dot wildebeest dot org> <1404381209-11280-1-git-send-email-mjw at redhat dot com> <20140703100516 dot GC31640 at tucnak dot redhat dot com> <1404386141 dot 3766 dot 52 dot camel at bordewijk dot wildebeest dot org>
>> Is what gdb prints for ptype stable across different gdb versions (except
>> for whitespace that you canonicalize)? If yes, this looks good to me.
Mark> Yes, I believe it is (I tested against gdb git master and gdb 7.6.50).
Mark> It tries to print the expression as a canonical C type, so it should be
Mark> stable. GDB itself contains similar tests, but for pregenerated .S files
Mark> or synthetic generated DWARF. This just extends it to make sure gcc and
Mark> gdb agree on the produced/consumed debuginfo.
I think it should be reasonably reliable.
Something like this (but for value-printing) is already done in the
libstdc++ test suite.
Tom