Rewrite and document multi-buffering properly:
- Use IndexingUtils / StaticValueUtils instead of duplicating functionality
- Properly plumb RewriterBase through.
- Add support
- Better debug messages.
This revision is otherwise almost NFC, if it weren't for the extra DeallocOp
support that would previoulsy make multi-buffering fail.
Depends on: D145036
Nit: Dangling For each