The op bufferizes similarly to tensor.generate: it is lowered to a linalg.map, which may then lower to a loop nest that fills the buffer.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
I wouldn't be able to catch many, even easy flaws, but from what I can judge, all looks good, and I do see the splat op in my own example being bufferized with the patch. Thanks!
Comment Actions
Actually, do we really need the MapOp with an empty body? Can we not just allocate the tensor and that's it?
Comment Actions
The body of the linalg.map is not empty. It has a linalg.yield terminator. The reason why I used linalg.map is because it can lower to a loop or vectorize. Alternatively, I could've generated a loop nest that fills the allocation, but then the op would not vectorize anymore.
Comment Actions
Thanks for clarifying and insisting ;) Indeed, it does yield something. I don't know how I got to the impression it did not... All good now :)