Apply clang-tidy fixes for readability-simplify-boolean-expr in TosaToLinalg.cpp...
authorMehdi Amini <joker.eph@gmail.com>
Sun, 12 Jun 2022 17:09:09 +0000 (17:09 +0000)
committerMehdi Amini <joker.eph@gmail.com>
Tue, 28 Jun 2022 11:21:43 +0000 (11:21 +0000)
mlir/lib/Conversion/TosaToLinalg/TosaToLinalg.cpp

index 133a3631b7d5aa6a5c22b97ee7b7188120eea0a4..5711ffe003f4774910830aae042e2317b1889806 100644 (file)
@@ -944,7 +944,7 @@ static bool createReassociationMapsForCollapse(
 
   // If both iterators didn't reach the end, we have leftover dimentions which
   // implies that we have a mismatch in shape.
-  return !(currSrcDim != srcShape.size() || currDstDim != dstShape.size());
+  return currSrcDim == srcShape.size() && currDstDim == dstShape.size();
 }
 
 namespace {