I’ve got a transformation which looks nearly identical to bufferization. I’ve got a function-like op with some arguments and results which I need to mutate the types and make them all arguments along with all of the invocations of said function-like op. The documentation on bufferization here Bufferization on MLIR - MLIR (llvm.org) describes exactly what I need. It was recently removed but I can’t seem to find a direct replacement.
I’ve seen the “2020-11-19 ODM: Type Conversions the Not-So-Hard Way” presentation, but the bufferization part seems to only cover the new bufferization passes functionality and usage. The second part (which I’ve found helpful) is just about Dialect/Type conversions and doesn’t cover how to implement bufferization patterns.
mlir/Transforms/Bufferize.h seems to offer code which is very specific to tensors and memrefs.
Similarly, the DialectConversion API doesn’t seem to know about function-like signature conversions in that it doesn’t have any hooks for dealing with converting the call ops the way the old bufferization framework had (according to the outdated docs). I might be wrong about that – there may be some magic behind the scenes which I missed.
So is there a replacement which’ll handle both the function-like op conversion and the call-like op conversions? If so, could someone point me at some documentation, the C++ API, or an example use?