MLIR
20.0.0git
|
This class provides all of the information necessary to convert a type signature. More...
#include "mlir/Transforms/DialectConversion.h"
Classes | |
struct | InputMapping |
This struct represents a range of new types or a single value that remaps an existing signature input. More... | |
Public Member Functions | |
SignatureConversion (unsigned numOrigInputs) | |
ArrayRef< Type > | getConvertedTypes () const |
Return the argument types for the new signature. More... | |
std::optional< InputMapping > | getInputMapping (unsigned input) const |
Get the input mapping for the given argument. More... | |
void | addInputs (unsigned origInputNo, ArrayRef< Type > types) |
Remap an input of the original signature with a new set of types. More... | |
void | addInputs (ArrayRef< Type > types) |
Append new input types to the signature conversion, this should only be used if the new types are not intended to remap an existing input. More... | |
void | remapInput (unsigned origInputNo, Value replacement) |
Remap an input of the original signature to another replacement value. More... | |
This class provides all of the information necessary to convert a type signature.
Definition at line 63 of file DialectConversion.h.
|
inline |
Definition at line 65 of file DialectConversion.h.
Append new input types to the signature conversion, this should only be used if the new types are not intended to remap an existing input.
Definition at line 2702 of file DialectConversion.cpp.
Remap an input of the original signature with a new set of types.
The new types are appended to the new signature conversion.
Definition at line 2695 of file DialectConversion.cpp.
References remapInput().
Referenced by mlir::TypeConverter::convertSignatureArg(), and lowerAsEntryFunction().
Return the argument types for the new signature.
Definition at line 76 of file DialectConversion.h.
Referenced by mlir::detail::ConversionPatternRewriterImpl::applySignatureConversion(), convertFuncOpTypes(), and lowerAsEntryFunction().
|
inline |
Get the input mapping for the given argument.
Definition at line 79 of file DialectConversion.h.
Referenced by mlir::detail::ConversionPatternRewriterImpl::applySignatureConversion(), mlir::convertFuncOpToLLVMFuncOp(), and mlir::GPUFuncOpLowering::matchAndRewrite().
void TypeConverter::SignatureConversion::remapInput | ( | unsigned | origInputNo, |
Value | replacement | ||
) |
Remap an input of the original signature to another replacement
value.
This drops the original argument.
Definition at line 2717 of file DialectConversion.cpp.
Referenced by addInputs(), and mlir::GPUFuncOpLowering::matchAndRewrite().