Fix PR9815: I was trying to get out of "generating code and then
authorChris Lattner <sabre@nondot.org>
Sun, 22 May 2011 17:39:56 +0000 (17:39 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 22 May 2011 17:39:56 +0000 (17:39 +0000)
commit4f81b5419295cfc26a1349d6c23a55c6d2a683e1
treeb3b8121012a48cca6bc1350a04794771da37ec5d
parent5649ba70fb39f2fda4791d255ae8bb373071874f
Fix PR9815: I was trying to get out of "generating code and then
failing to form a memset, then having to delete it" but my approximation
isn't safe for self recurrent loops.  Instead of doign a hack, just
do it the right way.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131858 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/LoopIdiomRecognize.cpp
test/Transforms/LoopIdiom/basic.ll