diff options
author | Owen Anderson <resistor@mac.com> | 2008-04-13 19:15:17 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2008-04-13 19:15:17 +0000 |
commit | 386ea355e730a1e92acf84e7a3f2ad95c3d6165b (patch) | |
tree | db0f8b4f971bfe783a270cd59caa66856dba6fa1 /lib/Transforms/Scalar/TailDuplication.cpp | |
parent | 4a6da60787fcc66c521288fbd139cf8afdca5957 (diff) |
Replace calls of the form V1->setName(V2->getName()) with V1->takeName(V2),
which is significantly more efficient.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49614 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Scalar/TailDuplication.cpp')
-rw-r--r-- | lib/Transforms/Scalar/TailDuplication.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/TailDuplication.cpp b/lib/Transforms/Scalar/TailDuplication.cpp index 929d113745..5d802a6e7a 100644 --- a/lib/Transforms/Scalar/TailDuplication.cpp +++ b/lib/Transforms/Scalar/TailDuplication.cpp @@ -317,7 +317,7 @@ void TailDup::eliminateUnconditionalBranch(BranchInst *Branch) { // for (; BI != DestBlock->end(); ++BI) { Instruction *New = BI->clone(); - New->setName(BI->getName()); + New->takeName(BI); SourceBlock->getInstList().push_back(New); ValueMapping[BI] = New; } |