[MLIR] Don't insert YieldOp for non-void loop.for by default.
The ForOp::build ensures that there is a block terminator which is great for the default use case when there are no iter_args and loop.for returns no results. In non-zero results case we always need to call replaceOpWithNewOp which is not the nicest thing in the world. We can stop inserting YieldOp when iter_args is non-empty. IfOp::build already behaves similarly.
parent
0359b86d
Please register or sign in to comment