From 7302344bdf2b107001364a37e3d48787af521fc3 Mon Sep 17 00:00:00 2001 From: Alexander Kornienko Date: Wed, 20 Sep 2017 14:52:56 +0000 Subject: [PATCH] Revert r313753: "Fix a -Wsign-compare warning in LoopAccessAnalysis.cpp" llvm-svn: 313757 --- llvm/lib/Analysis/LoopAccessAnalysis.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/llvm/lib/Analysis/LoopAccessAnalysis.cpp b/llvm/lib/Analysis/LoopAccessAnalysis.cpp index 3b23b3314b9f..efc3bc950b36 100644 --- a/llvm/lib/Analysis/LoopAccessAnalysis.cpp +++ b/llvm/lib/Analysis/LoopAccessAnalysis.cpp @@ -1143,8 +1143,7 @@ bool llvm::sortLoadAccesses(ArrayRef VL, const DataLayout &DL, // The pointers may not have a constant offset from each other, or SCEV // may just not be smart enough to figure out they do. Regardless, // there's nothing we can do. - if (!Diff || Diff->getAPInt().abs().getSExtValue() > - static_cast((VL.size() - 1) * Size)) + if (!Diff || Diff->getAPInt().abs().getSExtValue() > (VL.size() - 1) * Size) return false; OffValPairs.emplace_back(Diff->getAPInt().getSExtValue(), Val);