From ec688648779b9ce1e2e6fb737f569263cf463739 Mon Sep 17 00:00:00 2001 From: Bob Wilson Date: Tue, 22 Jun 2010 02:08:51 +0000 Subject: [PATCH] Revert my change to clone named metadata. Buildbots are complaining. --- Reverse-merging r106508 into '.': U lib/Transforms/Utils/CloneModule.cpp git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106521 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/Utils/CloneModule.cpp | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/lib/Transforms/Utils/CloneModule.cpp b/lib/Transforms/Utils/CloneModule.cpp index 1809bbb3201..b87c082793e 100644 --- a/lib/Transforms/Utils/CloneModule.cpp +++ b/lib/Transforms/Utils/CloneModule.cpp @@ -122,17 +122,6 @@ Module *llvm::CloneModule(const Module *M, if (const Constant* C = I->getAliasee()) GA->setAliasee(cast(MapValue(C, ValueMap))); } - - // And named metadata.... - for (Module::const_named_metadata_iterator I = M->named_metadata_begin(), - E = M->named_metadata_end(); I != E; ++I) { - const NamedMDNode &NMD = *I; - SmallVector MDs; - for (unsigned i = 0, e = NMD.getNumOperands(); i != e; ++i) - MDs.push_back(cast(MapValue(NMD.getOperand(i), ValueMap))); - NamedMDNode::Create(New->getContext(), NMD.getName(), - MDs.data(), MDs.size(), New); - } return New; }