[PATCH] D112295: [SCEV][NFC] API for tracking of SCEV users

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 22 01:22:29 PDT 2021


nikic added inline comments.


================
Comment at: llvm/lib/Analysis/ScalarEvolution.cpp:13397
+  for (auto *Op : Ops)
+    SCEVUsers[Op].insert(User);
+}
----------------
Something we might want to consider is to not track users of SCEVConstant. I believe this is where things are moving in IR (dropping use lists for ConstantData) and we might want to avoid repeating that mistake from the start.

I don't think it's possible for a SCEVConstant to ever become invalid (as they are just integers -- constant expressions are SCEVUnknown), so not having SCEVConstant users should not present an issue for invalidation purposes.


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

https://reviews.llvm.org/D112295



More information about the llvm-commits mailing list