[llvm] [polly] [AST] Don't merge memory locations in AliasSetTracker (PR #65731)
Bruno De Fraine via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 19 01:43:38 PST 2023
================
@@ -3238,8 +3238,10 @@ ScopBuilder::buildAliasGroupsForAccesses() {
if (AS.isMustAlias() || AS.isForwardingAliasSet())
continue;
AliasGroupTy AG;
- for (auto &PR : AS)
- AG.push_back(PtrToAcc[PR.getValue()]);
+ llvm::SmallPtrSet<const Value *, 8> Seen;
+ for (auto &MemLoc : AS)
+ if (Seen.insert(MemLoc.Ptr).second)
+ AG.push_back(PtrToAcc[const_cast<Value *>(MemLoc.Ptr)]);
----------------
brunodf-snps wrote:
Done.
https://github.com/llvm/llvm-project/pull/65731
More information about the llvm-commits
mailing list