Choose Tile Size and Work Partitioning

Determine tile sizes and grid layouts for CUDA or Triton kernels.

54|7|Updated Apr 10, 2026
One-click install
npx skills add https://github.com/tensormux/kernel-skills --skill choose-tile-size-and-work-partitioning
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Choose Tile Size and Work Partitioning
Source: https://github.com/tensormux/kernel-skills/tree/main/skills/patterns/choose-tile-size-and-work-partitioning
Command: npx skills add https://github.com/tensormux/kernel-skills --skill choose-tile-size-and-work-partitioning

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Guides AI agents in selecting tile sizes and work partitioning for CUDA or Triton kernels, balancing shared memory use, register pressure, occupancy, and problem shape.

Core Features & Use Cases

  • Structured decision framework to evaluate smem budgets, register pressure, and occupancy for GEMM-like tiling, attention, or elementwise kernels.
  • Guided configuration outputs including BLOCK_M, BLOCK_N, BLOCK_K, and grid strategy tailored to problem shapes (static or dynamic) and hardware limits.
  • Use Case: When designing a new tiled kernel with irregular shapes, this skill helps pick tile sizes that maximize occupancy and throughput while avoiding shared memory overruns.

Quick Start

Provide problem dimensions and hardware constraints to receive recommended tile sizes and launch configuration.

Frequently Asked Questions about Choose Tile Size and Work Partitioning

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

FAQPage Schema
How do I choose tile sizes for CUDA or Triton kernels to maximize occupancy?

To choose tile sizes for CUDA or Triton kernels, balance shared memory use, register pressure, and occupancy against your problem shape and hardware limits to determine viable BLOCK_M, BLOCK_N, and BLOCK_K dimensions.

What's the best way to partition work and grid layout for a tiled GPU kernel?

The best work partitioning strategy for a tiled GPU kernel applies a grid layout tailored to your problem dimensions, explicitly stating block configurations to maximize throughput while avoiding shared memory overruns.

Why does my Triton kernel have low occupancy with irregular problem shapes?

Triton kernels face low occupancy with irregular shapes when tile sizes cause high register pressure or exceed shared memory budgets, requiring a structured evaluation of hardware constraints to rebalance the configuration.

Can I autotune tile sizes when multiple configurations are viable for my kernel?

You can autotune tile sizes when multiple viable configurations exist by generating an optional autotuning plan that evaluates different launch configurations against your kernel's specific hardware limits.

How do I balance shared memory and registers for GEMM-like tiling without overruns?

Balancing shared memory and registers for GEMM-like tiling requires evaluating hardware smem budgets and register pressure to select explicit tile sizes that maximize occupancy without exceeding memory limits.