[llvm-commits] [Review request] clang bug 8355: generating wrong code due to incorrect name mangling

Eli Friedman eli.friedman at gmail.com
Tue Oct 19 11:29:48 PDT 2010


On Sun, Oct 17, 2010 at 6:12 AM, Richard Smith <richard at metafoo.co.uk> wrote:
> Hello,
>
> While porting a large C++ codebase to clang, I found a bug where incorrect
> code would be generated if two polymorphic classes with the same name were
> defined within a function -- specifically, the name mangling code didn't
> fall into the <local-name> case and gave the same mangled name for both
> vtables. This is filed as bug#8355.
>
> The attached patch corrects this behaviour. I've also changed the
> discriminator numbering for local classes to more closely match the
> Itanium C++ ABI and g++ -- the numbering is now incremented for each
> top-level type within a function, and not for each mangled local name.
>
> I'd appreciate any review comments you might have. Please CC me on any
> replies.

1) Please send clang patches to cfe-commits, not here.
2) In case you didn't spot it, see clang r116752
(http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20101018/035564.html).

-Eli



More information about the llvm-commits mailing list