为 FlashInfer 基准脚本增加统一运行参数控制 #57

Open
Mengz wants to merge 1 commits from Mengz/op_optimization:mengz/flashinfer-benchmark-controls into master
First-time contributor

test-line-1

test-line-2这次修改把 FlashInfer 基准脚本里分散的 batch size、序列长度、warmup、迭代次数和输出目录收敛成统一入口,避免在不同沐曦环境下为了做短跑验证、回归复现和问题定位反复改源码。

改动覆盖 batch decode、MLA paged attention、paged prefill 和 ragged prefill 四类脚本,并把公共参数解析、案例截断、失败记录和 CSV 输出能力收敛到 bench_common 里,保证各脚本的行为一致。

已经在沐曦 GPU 环境完成实际运行验证,BatchDecodeWithPagedKVCacheWrapper 成功输出 0.020ms、52.72 GB/s、0.84 TFLOPs 的基准结果,其余 wrapper 也能按统一参数链路执行并保留失败信息,方便后续继续对现有算子问题做回归和定位。这次修改把 FlashInfer 基准脚本里分散的 batch size、序列长度、warmup、迭代次数和输出目录收敛成统一入口,避免在不同沐曦环境下为了做短跑验证、回归复现和问题定位反复改源码。

改动覆盖 batch decode、MLA paged attention、paged prefill 和 ragged prefill 四类脚本,并把公共参数解析、案例截断、失败记录和 CSV 输出能力收敛到 bench_common 里,保证各脚本的行为一致。

已经在沐曦 GPU 环境完成实际运行验证,BatchDecodeWithPagedKVCacheWrapper 成功输出 0.020ms、52.72 GB/s、0.84 TFLOPs 的基准结果,其余 wrapper 也能按统一参数链路执行并保留失败信息,方便后续继续对现有算子问题做回归和定位。

test-line-1 test-line-2这次修改把 FlashInfer 基准脚本里分散的 batch size、序列长度、warmup、迭代次数和输出目录收敛成统一入口,避免在不同沐曦环境下为了做短跑验证、回归复现和问题定位反复改源码。 改动覆盖 batch decode、MLA paged attention、paged prefill 和 ragged prefill 四类脚本,并把公共参数解析、案例截断、失败记录和 CSV 输出能力收敛到 bench_common 里,保证各脚本的行为一致。 已经在沐曦 GPU 环境完成实际运行验证,BatchDecodeWithPagedKVCacheWrapper 成功输出 0.020ms、52.72 GB/s、0.84 TFLOPs 的基准结果,其余 wrapper 也能按统一参数链路执行并保留失败信息,方便后续继续对现有算子问题做回归和定位。这次修改把 FlashInfer 基准脚本里分散的 batch size、序列长度、warmup、迭代次数和输出目录收敛成统一入口,避免在不同沐曦环境下为了做短跑验证、回归复现和问题定位反复改源码。 改动覆盖 batch decode、MLA paged attention、paged prefill 和 ragged prefill 四类脚本,并把公共参数解析、案例截断、失败记录和 CSV 输出能力收敛到 bench_common 里,保证各脚本的行为一致。 已经在沐曦 GPU 环境完成实际运行验证,BatchDecodeWithPagedKVCacheWrapper 成功输出 0.020ms、52.72 GB/s、0.84 TFLOPs 的基准结果,其余 wrapper 也能按统一参数链路执行并保留失败信息,方便后续继续对现有算子问题做回归和定位。
Mengz added 1 commit 2026-06-26 10:03:59 +08:00
This pull request has changes conflicting with the target branch.
  • 基于AI Agent开发范式的国产GPU大模型推理算子库优化/baselines/flashinfer_baseline/bench_batch_decode.py
  • 基于AI Agent开发范式的国产GPU大模型推理算子库优化/baselines/flashinfer_baseline/bench_batch_mla.py
  • 基于AI Agent开发范式的国产GPU大模型推理算子库优化/baselines/flashinfer_baseline/bench_batch_prefill_paged.py
  • 基于AI Agent开发范式的国产GPU大模型推理算子库优化/baselines/flashinfer_baseline/bench_batch_prefill_ragged.py
  • 基于AI Agent开发范式的国产GPU大模型推理算子库优化/baselines/flashinfer_baseline/bench_common.py
You can also view command line instructions.

Step 1:

From your project repository, check out a new branch and test the changes.
git checkout -b Mengz-mengz/flashinfer-benchmark-controls master
git pull mengz/flashinfer-benchmark-controls

Step 2:

Merge the changes and update on Gitea.
git checkout master
git merge --no-ff Mengz-mengz/flashinfer-benchmark-controls
git push origin master
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: metax-maca/op_optimization#57
No description provided.