Skip to content
Commit b3d48a60 authored by Nicolas Vasilache's avatar Nicolas Vasilache
Browse files

[mlir][Memref] Introduce a memref::ExtractAlignedPointerAsIndexOp

As experience with memref::ExtractStridedMetadataOp grows we are
still missing a simple way to extract the pointer held by a memref
and lower to different backednds (LLVM, SPIRV, library calls).

This revision introduces a memref.extract_aligned_pointer_as_index that
returns an index containing the aligned pointer of the strided memref.

This operation is intended to be used solely as step during lowering,
it has no side effects. A reverse operation that creates a memref from
an index interpreted as a pointer is explicitly discouraged.

Differential Revision: https://reviews.llvm.org/D134651
parent aac6629f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment