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
[Unittest][Metal] Add minimal metal functionality test to CI #15756
[Unittest][Metal] Add minimal metal functionality test to CI #15756
Conversation
Prior to this commit, the CI compiled TVM with `USE_METAL=ON` on OSX, as defined in `conda/recipe/build.sh`, but did not validate the execution of any generated metal kernels. As a result, breakage could occur without being caught by the CI, such as found following apache#15103. This commit adds the execution of a single metal kernel as a minimal functionality test of the metal backend.
The initial version of this PR has a deliberate failure by asserting that After these three items are verified, the assert statement will be removed, and all CI steps including the "CI / MacOS" stage should pass. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you! Awesome improvement to add minimal Metal testing to CI. Excited about it!
Hmm, first time that I've been disappointed to have the CI show green. The "CI / MacOS" section skipped the Metal test, rather than failing on the assert. |
And getting closer. The "compile-only" test has two versions, one of which defines the PackedFunc Now, the final validation of the CI: Generating code in |
And the results look good, with the intentionally-incorrect codegen resulting in a failure found at compile-time of the The intentionally-incorrect codegen is now removed, and the compile-only test should now pass. Assuming this latest update passes CI, this PR will be marked as ready for review. |
And ready for review! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thank you! Glad to see such tests in CI.
Prior to this commit, the CI compiled TVM with
USE_METAL=ON
on OSX, as defined inconda/recipe/build.sh
, but did not validate the execution of any generated metal kernels. As a result, breakage could occur without being caught by the CI, such as found following #15103.This commit adds the execution of a single metal kernel as a minimal functionality test of the metal backend.