PTXBench:利用架构特定PTX对LLM进行GPU内核优化的基准测试与适配

·

研究论文 · 2026/08/20

我们提出了PTXBench,一个用于评估和调整大语言模型(LLMs)使用特定于架构的PTX进行GPU内核优化的基准。PTXBench在H100和B200 GPU上,针对GEMM和注意力工作负载,衡量功能正确性、所选目标指令是否在运行时执行,以及相对于前沿库的加速比。我们的评估显示,特定于架构的PTX能力仍然不均衡:在复杂的注意力反向工作负载上,成功率大幅下降,并且执行目标指令并不一定转化为有竞争力的性能。没有评估的模型在整套测试中始终匹配前沿库。我们进一步使用监督微调来调整Qwen3.6-27B。修复条件训练改善了一些任务,但泛化仍然不均衡;除了数据集大小外,数据覆盖、平衡和推理教师的质量也很重要。PTXBench为衡量和改进LLMs利用不断发展的GPU架构的能力提供了一个可审计的测试平台。

该论文提出了一个针对GPU内核优化的新基准,填补了评估LLMs使用特定架构PTX能力的空白,并提供了详细的评估和适应方法,对硬件和AI交叉领域的研究具有重要价值。

We introduce PTXBench, a benchmark for evaluating and adapting large language models (LLMs) to use architecture-specific PTX for GPU kernel optimization. PTXBench measures functional correctness, whether selected target instructions execute at runtime, and speedup over frontier libraries across GEMM and attention workloads on H100 and B200 GPUs. Our evaluation shows that architecture-specific PTX capability remains uneven: success rates fall substantially on complex attention backward workloads, and executing the target instructions does not necessarily translate into competitive performance. No evaluated model consistently matches frontier libraries across the suite. We further adapt Qwen3.6-27B using supervised fine-tuning. Repair-conditioned training improves several tasks, but generalization remains uneven; data coverage, balance, and the quality of the reasoning teacher matter in addition to dataset size. PTXBench provides an auditable testbed for measuring and improving LLMs' ability to exploit evolving GPU architectures.

阅读原文

参与讨论