FLANG
FIRMemRefOpsInterfaces.cpp File Reference
#include "flang/Optimizer/Dialect/FIRDialect.h"
#include "flang/Optimizer/Dialect/FortranVariableInterface.h"
#include "mlir/Dialect/MemRef/IR/MemRef.h"
#include "mlir/Dialect/Utils/StaticValueUtils.h"
#include "mlir/IR/DialectRegistry.h"
#include "mlir/Interfaces/ViewLikeInterface.h"
#include <optional>

Detailed Description

External models of FortranObjectViewOpInterface for memref casts, so that FIR alias analysis can look through them. fir-to-memref creates memref.reinterpret_cast, and canonicalization can also introduce memref.cast.

We assume the result stays within the object of the source, as we do elsewhere in FIR alias analysis.