This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 0/6] Convert gimple to a C++ class hierarchy
- From: Richard Biener <richard dot guenther at gmail dot com>
- To: Diego Novillo <dnovillo at google dot com>,Jakub Jelinek <jakub at redhat dot com>
- Cc: Michael Matz <matz at suse dot de>,Gabriel Dos Reis <gdr at integrable-solutions dot net>,David Malcolm <dmalcolm at redhat dot com>,"gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Sat, 31 Aug 2013 11:57:03 +0200
- Subject: Re: [PATCH 0/6] Convert gimple to a C++ class hierarchy
- Authentication-results: sourceware.org; auth=none
- References: <1377793216-22549-1-git-send-email-dmalcolm at redhat dot com> <alpine dot LNX dot 2 dot 00 dot 1308301532490 dot 9949 at wotan dot suse dot de> <CAAiZkiB-Z7GfDGNuWys+d6JW+ynbtfC_Yc5YHfN9M-to5uABXg at mail dot gmail dot com> <20130830140253 dot GO21876 at tucnak dot zalov dot cz> <CAAiZkiB=iJ7dwFEe7OKhMBXccMsu6950fE6Cy=h-a6JF0h=FTA at mail dot gmail dot com> <alpine dot LNX dot 2 dot 00 dot 1308301712450 dot 9949 at wotan dot suse dot de> <CAD_=9DRK4htu8jefZehb0Q4JDCozbCA2pr0Sq6rhX4JcW7QEDw at mail dot gmail dot com> <20130830153727 dot GQ21876 at tucnak dot zalov dot cz> <CAD_=9DRki+6uidqeKJ_=hU0u=hc6s-55XUDqr-qyhAp-kvxGjw at mail dot gmail dot com>
Diego Novillo <dnovillo@google.com> wrote:
>On Fri, Aug 30, 2013 at 11:37 AM, Jakub Jelinek <jakub@redhat.com>
>wrote:
>
>> Teaching the gengtype parser about
>> {struct,class} name : public {struct,class} someothername { ... }
>> as opposed to current
>> {struct,class} name { ... }
>> shouldn't be that hard. And, if the complaint is that we'd need to
>write
>> whole C++ parser for it, then the response could be that we already
>have
>> one C++ parser (and, even have plugin support and/or emit dwarf
>etc.).
>
>It isn't. It's annoying and a duplication of effort.
>
>> So, gengtype could very well use a g++ plugin to emit the stuff it
>needs,
>> or parse DWARF, etc. And, we even could not require everybody
>actually
>> emitting those themselves, we could check some text form of that
>> (gengtype.state?) into the tree, so only people actually changing the
>> compiler would need to run the plugin.
>
>Yes. Lawrence and I thought about moving gengtype inside g++. That
>seemed like a promising approach.
What do you do during stage1? Have a collector that never collects?
Richard.
>> Even if you have some stuff that helps you writing those, still it
>will be a
>> big source of bugs (very hard to debug) and a maintainance nightmare.
>
>Debugging gengtype is much harder. It is magic code that is not
>visible.
>
>
>Diego.