[LLVMdev] How to deal with potentially unlimited count/length symbol names?

Eli Friedman eli.friedman at gmail.com
Wed Jun 19 10:49:35 PDT 2013


On Wed, Jun 19, 2013 at 10:35 AM, edA-qa mort-ora-y <eda-qa at disemia.com>wrote:

> On 19/06/13 19:23, Eli Friedman wrote:
> > I think you've covered all the possible implementations.
> >
> > In terms of just generating long names, LLVM and common platforms can
> > handle long names reasonably well because C++ often uses such names.
> >  Also, the Itanium C++ ABI has a scheme to compress repeated uses of the
> > same type which might be of interest; see
> > http://mentorembedded.github.io/cxx-abi/abi.html#mangling-compression .
> >
> > In terms of a registry, you might want to consider whether these helpers
> > actually need to be exposed across libraries.
>
> Annoyingly, the larger the type the more important it is to share -- for
> small types everything will just be inlined so it doesn't matter.
>
> Any idea on what the limit of a name can be? I'll try a compression like
> system as well, but I will likely have to truncate at some point (where
> I can add a hash).
>

IIRC, there isn't any absolute limit.  You'll probably run into performance
issues if your symbols get beyond a few kilobytes, though.

-Eli
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130619/b5769f65/attachment.html>


More information about the llvm-dev mailing list