-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[Relax] Require correct input/output shapes R.call_tir
#17285
[Relax] Require correct input/output shapes R.call_tir
#17285
Conversation
Prior to this commit, the Relax well-formed checker validated arguments provided to Relax functions, but did not validate arguments provided to `R.call_tir`. As a result, incorrect arguments from Relax to TIR would not be checked until runtime, if at all. This commit updates the well-formed checker to verify that `R.call_tir` has received the correct arguments, and has the correct output shape specified in the `out_sinfo` parameter.
The implementation in this PR is similar to #17216, but with a few key changes:
|
All CI tests are passing, with the exception of the |
Initial implementation performed the validation as part of `FNormalize`, to maximize coverage of this check. This increased end-to-end compilation time by ~10%, and so the check was requested to be restricted to the well-formed checker. Expensive operator-specific validation is now performed in the new `FValidate` attribute.
@tvm-bot rerun |
Looks like the failure on #17334 should resolve the hexagon CI issues by breaking up the single gigantic test, allowing them to be sharded out. |
Prior to this commit, the Relax well-formed checker validated arguments provided to Relax functions, but did not validate arguments provided to
R.call_tir
. As a result, incorrect arguments from Relax to TIR would not be checked until runtime, if at all.This commit updates the well-formed checker to verify that
R.call_tir
has received the correct arguments, and has the correct output shape specified in theout_sinfo
parameter.