Auto-upgrade the magic ".llvm.eh.catch.all.value" global to

"llvm.eh.catch.all.value". Only the name needs to be changed.

llvm-svn: 113600
This commit is contained in:
Bill Wendling
2010-09-10 18:51:56 +00:00
parent 0996003126
commit e26fffc597
5 changed files with 28 additions and 0 deletions

View File

@@ -1288,6 +1288,12 @@ bool BitcodeReader::ParseModule() {
UpgradedIntrinsics.push_back(std::make_pair(FI, NewFn));
}
// Look for global variables which need to be renamed.
for (Module::global_iterator
GI = TheModule->global_begin(), GE = TheModule->global_end();
GI != GE; ++GI)
UpgradeGlobalVariable(GI);
// Force deallocation of memory for these vectors to favor the client that
// want lazy deserialization.
std::vector<std::pair<GlobalVariable*, unsigned> >().swap(GlobalInits);