]> granicus.if.org Git - clang/commit
Add a separate llvm.global_ctors entry for linkonce_odr data initializers
authorReid Kleckner <reid@kleckner.net>
Thu, 22 Aug 2013 20:07:45 +0000 (20:07 +0000)
committerReid Kleckner <reid@kleckner.net>
Thu, 22 Aug 2013 20:07:45 +0000 (20:07 +0000)
commitb969e84ec398fde1bb6255a05babdc23e2841101
treed482565f09e28f0427d249bcee8e59e2d69e2171
parent0bd62ade260c8fa72dbc8060fc7ce4502d22f5af
Add a separate llvm.global_ctors entry for linkonce_odr data initializers

Summary:
These typically come from static data members of class template
specializations.  This accomplishes two things:

1. May expose GlobalOpt optimizations for Itanium C++ ABI code.
2. Works toward fixing double initialization in the Microsoft C++ ABI.

CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1475

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189051 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGDeclCXX.cpp
test/CodeGenCXX/microsoft-abi-static-initializers.cpp
test/CodeGenCXX/static-member-variable-explicit-specialization.cpp