[GCC-XML] internal error with 0.9.0
Steve Vinoski
vinoski at ieee.org
Thu Feb 14 13:47:37 EST 2008
On 2/14/08, Brad King <brad.king at kitware.com> wrote:
> Steve Vinoski wrote:
> > Right, debugging gccxml_cc1plus instead of gccxml let me hit the
> > breakpoint, but I didn't get very far after that. I'm not very
> > familiar with the innards of gcc, so debugging it is not easy.
> >
> > But given that g++ 4.2 doesn't have any issues with that code, I
> > thought maybe I could look through recent gcc patches to find the fix.
> > I looked through a number of patches and also through the gcc sources
> > a fair bit, but so far, no luck.
>
> I found the problem. It is in fact a bug in GCC 4.2's mangle.c but it
> is exposed only by GCC-XML's call to it. Somehow mangle.c reaches a
> case where it assumes that an enumeration value will be a simple integer
> expression when in your example it is a less-than-comparison expression.
Well, at least I was looking at the right place -- mangle.c seemed to
be the culprit, but I couldn't narrow it down from there due to my
ignorance of the compiler internals. :-)
> I've committed a hack to work around the issue:
>
> /cvsroot/GCC_XML/gccxml/GCC/gcc/cp/mangle.c,v <-- mangle.c
> new revision: 1.3; previous revision: 1.2
I picked that up and verified that it works. Thanks!
--steve
More information about the gccxml
mailing list