bit from the original function to the cloned one.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61194
91177308-0d34-0410-b5e6-
96231b3b80d8
GlobalValue::InternalLinkage,
oldFunction->getName() + "_" +
header->getName(), M);
+ // If the old function is no-throw, so is the new one.
+ if (oldFunction->doesNotThrow())
+ newFunction->setDoesNotThrow(true);
+
newFunction->getBasicBlockList().push_back(newRootNode);
// Create an iterator to name all of the arguments we inserted.