[PATCH] D120303: [SCEV] Do not erase LoopUsers. PR53969

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 22 00:11:36 PST 2022


nikic accepted this revision.
nikic added a comment.
This revision is now accepted and ready to land.

LGTM. It's a bit unfortunate that we conflate the notion of "forget this loop because we're about to delete it" and "forget this loop because we made a significant change to it", but as things are right now, I agree that dropping from LoopUsers is not correct here.

> The only real problem we can run into is following: if we
> delete a loop, and then create a new loop by the same address, this may cause cache confusion.
> However, this still should be safe because the *only* purpose of LoopUsers is invalidation, and
> invalidation never reads loops from AddRecs.

This can't happen, because Loop addresses are not reused.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D120303/new/

https://reviews.llvm.org/D120303



More information about the llvm-commits mailing list