diff options
author | Chris Lattner <sabre@nondot.org> | 2009-07-17 23:57:13 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-07-17 23:57:13 +0000 |
commit | f56501ce48255765414dc57220e6aadf2bd3837c (patch) | |
tree | 63bceede4ae0f1462815837282cc3b766edc5055 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | e1019db65836e2dd1cd9521435e21be5deeaeaa2 (diff) | |
download | bcm5719-llvm-f56501ce48255765414dc57220e6aadf2bd3837c.tar.gz bcm5719-llvm-f56501ce48255765414dc57220e6aadf2bd3837c.zip |
fix objc codegen to not have its own list of things that eventually get into llvm.used, just
populate CGM's list directly.
llvm-svn: 76266
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index d502d79d294..20fbbd2f2ee 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -415,9 +415,7 @@ void CodeGenModule::AddUsedGlobal(llvm::GlobalValue *GV) { void CodeGenModule::EmitLLVMUsed() { // Don't create llvm.used if there is no need. - // FIXME. Runtime indicates that there might be more 'used' symbols; but not - // necessariy. So, this test is not accurate for emptiness. - if (LLVMUsed.empty() && !Runtime) + if (LLVMUsed.empty()) return; llvm::Type *i8PTy = VMContext.getPointerTypeUnqual(llvm::Type::Int8Ty); @@ -431,8 +429,6 @@ void CodeGenModule::EmitLLVMUsed() { i8PTy); } - if (Runtime) - Runtime->MergeMetadataGlobals(UsedArray); if (UsedArray.empty()) return; llvm::ArrayType *ATy = VMContext.getArrayType(i8PTy, UsedArray.size()); |