[mlir][NFC] accept plain OpBuidler in folded construction helpers
A group of functions in the Affine dialect provides a mechanism for buliding folded-by-construction operations. These functions used to accept a `RewriterBase` reference because they may need to erase the operations that were folded and notify the rewriter when called from rewrite patterns. Adopt a different approach: postpone the builder notification of the op creation until we are certain that the op will not be folded away. This removes the need to notify the rewriter about op deletion following op construction in case of successful folding, and removes a bunch of one-off `IRRewriter` instances in transform code that may mess up insertion points. Reviewed By: springerm, mravishankar Differential Revision: https://reviews.llvm.org/D130616
parent
ad16268f
Please register or sign in to comment