[PATCH] D20083: Add an c++ itanium demangler to llvm

Rafael Espíndola via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 24 11:20:19 PDT 2016


We need a demangler in llvm, and that requires annoying tradeoffs:

* llvm depends on libc++abi.
* libc++abi depends on llvm.
* both llvm and libc++abi dependent on a libdemangle.
* we keep a file in both repositories.
* we have two independent implementations.

The first 3 introduce annoying dependencies. The last one means the llvm
demangler can have a nice interface (stringref), but duplicates a lot of
code.

Having a file that is copied in both repositories is the least horrible
option IMHO. Having said that, any solution where lld on windows can
demangle itanium  names would work for us.

Cheers,
Rafael

On Aug 24, 2016 1:16 PM, "Mehdi Amini" <mehdi.amini at apple.com> wrote:

>
> > On Aug 24, 2016, at 9:56 AM, Craig, Ben <ben.craig at codeaurora.org>
> wrote:
> >
> > On 8/24/2016 11:31 AM, Rafael Espíndola wrote:
> >>> 1. I think there are already too many build time dependencies crossing
> the compiler / runtime boundary.  I'm tired of my libcxx and libcxxabi
> builds failing because of unrelated cmake changes in LLVM.  To avoid that,
> I could build a standalone version... but now that won't be easily possible
> because of this change.
> >> Not sure I follow. Note that this function is in an independent
> >> library with no dependencies.
> >>
> >>> Building libcxx and libcxxabi shouldn't require me to pull down llvm
> sources, or to have a "dev" install of llvm, and this change makes that
> problem even worse than it already is.  Will this even work for the cross
> compilation cases?
> >> This should not change this case at all. This just adds a file to llvm
> >> itself. In a future change I will add a ifdef to it so that it can
> >> also be used with no changes in libcxxabi.
> > I guess I'm protesting the future change, rather than this change.
> libc++abi should not use source files, header files, static libraries, or
> shared objects that come from the llvm repository.
>
> That's bothering: it means that any functionality has to be reimplemented
> (can’t use simple StringRef or Twine helper, which is annoying when doing
> string processing like here).
>
>> Mehdi
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160824/86a2d2f8/attachment.html>


More information about the llvm-commits mailing list