[PATCH] D79329: [MLIR] Update the FunctionAndBlockSignatureConverter and NonVoidToVoidReturnOpConverter of Buffer Assignment

Stephan Herhut via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 5 01:34:32 PDT 2020


herhut requested changes to this revision.
herhut added a comment.
This revision now requires changes to proceed.

Please add a test for the case that is currently asserted.



================
Comment at: mlir/include/mlir/Transforms/BufferPlacement.h:117
     // Find the corresponding output buffer for each operand.
-    assert(numReturnValues <= numFuncArgs &&
+    assert(returnOp.getNumOperands() <= numFuncArgs &&
            "The number of operands of return operation is more than the "
----------------
In the case where the return has non-memref operands, this can fail even for correct code as the non-memref operands do not require a function argument. Maybe add a test for such a case?




Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D79329/new/

https://reviews.llvm.org/D79329





More information about the llvm-commits mailing list