[PATCH] D106185: [Attributor] Introduce getPotentialCopiesOfStoredValue and use it
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 16 17:48:54 PDT 2021
jdoerfert added inline comments.
================
Comment at: llvm/lib/Transforms/IPO/AttributorAttributes.cpp:3085-3090
const auto &ReachabilityAA = A.getAAFor<AAReachability>(
*this, IRPosition::function(*ScopeFn), DepClassTy::OPTIONAL);
if (!ReachabilityAA.isAssumedReachable(A, *UserI, *getCtxI()))
return true;
----------------
kuter wrote:
> From what I can see `checkForAllUses` can now return uses from different functions.
> I am worried about some code not handling this case correctly.
>
> For example, do you think this piece of code can cause a problem ?
Assuming `AAReachability` would handle interprocedural queries right (it will assert now) this would be fine.
That said, I find the UserI check above very suspect and I can not remember why this is supposed to be valid without following the user at least.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D106185/new/
https://reviews.llvm.org/D106185
More information about the llvm-commits
mailing list