Extend multi-buffering to simplify the affine map created if any of its operands are constants. This avoids downstream problems where more complex affine.apply operations cannot be expanded.
Transfer attributes from the old allocation to the new allocation.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Please include context by using -U9999999 when creating patch:
https://llvm.org/docs/Phabricator.html#requesting-a-review-via-the-web-interface
mlir/lib/Dialect/MemRef/Transforms/MultiBuffer.cpp | ||
---|---|---|
118 | We should bail out before if the alloc doesn't dominate the loop as the transformation doesn't make sense. |
This looks good to me once the style comments are addressed
mlir/lib/Dialect/MemRef/Transforms/MultiBuffer.cpp | ||
---|---|---|
108 | nit: please remove brace for single line if: | |
129 | nit: please spell out the types here: |
@ThomasRaoux thank you very much for the review! Would you mind being the one to actually commit the change? Unfortunately I don't have commit access.
Not a problem. Could you send me the name and email to use for the commit? (for reference: https://llvm.org/docs/Phabricator.html#committing-someone-s-change-from-phabricator)
nit: please remove brace for single line if:
https://llvm.org/docs/CodingStandards.html#don-t-use-braces-on-simple-single-statement-bodies-of-if-else-loop-statements