[PATCH] D94926: [LoopInfo] Fix a typo in compareLoops
Kazu Hirata via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 18 11:55:45 PST 2021
kazu created this revision.
kazu added reviewers: fhahn, efriedma.
kazu requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
The code here is checking to see if two sets are identical.
OtherBlocksSet should point to OtherL->getBlocksSet() instead.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D94926
Files:
llvm/include/llvm/Analysis/LoopInfoImpl.h
Index: llvm/include/llvm/Analysis/LoopInfoImpl.h
===================================================================
--- llvm/include/llvm/Analysis/LoopInfoImpl.h
+++ llvm/include/llvm/Analysis/LoopInfoImpl.h
@@ -673,7 +673,8 @@
"Mismatched basic blocks in the loops!");
const SmallPtrSetImpl<const BlockT *> &BlocksSet = L->getBlocksSet();
- const SmallPtrSetImpl<const BlockT *> &OtherBlocksSet = L->getBlocksSet();
+ const SmallPtrSetImpl<const BlockT *> &OtherBlocksSet =
+ OtherL->getBlocksSet();
assert(BlocksSet.size() == OtherBlocksSet.size() &&
llvm::all_of(BlocksSet,
[&OtherBlocksSet](const BlockT *BB) {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D94926.317400.patch
Type: text/x-patch
Size: 674 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210118/9b5df6d9/attachment.bin>
More information about the llvm-commits
mailing list