[polly] independent blocks: when moving values, invalidate SCEV cached info

Sebastian Pop spop at codeaurora.org
Fri May 3 10:52:21 PDT 2013


Tobias Grosser wrote:
> On 05/02/2013 10:57 PM, Sebastian Pop wrote:
> >Hi,
> >
> >IndependentBlocks::moveOperandTree already calls SE->forgetValue() in exactly
> >one case, however there are other cases where it does not call forgetValue
> >leading to crashes due to cached SCEVs that refer to values that no longer
> >exist.  The attached patch adds more calls to forgetValue whenever a value is
> >moved (and so renamed) to the new code generated for the scop.
> 
> Hi Sebastian,
> 
> I understand that we may need to forget more values in the
> IndependentBlocks pass, but I am currently still wondering if moving
> a value always invalidates its SCEV. 

It is not the scev of the value that we move that should change: it is all the
other scevs using the value we are moving that have to be recomputed in function
of code that will remain after removing the original scop. 

Sebastian
-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
hosted by The Linux Foundation



More information about the llvm-commits mailing list