[llvm] r281939 - Misleading comments of SplitBlockAndInsertIfThenElse in BasicBlockUtils.h
Evgeniy Stepanov via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 19 14:26:05 PDT 2016
Author: eugenis
Date: Mon Sep 19 16:26:05 2016
New Revision: 281939
URL: http://llvm.org/viewvc/llvm-project?rev=281939&view=rev
Log:
Misleading comments of SplitBlockAndInsertIfThenElse in BasicBlockUtils.h
The comments of SplitBlockAndInsertIfThenElse say the SplitBefore instruction will stay in the old block.
But according to the implementation(split the block at SplitBefore by using splitBasicBlock), the SplitBefore will be moved to the new block.
This patch fixes the comments.
Patch by Zhe Yu Wu.
Modified:
llvm/trunk/include/llvm/Transforms/Utils/BasicBlockUtils.h
Modified: llvm/trunk/include/llvm/Transforms/Utils/BasicBlockUtils.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Transforms/Utils/BasicBlockUtils.h?rev=281939&r1=281938&r2=281939&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Transforms/Utils/BasicBlockUtils.h (original)
+++ llvm/trunk/include/llvm/Transforms/Utils/BasicBlockUtils.h Mon Sep 19 16:26:05 2016
@@ -230,8 +230,8 @@ ReturnInst *FoldReturnIntoUncondBranch(R
BasicBlock *Pred);
/// Split the containing block at the specified instruction - everything before
-/// and including SplitBefore stays in the old basic block, and everything after
-/// SplitBefore is moved to a new block. The two blocks are connected by a
+/// SplitBefore stays in the old basic block, and the rest of the instructions
+/// in the BB are moved to a new block. The two blocks are connected by a
/// conditional branch (with value of Cmp being the condition).
/// Before:
/// Head
More information about the llvm-commits
mailing list