|
|
| ENUM_CLASS (SourceKind, Allocate, Global, Argument, HostAssoc, Indirect, Unknown) |
| | Kind of the memory source referenced by a value.
|
|
| ENUM_CLASS (Attribute, Target, Pointer, IntentIn, CrayPointer, CrayPointee) |
| | Attributes of the memory source object.
|
|
mlir::AliasResult | alias (Source lhsSrc, Source rhsSrc, mlir::Value lhs, mlir::Value rhs) |
| | Given the values and their sources, return their aliasing behavior.
|
|
mlir::AliasResult | alias (mlir::Value lhs, mlir::Value rhs) |
| | Given two values, return their aliasing behavior.
|
|
mlir::ModRefResult | getModRef (mlir::Operation *op, mlir::Value location) |
| | Return the modify-reference behavior of op on location.
|
| mlir::ModRefResult | getModRef (mlir::Region ®ion, mlir::Value location) |
| fir::AliasAnalysis::Source | getSource (mlir::Value, bool getLastInstantiationPoint=false, bool collectScopedOrigins=true) |
| void | enableSourceCache () |
|
void | disableSourceCache () |
| | Disable getSource() memoization and drop any cached entries.
|
|
std::size_t | getSourceCacheSizeForTesting () const |
| | Testing only: number of entries currently held in the getSource() cache.
|
|
std::size_t | getSourceCacheHitsForTesting () const |
| | Testing only: cumulative getSource() cache hits / misses on this instance.
|
|
std::size_t | getSourceCacheMissesForTesting () const |
| bool | functionHasMultipleScopes (mlir::Value v) |
| AliasAnalysis::Source fir::AliasAnalysis::getSource |
( |
mlir::Value | v, |
|
|
bool | getLastInstantiationPoint = false, |
|
|
bool | collectScopedOrigins = true ) |
Return the memory source of a value. If getLastInstantiationPoint is true, the search for the source will stop at [hl]fir.declare if it represents a dummy argument declaration (i.e. it has the dummy_scope operand). If collectScopedOrigins is false, the per-declare ScopedOrigin snapshots are not collected, and getSource performs only the SourceKind/origin classification without that bookkeeping side effect.
When source caching is enabled (see enableSourceCache()), the result is memoized keyed on (value, flags), and recursive sub-queries share the same cache. The cache is a frozen snapshot with no automatic invalidation: it is only valid while the IR reachable from the queried values is not mutated in a way that would change the source. It lives no longer than this AliasAnalysis instance, so a client enables caching only for a region in which it does not perform such mutations (e.g. a pass that only moves operations).