f16 type support was missing in the math.erf op.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/lib/Dialect/Math/Transforms/PolynomialApproximation.cpp | ||
---|---|---|
173 | You could use FloatAttr Builder::getFloatAttr(Type type, double value) to avoid branching. | |
775 | If this check fails wouldn't it let someone else handle math.erf down the line. Isn't it desirable for example if you have also f64 that has to be calculated in some other manner? |
mlir/lib/Dialect/Math/Transforms/PolynomialApproximation.cpp | ||
---|---|---|
775 | Asserting is different. This will return a match failure, allowing others to handle the lowering. |
instead of assert notifiy match failure.
mlir/lib/Dialect/Math/Transforms/PolynomialApproximation.cpp | ||
---|---|---|
775 | Makes sense. |
This assert can be removed if you use Builder::getFloatAttr.