From: Chris Lattner Date: Thu, 18 Nov 2010 07:39:57 +0000 (+0000) Subject: remove another pointless noalias check: M is a memcpy, so the X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=12f7085027657957e08aea597b5c9fed44052969;p=oota-llvm.git remove another pointless noalias check: M is a memcpy, so the source and dest are known to not overlap. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119692 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Transforms/Scalar/MemCpyOptimizer.cpp b/lib/Transforms/Scalar/MemCpyOptimizer.cpp index cab8bac0f94..ea29fca346a 100644 --- a/lib/Transforms/Scalar/MemCpyOptimizer.cpp +++ b/lib/Transforms/Scalar/MemCpyOptimizer.cpp @@ -691,8 +691,7 @@ bool MemCpyOpt::processMemCpyMemCpyDependence(MemCpyInst *M, MemCpyInst *MDep, // Finally, we have to make sure that the dest of the second does not // alias the source of the first. AliasAnalysis &AA = getAnalysis(); - if (!AA.isNoAlias(M->getRawDest(), MSize, MDep->getRawSource(), DepSize) || - !AA.isNoAlias(M->getRawDest(), MSize, M->getRawSource(), MSize)) + if (!AA.isNoAlias(M->getRawDest(), MSize, MDep->getRawSource(), DepSize)) return false; // If all checks passed, then we can transform these memcpy's