Back to Skills

tilegym-adding-cutile-kernel

Add a new cuTile GPU kernel operator to TileGym. Covers dispatch registration in ops.py, cuTile backend implementation, __init__.py exports, test creation, and benchmark in tests/benchmark. Use when adding, creating, or implementing a new cuTile operator/kernel in TileGym, or when asking how to register a new cuTile op.

2,741stars319forksUpdated 7/31/2026

Security Assessment

Safe(95/100)
Security Score95/100

About tilegym-adding-cutile-kernel

This skill is an NVIDIA end-to-end workflow for adding a new cuTile GPU kernel operator to the TileGym library. It solves the problem of correctly wiring a new operator through every layer of TileGym so it is dispatchable, implemented, exported, tested, and benchmarked, avoiding the common mistake of forgetting a registration step that leaves the backend implementation unloaded. It enforces a strict ordered checklist via TodoWrite, requiring each step to result in a file write or an explicit skip decision with no silent omissions.

The workflow has six steps: registering a dispatch interface in ops.py as the single entry point (whose body only raises NotImplementedError), implementing the cuTile backend kernel in a dedicated module using cuda.tile with register_impl, registering the new operator in the cutile __init__.py (imports and __all__), adding tests that import from tilegym.ops rather than the backend module and compare against a PyTorch reference across shapes and dtypes, adding a benchmark under tests/benchmark, and finally verifying with pytest and lint. It provides code templates for each step and points to existing operators like silu_and_mul and softmax as references. The bundled benchmark and skill card report NVSkills-Eval results with a 100% security score, no required credentials, and dual CC-BY-4.0/Apache-2.0 licensing.

It targets GPU kernel developers and ML systems engineers contributing operators to TileGym. Typical use cases include adding, creating, or implementing a new cuTile operator and learning how to register it properly. The output is Python source files and shell commands run against a local TileGym checkout.

FAQ

What does this skill help me do?

Add a new cuTile GPU kernel operator to TileGym end to end: dispatch registration in ops.py, cuTile backend implementation, __init__.py exports, test creation, and a benchmark, followed by verification.

Why is the __init__.py step emphasized as critical?

Missing the registration in the cutile __init__.py (imports and __all__) means the cuTile backend implementation never gets loaded, so the operator silently won't work.

How should tests import the operator?

Always import from tilegym.ops, never directly from tilegym.ops.cutile.my_op, and compare results against a PyTorch reference implementation across multiple shapes and dtypes.

Does it require any credentials?

No. The skill card lists no required API keys or external credentials; it produces Python source and shell commands run against a local TileGym checkout.

How is the workflow enforced?

It mandates creating a TodoWrite checklist before writing code and executing the six steps strictly in order, marking each complete and never silently skipping (a skip must be an explicit noted decision).

All Files

5 files
skill.oms.sig4.5 KB
View
BENCHMARK.md4.2 KB
View
skill-card.md3.6 KB
View
evals/evals.json5.4 KB
View
SKILL.md8.0 KB
View

Install tilegym-adding-cutile-kernel

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill

Repository

nvidia/skills