MLIR 24.0.0git
MathToXeVM.cpp File Reference

Go to the source code of this file.

Classes

struct  ConvertNativeFuncPattern< Op >
 Convert math ops marked with fast (afn) to native OpenCL intrinsics. More...

Namespaces

namespace  mlir
 Include the generated interface declarations.

Macros

#define GEN_PASS_DEF_CONVERTMATHTOXEVM
#define DEBUG_TYPE   "math-to-xevm"

Functions

static bool isSizeOneVector (Type type)
static bool isSPIRVCompatibleFloatOrVec (Type type)
template<typename OpTy>
static void populateOCLExtSetOpPatterns (const LLVMTypeConverter &converter, RewritePatternSet &patterns, PatternBenefit benefit, StringRef opName)

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "math-to-xevm"

Definition at line 30 of file MathToXeVM.cpp.

◆ GEN_PASS_DEF_CONVERTMATHTOXEVM

#define GEN_PASS_DEF_CONVERTMATHTOXEVM

Definition at line 24 of file MathToXeVM.cpp.

Function Documentation

◆ isSizeOneVector()

bool isSizeOneVector ( Type type)
static

Definition at line 32 of file MathToXeVM.cpp.

Referenced by ConvertNativeFuncPattern< Op >::matchAndRewrite().

◆ isSPIRVCompatibleFloatOrVec()

bool isSPIRVCompatibleFloatOrVec ( Type type)
static

Definition at line 38 of file MathToXeVM.cpp.

References mlir::Type::isFloat().

Referenced by ConvertNativeFuncPattern< Op >::matchAndRewrite().

◆ populateOCLExtSetOpPatterns()

template<typename OpTy>
void populateOCLExtSetOpPatterns ( const LLVMTypeConverter & converter,
RewritePatternSet & patterns,
PatternBenefit benefit,
StringRef opName )
static