C++: Add support for -fno-use-cxa-atexit.

- So much typing, so little gain...

Also, rename the __cxx_global_initialization function just to match llvm-gcc.

llvm-svn: 99039
This commit is contained in:
Daniel Dunbar
2010-03-20 04:15:41 +00:00
parent 7572284f4f
commit fe06df4bf3
12 changed files with 140 additions and 28 deletions

View File

@@ -81,6 +81,7 @@ void CodeGenModule::createObjCRuntime() {
void CodeGenModule::Release() {
EmitDeferred();
EmitCXXGlobalInitFunc();
EmitCXXGlobalDtorFunc();
if (Runtime)
if (llvm::Function *ObjCInitFunction = Runtime->ModuleInitFunction())
AddGlobalCtor(ObjCInitFunction);