This revision cleans up the implementation of hoist padding and extends it to also work in the
absence of packing loops.
This allows better composition when hoisting the padded result of a DPS operation.
A systematic usage of RewriterBase is applied to the implementation.
Depends on: D144856
I think this is not correct if the loop yields iter_args in a swapped order. Or if it yields a value that is not originating from the iter_arg.
Generally speaking, this function looks similar to AnalysisState::findvalueInReverseUseDefChain. In the long term, we could make that function independent of bufferization (make it a function that operates on DestinationStyleOpInterface). But we would also have to model loop bbArgs in DestinationStyleOpInterface, so that we can trace back values through loops.