Use MCSymbols for FastISel.

The summary is that it moves the mangling earlier and replaces a few
calls to .addExternalSymbol with addSym.

I originally wanted to replace all the uses of addExternalSymbol with
addSym, but noticed it was a lot of work and doesn't need to be done
all at once.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240395 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Rafael Espindola
2015-06-23 12:21:54 +00:00
parent b7f5b8b4b2
commit b9ed9af341
12 changed files with 96 additions and 41 deletions

View File

@@ -51,6 +51,10 @@ public:
/// Print the appropriate prefix and the specified global variable's name.
/// If the global variable doesn't have a name, this fills in a unique name
/// for the global.
static void getNameWithPrefix(SmallVectorImpl<char> &OutName,
const Twine &GVName, const DataLayout &DL);
void getNameWithPrefix(raw_ostream &OS, const GlobalValue *GV,
bool CannotUsePrivateLabel) const;
void getNameWithPrefix(SmallVectorImpl<char> &OutName, const GlobalValue *GV,