[patch] Drop support for mangling unnamed globals

Chris Lattner clattner at apple.com
Wed Feb 5 10:53:05 PST 2014


I generally like removing old dead code, but I'm nervous about this one.    This is really redefining what is valid IR.  How about you start by adding an assert that the name is not null, see if anyone complains over the course of a couple of weeks, and if noone does, then take it out.

If/when this goes in, this will need a release note and update to LangRef.

-Chris

On Feb 5, 2014, at 10:30 AM, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote:

> Ping.
> 
> A rebased patch is attached.
> 
> On 8 January 2014 15:13, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote:
>> HI Chris,
>> 
>> This feature apparently exists to make it easier for frontends to
>> create auxiliary functions and variables without worrying about their
>> names. It has quiet a bit of history, I tried to find when it was
>> introduced, but it is older than the current mangler. It already
>> existed back when % and @ were one :-)
>> 
>> Given that LLVM will rename a global if the name is already used, it
>> is easy for a frontend to create auxiliary globals that are already
>> unique at the llvm level, so the mangler/codegen features seems a bit
>> redundant.
>> 
>> This is not a critical patch, just a possible cleanup I noticed when
>> moving the Mangler. It does remove a DenseMap, making the Mangler a
>> bit lighter.
>> 
>> Cheers,
>> Rafael
> <t.patch>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140205/10fe3a6a/attachment.html>


More information about the llvm-commits mailing list