1//===- MemRefDescriptor.h - MemRef descriptor constants ---------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// Defines constants that are used in LLVM dialect equivalents of MemRef type.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef MLIR_LIB_CONVERSION_LLVMCOMMON_MEMREFDESCRIPTOR_H
14#define MLIR_LIB_CONVERSION_LLVMCOMMON_MEMREFDESCRIPTOR_H
15
16static constexpr unsigned kAllocatedPtrPosInMemRefDescriptor = 0;
17static constexpr unsigned kAlignedPtrPosInMemRefDescriptor = 1;
18static constexpr unsigned kOffsetPosInMemRefDescriptor = 2;
19static constexpr unsigned kSizePosInMemRefDescriptor = 3;
20static constexpr unsigned kStridePosInMemRefDescriptor = 4;
21
22static constexpr unsigned kRankInUnrankedMemRefDescriptor = 0;
23static constexpr unsigned kPtrInUnrankedMemRefDescriptor = 1;
24
25#endif // MLIR_LIB_CONVERSION_LLVMCOMMON_MEMREFDESCRIPTOR_H
26

source code of mlir/lib/Conversion/LLVMCommon/MemRefDescriptor.h