New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[TIR] ConvertSSA process entry func first #16236
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cc: @tqchen |
tqchen
approved these changes
Dec 14, 2023
Lunderberg
added a commit
to Lunderberg/tvm
that referenced
this pull request
Dec 15, 2023
The buf reported in apache#16237 can be resolved by tracking variable usage in a thread extent.
Lunderberg
added a commit
to Lunderberg/tvm
that referenced
this pull request
Dec 18, 2023
The buf reported in apache#16237 can be resolved by tracking variable usage in a thread extent.
Lunderberg
added a commit
that referenced
this pull request
Jan 3, 2024
* [TIR] In SplitHostDevice, check for variables in thread extents Otherwise, they would be undefined after being de-duplicated by `ConvertSSA`. * Revert #16236 The buf reported in #16237 can be resolved by tracking variable usage in a thread extent. * lint fixes * Update TIR well-formed checker for env thread SSA requirements Environment threads must reuse the same `tir::Var` across all `AttrStmt` instances in a `PrimFunc`, but must not reuse across separate `PrimFunc`s in an `IRModule`. * Update ConvertSSA to handle environment threads' SSA requirements * lint fix * Updated docstrings for VerifyWellFormed * Rely on script.Complete for read/writes Avoids issue in cortexm unit tests resulting from read/write annotations being present in the root block, followed by application of BindParams. * Typo fix * Added structural equal comparison in unit test
junrushao
pushed a commit
to junrushao/tvm
that referenced
this pull request
Jan 7, 2024
…he#16250) * [TIR] In SplitHostDevice, check for variables in thread extents Otherwise, they would be undefined after being de-duplicated by `ConvertSSA`. * Revert apache#16236 The buf reported in apache#16237 can be resolved by tracking variable usage in a thread extent. * lint fixes * Update TIR well-formed checker for env thread SSA requirements Environment threads must reuse the same `tir::Var` across all `AttrStmt` instances in a `PrimFunc`, but must not reuse across separate `PrimFunc`s in an `IRModule`. * Update ConvertSSA to handle environment threads' SSA requirements * lint fix * Updated docstrings for VerifyWellFormed * Rely on script.Complete for read/writes Avoids issue in cortexm unit tests resulting from read/write annotations being present in the root block, followed by application of BindParams. * Typo fix * Added structural equal comparison in unit test
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
ConvertSSA is called in SplitHostDevice. The vars which only exists in T.launch_thread extent in device function must be the same as host function, so we need to let ConvertSSA process host function first to avoid var redefine.