[Mlir-commits] [mlir] [mlir][sparse] deallocate tmp coo buffer generated during stage-spars… (PR #82017)
Aart Bik
llvmlistbot at llvm.org
Fri Feb 16 12:16:09 PST 2024
================
@@ -21,8 +22,16 @@ struct StageUnorderedSparseOps : public OpRewritePattern<StageWithSortOp> {
LogicalResult matchAndRewrite(StageWithSortOp op,
PatternRewriter &rewriter) const override {
- return llvm::cast<StageWithSortSparseOp>(op.getOperation())
- .stageWithSort(rewriter);
+ Location loc = op.getLoc();
+ Value tmpBuf = nullptr;
+ auto itOp = llvm::cast<StageWithSortSparseOp>(op.getOperation());
+ LogicalResult stageResult = itOp.stageWithSort(rewriter, tmpBuf);
+ // Deallocate tmpBuf, maybe delegate to buffer deallocation pass in the
----------------
aartbik wrote:
put "maybe" as TODO (so we can grep for it later)
https://github.com/llvm/llvm-project/pull/82017
More information about the Mlir-commits
mailing list