[LoopGuardWidening] Make PostDomTree optional
authorPhilip Reames <listmail@philipreames.com>
Fri, 27 Apr 2018 23:15:56 +0000 (23:15 +0000)
committerPhilip Reames <listmail@philipreames.com>
Fri, 27 Apr 2018 23:15:56 +0000 (23:15 +0000)
commit502d4481d48a93dd6c083e049cf675b7c2946e6d
tree37dc1506af950b507ea18357477ba8841439730f
parent1c0a0da62e6fc397d4c8e82932274ca05f7eccf8
[LoopGuardWidening] Make PostDomTree optional

The effect of doing so is not disrupting the LoopPassManager when mixing this pass with other loop passes.  This should help locality of access substaintially and avoids the cost of computing PostDom.

The assumption here is that the full GuardWidening (which does use PostDom) is run as a canonicalization before loop opts and that this version is just catching cases exposed by other loop passes.  (i.e. LoopPredication, IndVarSimplify, LoopUnswitch, etc..)

llvm-svn: 331094
llvm/lib/Transforms/Scalar/GuardWidening.cpp
llvm/test/Transforms/GuardWidening/loop-schedule.ll