[Mlir-commits] [mlir] [MLIR][ROCDL] Convert `math::fpowi` to ROCDL call (PR #122640)
Jakub Kuderski
llvmlistbot at llvm.org
Sun Jan 12 10:05:25 PST 2025
================
@@ -58,7 +59,8 @@ struct OpToFuncCallLowering : public ConvertOpToLLVMPattern<SourceOp> {
"expected single result op");
static_assert(std::is_base_of<OpTrait::SameOperandsAndResultType<SourceOp>,
- SourceOp>::value,
+ SourceOp>::value ||
+ std::is_same_v<SourceOp, math::FPowIOp>,
----------------
kuhar wrote:
This feels like a hack. Are there some other things we could check instead? Maybe turn this into a runtime assertion and check that the first operand and have the same type, or add a hook for getting the element types with a default for `SameOperandsAndResultType`?
https://github.com/llvm/llvm-project/pull/122640
More information about the Mlir-commits
mailing list