Skip to content

Conversation

@wrongtest-intellif
Copy link
Contributor

Hi, we found a kind of corner bad cases for reverse inline primitive. Currently we encode predicate produced by inlining as block compute body, like

with T.block():
    if pred:
        body()

While other primitives (typically cache_write) currently may only respect the predicate of T.where for region estimation. The newly created blocks take the risk of region out-of-bound write accesses, lead to segfaults even in cpu target computations.

The change proposes to use equavalent T.where when possible to make it more consistent with s-tir system, like

with T.block():
    T.where(pred_on_loop_vars)
    body()

@wrongtest-intellif
Copy link
Contributor Author

@tvm-bot re-run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants