[llvm] r290683 - [NewGVN] Simplyfy loop NFC
Piotr Padlewski via llvm-commits
llvm-commits at lists.llvm.org
Wed Dec 28 11:42:50 PST 2016
Author: prazek
Date: Wed Dec 28 13:42:49 2016
New Revision: 290683
URL: http://llvm.org/viewvc/llvm-project?rev=290683&view=rev
Log:
[NewGVN] Simplyfy loop NFC
Modified:
llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp?rev=290683&r1=290682&r2=290683&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/NewGVN.cpp Wed Dec 28 13:42:49 2016
@@ -1915,10 +1915,7 @@ bool NewGVN::eliminateInstructions(Funct
// Cleanup the congruence class.
SmallPtrSet<Value *, 4> MembersLeft;
- for (auto MI = CC->Members.begin(), ME = CC->Members.end(); MI != ME;) {
- auto CurrIter = MI;
- ++MI;
- Value *Member = *CurrIter;
+ for (Value * Member : CC->Members) {
if (Member->getType()->isVoidTy()) {
MembersLeft.insert(Member);
continue;
More information about the llvm-commits
mailing list