CASS: データ、モデル、ベンチマークを用いたNvidiaからAMDへのトランスパイレーション
CASS: Nvidia to AMD Transpilation with Data, Models, and Benchmark
May 22, 2025
著者: Ahmed Heakl, Sarim Hashmi, Gustavo Bertolo Stahl, Seung Hun Eddie Han, Salman Khan, Abdulrahman Mahmoud
cs.AI
要旨
本論文では、クロスアーキテクチャGPUコードトランスパイレーションのための初の大規模データセットおよびモデルスイートであるCASSを紹介します。CASSは、ソースレベル(CUDA ↔ HIP)とアセンブリレベル(Nvidia SASS ↔ AMD RDNA3)の両方の翻訳を対象としています。このデータセットは、ホストとデバイスにわたる7万組の検証済みコードペアを含み、低レベルGPUコードの移植性における重要なギャップを埋めるものです。このリソースを活用して、ドメイン固有の言語モデルファミリーであるCASSを訓練し、95%のソース翻訳精度と37.5%のアセンブリ翻訳精度を達成しました。これは、GPT-4o、Claude、Hipifyなどの商用ベースラインを大幅に上回る性能です。生成されたコードは、85%以上のテストケースでネイティブ性能を維持し、ランタイムとメモリの挙動を保持しています。厳密な評価を支援するため、16のGPUドメインにわたるキュレーションされたベンチマークであるCASS-Benchを導入し、グラウンドトゥルースの実行を提供します。すべてのデータ、モデル、評価ツールはオープンソースとして公開され、GPUコンパイラツール、バイナリ互換性、LLMガイドによるハードウェア翻訳の進展を促進します。データセットとベンチマークはhttps://huggingface.co/datasets/MBZUAI/cass{blue{HuggingFace}}に、コードはhttps://github.com/GustavoStahl/CASS{blue{GitHub}}に公開されています。
English
We introduce CASS, the first large-scale dataset and model suite for
cross-architecture GPU code transpilation, targeting both source-level (CUDA
leftrightarrow HIP) and assembly-level (Nvidia SASS leftrightarrow AMD
RDNA3) translation. The dataset comprises 70k verified code pairs across host
and device, addressing a critical gap in low-level GPU code portability.
Leveraging this resource, we train the CASS family of domain-specific language
models, achieving 95% source translation accuracy and 37.5% assembly
translation accuracy, substantially outperforming commercial baselines such as
GPT-4o, Claude, and Hipify. Our generated code matches native performance in
over 85% of test cases, preserving runtime and memory behavior. To support
rigorous evaluation, we introduce CASS-Bench, a curated benchmark spanning 16
GPU domains with ground-truth execution. All data, models, and evaluation tools
are released as open source to foster progress in GPU compiler tooling, binary
compatibility, and LLM-guided hardware translation. Dataset and benchmark are
on
https://huggingface.co/datasets/MBZUAI/cass{blue{HuggingFace}},
with code at
https://github.com/GustavoStahl/CASS{blue{GitHub}}.Summary
AI-Generated Summary