Added arith::FastMathAttr and ArithFastMathInterface support for Math dialect floating point operations. This change-set creates ArithCommon conversion utils that currently provide classes and methods to aid with arith::FastMathAttr conversion into LLVM::FastmathFlags. These utils are used in ArithToLLVM and MathToLLVM convertors, but may eventually be used by other converters that need to convert fast math attributes. Since Math dialect operations use arith::FastMathAttr, MathOps.td now has to include enum and attributes definitions from Arith dialect. To minimize the amount of TD code included from Arith dialect, I moved FastMathAttr definition into ArithBase.td. Differential Revision: https://reviews.llvm.org/D136312
21 lines
351 B
CMake
21 lines
351 B
CMake
add_mlir_conversion_library(MLIRMathToLLVM
|
|
MathToLLVM.cpp
|
|
|
|
ADDITIONAL_HEADER_DIRS
|
|
${MLIR_MAIN_INCLUDE_DIR}/mlir/Conversion/MathToLLVM
|
|
|
|
DEPENDS
|
|
MLIRConversionPassIncGen
|
|
|
|
LINK_COMPONENTS
|
|
Core
|
|
|
|
LINK_LIBS PUBLIC
|
|
MLIRArithAttrToLLVMConversion
|
|
MLIRLLVMCommonConversion
|
|
MLIRLLVMDialect
|
|
MLIRMathDialect
|
|
MLIRPass
|
|
MLIRTransforms
|
|
)
|