[llvm] b71eed7 - [ConstraintElimination] Remove redundant lookup (NFC).
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 9 10:00:23 PST 2022
Author: Florian Hahn
Date: 2022-02-09T18:00:03Z
New Revision: b71eed7e8fdebfdbd127a5b31ba5ed8086f2238d
URL: https://github.com/llvm/llvm-project/commit/b71eed7e8fdebfdbd127a5b31ba5ed8086f2238d
DIFF: https://github.com/llvm/llvm-project/commit/b71eed7e8fdebfdbd127a5b31ba5ed8086f2238d.diff
LOG: [ConstraintElimination] Remove redundant lookup (NFC).
Added:
Modified:
llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp b/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
index 27a275ed59dc..09e455d8d280 100644
--- a/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
+++ b/llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
@@ -303,9 +303,6 @@ getConstraint(CmpInst::Predicate Pred, Value *Op0, Value *Op1,
auto V2I = Value2Index.find(V);
if (V2I != Value2Index.end())
return V2I->second;
- auto NewI = NewIndices.find(V);
- if (NewI != NewIndices.end())
- return NewI->second;
auto Insert =
NewIndices.insert({V, Value2Index.size() + NewIndices.size() + 1});
return Insert.first->second;
More information about the llvm-commits
mailing list