MLIR
20.0.0git
|
Options to control the LLVM lowering. More...
#include "mlir/Conversion/LLVMCommon/LoweringOptions.h"
Public Types | |
enum class | AllocLowering { Malloc , AlignedAlloc , None } |
Public Member Functions | |
LowerToLLVMOptions (MLIRContext *ctx) | |
LowerToLLVMOptions (MLIRContext *ctx, const DataLayout &dl) | |
void | overrideIndexBitwidth (unsigned bitwidth) |
Set the index bitwidth to the given value. More... | |
unsigned | getIndexBitwidth () const |
Get the index bitwidth. More... | |
Public Attributes | |
bool | useBarePtrCallConv = false |
AllocLowering | allocLowering = AllocLowering::Malloc |
bool | useGenericFunctions = false |
llvm::DataLayout | dataLayout = llvm::DataLayout("") |
The data layout of the module to produce. More... | |
Options to control the LLVM lowering.
The struct is used to share lowering options between passes, patterns, and type converter.
Definition at line 30 of file LoweringOptions.h.
|
strong |
Definition at line 37 of file LoweringOptions.h.
|
explicit |
Definition at line 15 of file LoweringOptions.cpp.
mlir::LowerToLLVMOptions::LowerToLLVMOptions | ( | MLIRContext * | ctx, |
const DataLayout & | dl | ||
) |
Definition at line 18 of file LoweringOptions.cpp.
References mlir::get(), and mlir::DataLayout::getTypeSizeInBits().
|
inline |
Get the index bitwidth.
Definition at line 66 of file LoweringOptions.h.
Referenced by mlir::LLVMTypeConverter::getIndexTypeBitwidth().
|
inline |
Set the index bitwidth to the given value.
Definition at line 59 of file LoweringOptions.h.
References mlir::kDeriveIndexBitwidthFromDataLayout.
AllocLowering mlir::LowerToLLVMOptions::allocLowering = AllocLowering::Malloc |
Definition at line 49 of file LoweringOptions.h.
Referenced by mlir::populateFinalizeMemRefToLLVMConversionPatterns().
llvm::DataLayout mlir::LowerToLLVMOptions::dataLayout = llvm::DataLayout("") |
The data layout of the module to produce.
This must be consistent with the data layout used in the upper levels of the lowering pipeline.
Definition at line 56 of file LoweringOptions.h.
Referenced by mlir::LLVMTypeConverter::getDataLayout(), and mlir::LLVMTypeConverter::getPointerBitwidth().
bool mlir::LowerToLLVMOptions::useBarePtrCallConv = false |
Definition at line 35 of file LoweringOptions.h.
Referenced by mlir::GPUReturnOpLowering::matchAndRewrite(), mlir::LLVMTypeConverter::packFunctionResults(), mlir::LLVMTypeConverter::promoteOperands(), and shouldUseBarePtrCallConv().
bool mlir::LowerToLLVMOptions::useGenericFunctions = false |
Definition at line 51 of file LoweringOptions.h.