test: Enable all modules in AOT build test#1528
Conversation
There was a problem hiding this comment.
Summary of Changes
Hello @yongwww, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
This pull request enhances the AOT (Ahead-Of-Time) build test script by enabling additional FlashInfer modules and expanding the supported CUDA architectures. This ensures a more thorough validation of the AOT build process, covering more functionalities and hardware configurations.
Highlights
- AOT Build Test Enhancement: The AOT build test script (scripts/task_test_aot_build_import.sh) has been updated to include more comprehensive testing.
- Module Activation: The flashinfer.aot command now explicitly enables communication (--add-comm True) and Mixture-of-Experts (--add-moe True) modules during the AOT build test.
- CUDA Architecture Support: The TORCH_CUDA_ARCH_LIST environment variable has been extended to include CUDA architectures 10.0 and 12.0, broadening the range of GPUs tested in the AOT build.
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Code Review
This pull request updates the AOT build test script to enable all modules, including communication and MoE kernels, and adds support for newer CUDA architectures. The changes align with the goal of expanding test coverage for the AOT build.
My review includes one suggestion to correct a potential typo in the list of CUDA architectures to ensure the configuration is valid and clear.
| : ${MAX_JOBS:=$(nproc)} | ||
| : ${CUDA_VISIBLE_DEVICES:=""} | ||
| export TORCH_CUDA_ARCH_LIST="7.5 8.0 8.9 9.0+PTX" | ||
| export TORCH_CUDA_ARCH_LIST="7.5 8.0 8.9 9.0+PTX 10.0 12.0" |
There was a problem hiding this comment.
The CUDA compute capability 12.0 is not a recognized architecture. The latest is Blackwell, which corresponds to 10.0. This is likely a typo. To avoid potential build errors or confusion, it's best to remove it.
Also, for consistency with 9.0+PTX, it would be good to add +PTX to 10.0 for forward compatibility.
| export TORCH_CUDA_ARCH_LIST="7.5 8.0 8.9 9.0+PTX 10.0 12.0" | |
| export TORCH_CUDA_ARCH_LIST="7.5 8.0 8.9 9.0+PTX 10.0+PTX" |
📌 Description
Currently comm modules and moe modules are not compiled in aot unittests, which results in lots of issues such as #1371 #1410, and #1530.
This PR adds these modules to aot UT to make sure we capture the potential compilation error of these modules.
#1531 (a bugfix) changes were ported into this PR to test together.
🔍 Related Issues
#1371, #1410, #1530, #1531
🚀 Pull Request Checklist
Thank you for contributing to FlashInfer! Before we review your pull request, please make sure the following items are complete.
✅ Pre-commit Checks
pre-commitby runningpip install pre-commit(or used your preferred method).pre-commit install.pre-commit run --all-filesand fixed any reported issues.🧪 Tests
unittest, etc.).Reviewer Notes
cc @nvpohanh @weireweire