[Mlir-commits] [flang] [mlir] [RFC][mlir] ViewLikeOpInterface method for detecting partial views. (PR #164020)
Tom Eccles
llvmlistbot at llvm.org
Fri Oct 24 02:51:44 PDT 2025
================
@@ -212,6 +212,10 @@ AliasResult AliasAnalysis::alias(Source lhsSrc, Source rhsSrc, mlir::Value lhs,
if (lhsSrc.origin == rhsSrc.origin) {
LLVM_DEBUG(llvm::dbgs()
<< " aliasing because same source kind and origin\n");
+ // TODO: we should return PartialAlias here. Need to decide
+ // if returning PartialAlias for fir.pack_array is okay;
+ // if not, then we need to handle it specially to still return
+ // MayAlias.
----------------
tblah wrote:
Thinking about it some more, I think local alias analysis should at least return MayAlias. As I understand it, the distinction between `MayAlias` and `PartialAlias` is that a `MayAlias` result invites further analysis by other methods whereas `PartialAlias` is considered a definate "these accesses are proven to overlap" and so does not need further analysis if other alias analysis implementations are available.
https://github.com/llvm/llvm-project/pull/164020
More information about the Mlir-commits
mailing list