[Mlir-commits] [mlir] [mlir][sparse] infer returned type for sparse_tensor.to_[buffer] ops (PR #83343)
Yinying Li
llvmlistbot at llvm.org
Wed Feb 28 14:53:24 PST 2024
================
@@ -257,9 +257,10 @@ def SparseTensor_ReinterpretMapOp : SparseTensor_Op<"reinterpret_map", [NoMemory
let hasVerifier = 1;
}
-def SparseTensor_ToPositionsOp : SparseTensor_Op<"positions", [Pure]>,
+def SparseTensor_ToPositionsOp : SparseTensor_Op<"positions",
+ [Pure, DeclareOpInterfaceMethods<InferTypeOpInterface>]>,
Arguments<(ins AnySparseTensor:$tensor, LevelAttr:$level)>,
- Results<(outs AnyStridedMemRefOfRank<1>:$result)> {
+ Results<(outs AnyNon0RankedMemRef:$result)> {
----------------
yinying-lisa-li wrote:
is the 0 intended to be in the name? if so, can we use zero instead of 0?
https://github.com/llvm/llvm-project/pull/83343
More information about the Mlir-commits
mailing list