Lunderberg opened a new pull request, #16682: URL: https://github.com/apache/tvm/pull/16682
In some cases, an `AttrStmt` may legally refer to a TIR variable that hasn't yet been defined. For example, the `"pragma_parallel_launch_point"` attribute, which annotates a variable that is about to occur in a ForNode. Prior to this commit, `ConvertSSA` treated the `AttrStmt` as the usage of a variable, followed by a nested definition to be de-duplicated. This resulted in the output `AttrStmt` containing a reference to an undefined variable. This commit updates `ConvertSSA` to handle this case. If an `AttrStmt` refers to a not-yet-defined variable, the body is visited before marking it as defined. This implementation may be simplified in the future by moving "pragma_parallel_launch_point" to be an annotation on the `ForNode`, rather than an `AttrStmt`. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
