[llvm-commits] CVS: llvm/lib/VMCore/Mangler.cpp

Chris Lattner lattner at cs.uiuc.edu
Mon Feb 13 13:43:38 PST 2006



Changes in directory llvm/lib/VMCore:

Mangler.cpp updated: 1.26 -> 1.27
---
Log message:

Another work around for the 'symbols with different types can have the same 
name' issue.


---
Diffs of the changes:  (+4 -0)

 Mangler.cpp |    4 ++++
 1 files changed, 4 insertions(+)


Index: llvm/lib/VMCore/Mangler.cpp
diff -u llvm/lib/VMCore/Mangler.cpp:1.26 llvm/lib/VMCore/Mangler.cpp:1.27
--- llvm/lib/VMCore/Mangler.cpp:1.26	Mon Nov 14 19:32:03 2005
+++ llvm/lib/VMCore/Mangler.cpp	Mon Feb 13 15:43:26 2006
@@ -161,6 +161,10 @@
     if (GV->hasExternalLinkage() && !ExistingValue->hasExternalLinkage()) {
       MangledGlobals.insert(ExistingValue);
       ExistingValue = GV;
+    } else if (GV->hasExternalLinkage() && ExistingValue->hasExternalLinkage()&&
+               GV->isExternal() && ExistingValue->isExternal()) {
+      // If the two globals both have external inkage, and are both external,
+      // don't mangle either of them, we just have some silly type mismatch.
     } else {
       // Otherwise, mangle GV
       MangledGlobals.insert(GV);






More information about the llvm-commits mailing list