Check that we're using SCEV for the same loop we're simulating. Otherwise, we might try to use the iteration number of the current loop in SCEV expressions for inner/outer loops IVs, which is clearly incorrect.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
lgtm
I don't know this area of code well, but this change looks fairly simple and obvious
Comment Actions
Thanks! It looks like the newlines are actually necessary, so I returned them in the committed patch.
Michael
Nit: why not change this to if (!AR || AR->getLoop() != L)?