MLIR 24.0.0git
MemRefToLLVM.cpp File Reference

Go to the source code of this file.

Namespaces

namespace  mlir
 Include the generated interface declarations.

Macros

#define DEBUG_TYPE   "memref-to-llvm"
#define GEN_PASS_DEF_FINALIZEMEMREFTOLLVMCONVERSIONPASS

Functions

static LLVM::GEPNoWrapFlags getLoadStoreNoWrapFlags (MemRefType type)
 Returns GEP no-wrap flags for a memref load/store.

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "memref-to-llvm"

Definition at line 32 of file MemRefToLLVM.cpp.

◆ GEN_PASS_DEF_FINALIZEMEMREFTOLLVMCONVERSIONPASS

#define GEN_PASS_DEF_FINALIZEMEMREFTOLLVMCONVERSIONPASS

Definition at line 35 of file MemRefToLLVM.cpp.

Function Documentation

◆ getLoadStoreNoWrapFlags()

LLVM::GEPNoWrapFlags getLoadStoreNoWrapFlags ( MemRefType type)
static

Returns GEP no-wrap flags for a memref load/store.

inbounds is always valid when indices are in-bounds per the memref spec. nuw requires every index*stride term to not unsigned-wrap, which holds iff all strides are statically non-negative. Negative strides would make the intermediate mul nuw overflow (e.g., idx * (-1 as u64) wraps for idx > 0).

Definition at line 46 of file MemRefToLLVM.cpp.