This pass allows removing getResultConversionKind from
BufferizeTypeConverter. This pass replaces the AppendToArgumentsList
functionality. As far as I could tell, the only use of this functionlity
is to perform the transformation that is implemented in this pass.
Future patches will remove the getResultConversionKind machinery from
BufferizeTypeConverter, but sending this patch for individual review for
clarity.
Just for my understanding: This pass basically simplifies the use of populateWithBufferizeOpConversionPatterns via a custom Rewriter instance for an input dialect, right? Do you plan to remove the conversion patterns in favor of this pass in the future?
My question is here: Why should this pass be executed after the entire bufferization process? Isn't it useful to apply this pass before applying the BufferDeallocation pass, which inserts all the necessary deallocations? Or do you refer to the first part of the "overall" bufferization process, which ports the input program into the "buffer world" (without taking deallocations into account)?
Regarding the Linalg dialect dependency: We are going to discuss possible solutions to remove the Std- and Linalg dialect dependencies from the BufferDeallocation pass in the public Discourse-Forums these days. I suspect that the result of this discussion can also be applied to this pass (in the future).