remove mangler support for mangling local names. Mangler should only be

used with globals.

llvm-svn: 75557
This commit is contained in:
Chris Lattner 2009-07-13 23:47:27 +00:00
parent 2a0ba70c02
commit 4ea397f845
2 changed files with 0 additions and 15 deletions

View File

@ -89,7 +89,6 @@ public:
/// in the current module.
///
std::string getValueName(const GlobalValue *V, const char *Suffix = "");
std::string getValueName(const Value *V);
/// makeNameProper - We don't want identifier names with ., space, or
/// - in them, so we mangle these characters into the strings "d_",

View File

@ -136,20 +136,6 @@ unsigned Mangler::getTypeID(const Type *Ty) {
return E;
}
std::string Mangler::getValueName(const Value *V) {
if (const GlobalValue *GV = dyn_cast<GlobalValue>(V))
return getValueName(GV);
std::string &Name = Memo[V];
if (!Name.empty())
return Name; // Return the already-computed name for V.
// Always mangle local names.
Name = "ltmp_" + utostr(Count++) + "_" + utostr(getTypeID(V->getType()));
return Name;
}
std::string Mangler::getValueName(const GlobalValue *GV, const char *Suffix) {
// Check to see whether we've already named V.
std::string &Name = Memo[GV];