This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR89779


On Thu, 21 Mar 2019, Richard Biener wrote:

> 
> The testcase in this PR shows that IVOPTs ends up using cached
> control IV information of IVs that have been elimiated by it.
> IVOPTs fails to properly release that information as scev_reset
> just resets ->nb_iterations but not control-IVs.
> 
> A proper fix is to avoid doing the above for each loop and instead
> delay IV def removal until IVOPTs has finished and there ensure
> also possibly invalidated control-IVs are released.
> 
> Bootstrap & regtest running on x86_64-unknown-linux-gnu.
> 
> IMHO this is the proper fix, I'll test and install also a patch
> restoring defensive checks that avoided the ICE before.
> 
> Slightly safe might be to prune control-IVs where we do
> scev_reset () now instead of delaying DEF removal.  I'm only 99%
> sure IVOPTs, when processing outer loops, is not affected by
> the dead IVs being still in the IL (all uses are already updated
> but feeding defs are not elimiated either).
> 
> Bin?

Applied as rev. 269914.

Richard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]