fix(pto): resolve subviews of tpop tiles - #1255
Conversation
Materialize the runtime address of declare_tile roots so subviews of tpop results lower to addressed tile handles. Fixes #1251
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1ff81d30b8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| Value ptr = | ||
| rewriter.create<pto::TileBufAddrOp>(loc, ptrType, value).getDst(); | ||
| return rewriter.create<pto::PtrToIntOp>(loc, ptr).getResult(); |
There was a problem hiding this comment.
Prevent stale CSE of rebound tile addresses
When the same pto.declare_tile handle is rebound by a later pto.tpop and subviewed again, this emits another identical pto.tile_buf_addr %tile even though the tile's runtime address has changed. The shared pipeline runs CSE after pto-resolve-buffer-select, and TileBufAddrOp is marked Pure, so the later extraction can be replaced with the first one, making the later TASSIGN use a stale FIFO-slot address. Please make the generated address value depend on the specific binding/use or otherwise prevent CSE across rebinding tpop operations.
Useful? React with 👍 / 👎.
Summary
pto.subviewoperations rooted at the runtime-boundpto.declare_tileproduced fortpopTEXTRACTworkaroundValidation
check-pto: 1785 passed, 1 unsupported, 0 failed83d01313Fixes #1251