triton-to-gluon

Translate Triton GPU kernels to explicit AMD Gluon kernels for CDNA GPUs.

Updated Mar 14, 2026
One-click install
npx skills add https://github.com/leonling-ll/claude-skills --skill triton-to-gluon
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: triton-to-gluon
Source: https://github.com/leonling-ll/claude-skills/tree/main/triton-to-gluon
Command: npx skills add https://github.com/leonling-ll/claude-skills --skill triton-to-gluon

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Translate a Triton GPU kernel into an explicit Gluon kernel that uses AMD tensor layouts to enable efficient execution on CDNA GPUs.

Core Features & Use Cases

  • Detects GPU architecture (gfx942 for CDNA3, gfx950 for CDNA4) and selects the appropriate layout conventions.
  • Dumps Triton IR artifacts (ttgir/llir) and derives precise tensor layouts and pipeline structure.
  • Generates a Gluon kernel with explicit layouts (BlockedLayout, SwizzledSharedLayout, AMDMFMALayout, DotOperandLayout) and an integrated verify/profiler workflow.
  • Saves generated artifacts and integrates with existing porting workflows for matmul/attention/linear kernels on AMD GPUs.

Quick Start

Run the translation on your Triton kernel file, for example /triton-to-gluon <kernel_file.py>.

Frequently Asked Questions about triton-to-gluon

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I translate Triton kernels to Gluon for AMD CDNA GPUs?

To translate Triton kernels to Gluon for AMD CDNA GPUs, you run the translation on your kernel file. The tool extracts TTGIR/LLIR artifacts, detects the GPU architecture, generates explicit layouts, and saves the ported Gluon kernel artifacts.

What AMD GPU architectures are supported when porting Triton to Gluon?

Porting Triton to Gluon supports AMD CDNA GPUs, specifically detecting gfx942 for CDNA3 and gfx950 for CDNA4 architectures. This covers porting workflows for MI300X, MI308X, and MI350 hardware to ensure proper layout conventions.

What explicit layouts are generated during Triton to Gluon kernel translation?

Translating Triton to Gluon generates explicit tensor layouts including BlockedLayout, SwizzledSharedLayout, AMDMFMALayout, and DotOperandLayout. These layouts are derived by dumping Triton IR artifacts to enable efficient execution on AMD GPUs.

Does porting Triton kernels to AMD Gluon include verification and profiling?

Porting Triton kernels to AMD Gluon includes an integrated verify and profiler workflow. It uses torch.profiler to ensure correctness and extract precise tensor layouts and pipeline structure during the translation process.

Why do I need to extract TTGIR and LLIR artifacts to port Triton kernels to AMD GPUs?

Extracting TTGIR and LLIR artifacts is required to derive precise tensor layouts and pipeline structure when porting Triton kernels to AMD GPUs. This explicit layout generation ensures the Gluon kernel executes efficiently on CDNA hardware.

What types of kernels can I port from Triton to Gluon on AMD GPUs?

You can port matmul, attention, and linear kernels from Triton to Gluon on AMD GPUs. The translation process integrates with existing porting workflows to generate explicit AMD tensor layouts for these specific kernel types.