This function is well-defined for an instruction that doesn't access memory (and thus trivially doesn't alias anything in the AST), so drop the assert. We can end up with a readnone call here if we originally created a MemoryDef for an indirect call, which was later replaced with a direct readnone call.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Ping
llvm/lib/Analysis/AliasSetTracker.cpp | ||
---|---|---|
237 | If desired, I could also just drop the check completely and let getModRefInfo do its thing. |
Comment Actions
LGTM, thanks! Handling instructions not accessing memory should be fine there and pushing the responsibility to remove MemmoryDefs that become non-defs to transforms making changes seems unnecessarily strict.
llvm/test/Transforms/LICM/pr51333.ll | ||
---|---|---|
24 | can this use opaque pointers? |
llvm/test/Transforms/LICM/pr51333.ll | ||
---|---|---|
24 | Yes, but this will need a (rustc) backport, so it's easier to keep typed pointers in the initial commit. |
If desired, I could also just drop the check completely and let getModRefInfo do its thing.