[PATCH] D31444: LTO: call getRealLinkageName on IRNames before feeding to getGUID

Mehdi AMINI via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 29 11:54:00 PDT 2017


mehdi_amini added a comment.

In https://reviews.llvm.org/D31444#713402, @rnk wrote:

> In https://reviews.llvm.org/D31444#712724, @pcc wrote:
>
> > So maybe we should have just one static function:
> >
> >   static GUID getGUID(StringRef Name, GlobalValue::LinkageTypes Linkage, StringRef FileName);
> >
> > That should hopefully make the API harder to misuse.
>


+1 as well.

> This would remove the need for the MachO-specific underscore removal hack in `computeGUIDPreservedSymbols`, which looks like it's trying to map from object file names back to IR names.

Yes that's what it does.

> That code is probably broken on Windows.

Luckily this component is not used on Windows :)
(it is only part of libLTO)
And I'd really like to deprecate and kill this!


https://reviews.llvm.org/D31444





More information about the llvm-commits mailing list