mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Fix PR2929 by making bugpoint/code extract propagate the nothrow
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
This commit is contained in:
parent
65ee1e6ff4
commit
31535f1f04
@ -283,6 +283,10 @@ Function *CodeExtractor::constructFunction(const Values &inputs,
|
||||
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.
|
||||
|
Loading…
Reference in New Issue
Block a user