fix: correct batched matmul stride for bs=1 and integrate CTest into build pipeline#157
Open
chen2021673 wants to merge 1 commit into
Open
fix: correct batched matmul stride for bs=1 and integrate CTest into build pipeline#157chen2021673 wants to merge 1 commit into
chen2021673 wants to merge 1 commit into
Conversation
… build pipeline Set stride to 0 when batch_size is 1 to enable proper broadcasting in cuBLAS, and add configurable CTest execution after builds with googletest submodule.
Chamberlain0w0
approved these changes
May 22, 2026
Collaborator
|
请贴测试通过截图。 |
This file contains hidden or 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
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.
Summary
bs == 1时将 stride 设为 0,使 cuBLAS 正确广播单个矩阵,避免非法内存访问或结果错误。涉及 forward、backward_input、backward_other 三个函数。
run_models_and_profile.bash中新增RUN_CTEST/CTEST_CMD可配置项,构建完成后自动执行测试;
test_config.json添加对应默认值。third_party/googletest),为 CTest 提供测试框架支持。-DUSE_NCCL=ON标志。Changes
infini_train/src/kernels/cuda/matmul.cuscripts/run_models_and_profile.bashscripts/test_config.jsondocs/test_usage_guide.mdthird_party/googletestTest
ctest 测例全部通过