[llvm] r209015 - Add comdat key field to llvm.global_ctors and llvm.global_dtors

Reid Kleckner rnk at google.com
Wed Jun 4 17:34:12 PDT 2014


On Wed, Jun 4, 2014 at 5:27 PM, Rafael EspĂ­ndola <rafael.espindola at gmail.com
> wrote:
>
> > Yes.  Also, this completely breaks the intended design of the comdat key
> in
> > global ctors, because now it needs to support an arbitrary symbol and
> not a
> > specific GV.  Maybe we can find a way to replace this with an explicit
> > section which will have the comdat, but I'll have to think of that later.
>
> Sure, it can definitely wait for us having comdat support in the IR :-)
>

Actually, I take this statement back.  We can still use the global variable
as the comdat key.  If the GV has a section with an explicit comdat group,
we can grab that group and use it for the initializer too.  Otherwise, we
keep using the implicit group created for linkonce_odr / weak_odr data.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140604/dcf430b5/attachment.html>


More information about the llvm-commits mailing list