Refactor: migrate ABG and HBG examples to SceneTestCase under tests/st/#541
Merged
ChaoWao merged 1 commit intohw-native-sys:mainfrom Apr 15, 2026
Merged
Refactor: migrate ABG and HBG examples to SceneTestCase under tests/st/#541ChaoWao merged 1 commit intohw-native-sys:mainfrom
ChaoWao merged 1 commit intohw-native-sys:mainfrom
Conversation
There was a problem hiding this comment.
Code Review
This pull request refactors and consolidates several examples (BGEMM, Vector, Matmul, and Paged Attention) into a standardized testing framework using SceneTestCase. It removes legacy example directories and introduces new test scripts in the tests/st/a2a3/ directory. Review feedback identified critical signature mismatches in the TestPagedAttentionUnrollAicpuBuildGraph test class, specifically regarding missing scalar arguments and incorrect argument counts for the orchestration and kernel functions, including aiv_softmax_prepare.cpp and aiv_online_update.cpp.
8ab1933 to
e2580ac
Compare
- Move aicpu_build_graph and host_build_graph cases from examples/ to tests/st/, converting golden.py/kernel_config.py entries to SceneTestCase format - Delete obsolete golden.py, kernel_config.py, README, and docs - Add small-tile dispatch (<16,16,...>) to HBG paged attention kernels so the small1 case (head_dim=16, block_size=16) no longer segfaults from buffer overruns
ChaoWao
approved these changes
Apr 15, 2026
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.
全量 Case 表
examples/.../host_build_graph/bgemm/examples/.../host_build_graph/vector_example/examples/.../host_build_graph/matmul/examples/.../host_build_graph/paged_attention/examples/.../host_build_graph/paged_attention/tests/st/.../host_build_graph/paged_attention/tests/st/.../host_build_graph/paged_attention/examples/.../aicpu_build_graph/bgemm/examples/.../aicpu_build_graph/vector_example/examples/.../aicpu_build_graph/paged_attention/examples/.../aicpu_build_graph/paged_attention/tests/st/.../aicpu_build_graph/paged_attention_unroll/tests/st/.../aicpu_build_graph/paged_attention_unroll/tests/st/.../aicpu_build_graph/paged_attention_unroll/迁移后变更
tests/st/.../host_build_graph/bgemm/tests/st/.../host_build_graph/vector_example/tests/st/.../host_build_graph/matmul/tests/st/.../host_build_graph/paged_attention/tests/st/.../host_build_graph/paged_attention/tests/st/.../host_build_graph/paged_attention/tests/st/.../host_build_graph/paged_attention/tests/st/.../aicpu_build_graph/bgemm/tests/st/.../aicpu_build_graph/vector_example/tests/st/.../aicpu_build_graph/paged_attention/tests/st/.../aicpu_build_graph/paged_attention/tests/st/.../aicpu_build_graph/paged_attention_unroll/tests/st/.../aicpu_build_graph/paged_attention_unroll/tests/st/.../aicpu_build_graph/paged_attention_unroll/迁移变更小结
examples/a2a3/全部删除,统一为tests/st/a2a3/下的@scene_test类examples/host/paged_attention/独立目录删除,small1/small2 合并入paged_attention/的 CASES 列表golden.py+kernel_config.py→@scene_test类中CALLABLE+CASES+generate_args()+compute_golden()