[flang-commits] [flang] [flang] AliasAnalysis: More formally define and distinguish between data and non-data (PR #91020)
Joel E. Denny via flang-commits
flang-commits at lists.llvm.org
Wed May 15 09:29:15 PDT 2024
================
@@ -50,12 +47,84 @@ struct AliasAnalysis {
/// Attributes of the memory source object.
ENUM_CLASS(Attribute, Target, Pointer, IntentIn);
+ // See
+ // https://discourse.llvm.org/t/rfc-distinguish-between-data-and-non-data-in-fir-alias-analysis/78759/1
+ //
+ // It is possible, while following the source of a memory reference through
+ // the use-def chain, to arrive at the same origin, even though the starting
+ // points were known to not alias.
+ //
+ // clang-format off
+ // Example:
+ // ------------------- test.f90 --------------------
+ // module top
+ // real, pointer :: a(:)
+ // end module
+ //
+ // subroutine test()
+ // use top
+ // a(1) = 1
+ // -------------------------------------------------
----------------
jdenny-ornl wrote:
```suggestion
// a(1) = 1
// end subroutine
// -------------------------------------------------
```
https://github.com/llvm/llvm-project/pull/91020
More information about the flang-commits
mailing list