llvm.org GIT mirror llvm / 4e34d50
- Add the LinkerPrivateWeakDefAutoLinkage to the Ada bindings. - Support the LinkerWeak*Linkage types in llvm-nm and in LinkModules.cpp. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111952 91177308-0d34-0410-b5e6-96231b3b80d8 Bill Wendling 10 years ago
3 changed file(s) with 30 addition(s) and 19 deletion(s). Raw diff Collapse all Expand all
316316 LLVMGhostLinkage,
317317 LLVMCommonLinkage,
318318 LLVMLinkerPrivateLinkage,
319 LLVMLinkerPrivateWeakLinkage);
319 LLVMLinkerPrivateWeakLinkage,
320 LinkerPrivateWeakDefAutoLinkage);
320321
321322 for LLVMLinkage use
322 (LLVMExternalLinkage => 0,
323 LLVMAvailableExternallyLinkage => 1,
324 LLVMLinkOnceAnyLinkage => 2,
325 LLVMLinkOnceODRLinkage => 3,
326 LLVMWeakAnyLinkage => 4,
327 LLVMWeakODRLinkage => 5,
328 LLVMAppendingLinkage => 6,
329 LLVMInternalLinkage => 7,
330 LLVMPrivateLinkage => 8,
331 LLVMDLLImportLinkage => 9,
332 LLVMDLLExportLinkage => 10,
333 LLVMExternalWeakLinkage => 11,
334 LLVMGhostLinkage => 12,
335 LLVMCommonLinkage => 13,
336 LLVMLinkerPrivateLinkage => 14,
337 LLVMLinkerPrivateWeakLinkage => 15);
323 (LLVMExternalLinkage => 0,
324 LLVMAvailableExternallyLinkage => 1,
325 LLVMLinkOnceAnyLinkage => 2,
326 LLVMLinkOnceODRLinkage => 3,
327 LLVMWeakAnyLinkage => 4,
328 LLVMWeakODRLinkage => 5,
329 LLVMAppendingLinkage => 6,
330 LLVMInternalLinkage => 7,
331 LLVMPrivateLinkage => 8,
332 LLVMDLLImportLinkage => 9,
333 LLVMDLLExportLinkage => 10,
334 LLVMExternalWeakLinkage => 11,
335 LLVMGhostLinkage => 12,
336 LLVMCommonLinkage => 13,
337 LLVMLinkerPrivateLinkage => 14,
338 LLVMLinkerPrivateWeakLinkage => 15,
339 LinkerPrivateWeakDefAutoLinkage => 16);
338340
339341 pragma Convention (C, LLVMLinkage);
340342
642642 else if (SL == GlobalValue::LinkerPrivateLinkage &&
643643 DL == GlobalValue::LinkerPrivateLinkage)
644644 return GlobalValue::LinkerPrivateLinkage;
645 else if (SL == GlobalValue::LinkerPrivateWeakLinkage &&
646 DL == GlobalValue::LinkerPrivateWeakLinkage)
647 return GlobalValue::LinkerPrivateWeakLinkage;
648 else if (SL == GlobalValue::LinkerPrivateWeakDefAutoLinkage &&
649 DL == GlobalValue::LinkerPrivateWeakDefAutoLinkage)
650 return GlobalValue::LinkerPrivateWeakDefAutoLinkage;
645651 else {
646652 assert (SL == GlobalValue::PrivateLinkage &&
647653 DL == GlobalValue::PrivateLinkage && "Unexpected linkage type");
8787
8888 static void DumpSymbolNameForGlobalValue(GlobalValue &GV) {
8989 // Private linkage and available_externally linkage don't exist in symtab.
90 if (GV.hasPrivateLinkage() || GV.hasLinkerPrivateLinkage() ||
91 GV.hasLinkerPrivateWeakLinkage() || GV.hasAvailableExternallyLinkage())
90 if (GV.hasPrivateLinkage() ||
91 GV.hasLinkerPrivateLinkage() ||
92 GV.hasLinkerPrivateWeakLinkage() ||
93 GV.hasLinkerPrivateWeakDefAutoLinkage() ||
94 GV.hasAvailableExternallyLinkage())
9295 return;
9396
9497 const std::string SymbolAddrStr = " "; // Not used yet...