TileLang: Bridge Programmability and Performance in Modern Neural Kernels

Lei Wang, Yu Cheng, Yining Shi, Zhiwen Mo, Zhengju Tang, Wenhao Xie, Tong Wu, Lingxiao Ma, Yuqing Xia, Jilong Xue, Fan Yang, Zhi Yang

International Conference on Learning Representations 2026 · Oral

Overview

The talk "TileLang: Bridge Programmability and Performance in Modern Neural Kernels," presented by Yu Cheng, introduces a novel programming language designed to address a critical challenge in the development of contemporary AI models: the inherent tension between ease of programming and achieving optimal hardware performance for neural network operators. As AI models become increasingly sophisticated, incorporating complex operations like multi-head attention and sparse attention, the underlying kernels that execute these operations on specialized hardware like GPUs grow in complexity. This necessitates highly optimized code that can leverage specific hardware features and memory hierarchies, a task traditionally requiring extensive manual effort and deep hardware expertise.

Watch on SlidesLive

Visual summary for TileLang: Bridge Programmability and Performance in Modern Neural Kernels by Lei Wang, Yu Cheng, Yining Shi, Zhiwen Mo, Zhengju Tang, Wenhao Xie, Tong Wu, Lingxiao Ma, Yuqing Xia, Jilong Xue, Fan Yang, Zhi Yang
Visual summary for TileLang: Bridge Programmability and Performance in Modern Neural Kernels by Lei Wang, Yu Cheng, Yining Shi, Zhiwen Mo, Zhengju Tang, Wenhao Xie, Tong Wu, Lingxiao Ma, Yuqing Xia, Jilong Xue, Fan Yang, Zhi Yang

Key moments

  1. 0:00 Problem: AI kernels are hard to build and optimize
  2. 1:20 Introducing TileLang: explicit control at the tile level
  3. 2:00 TileLang core APIs: allocation, operations, and scheduling
  4. 3:20 Three programming modes: beginner, developer, and expert
  5. 4:40 Evaluation: TileLang's performance on NVIDIA H100
  6. 5:00 Real-world impact and broad industry adoption
  7. 6:00 Summary: TileLang simplifies AI kernel development and optimization

TileLang: Bridge Programmability and Performance in Modern Neural Kernels

Speakers: Lei Wang; Yu Cheng; Yining Shi; Zhiwen Mo; Zhengju Tang; Wenhao Xie; Tong Wu; Lingxiao Ma; Yuqing Xia; Jilong Xue; Fan Yang; Zhi Yang

Conference: ICLR 2026

YouTube: https://slideslive.com/39062055

Overview

The talk "TileLang: Bridge Programmability and Performance in Modern Neural Kernels," presented by Yu Cheng, introduces a novel programming language designed to address a critical challenge in the development of contemporary AI models: the inherent tension between ease of programming and achieving optimal hardware performance for neural network operators. As AI models become increasingly sophisticated, incorporating complex operations like multi-head attention and sparse attention, the underlying kernels that execute these operations on specialized hardware like GPUs grow in complexity. This necessitates highly optimized code that can leverage specific hardware features and memory hierarchies, a task traditionally requiring extensive manual effort and deep hardware expertise.

TileLang emerges as a solution to this dilemma by offering a tile-level programming abstraction. Unlike high-level compilers that abstract away performance-critical details, or low-level CUDA that demands meticulous manual optimization, TileLang provides explicit control over computation and data movement at the "tile" granularity. This allows developers to express complex kernel logic more intuitively while retaining the ability to fine-tune performance-critical aspects such as memory layout, software pipelining, and thread partitioning. The language is designed to bridge the gap between developer productivity and hardware efficiency, enabling the creation of high-performance kernels with significantly less code and effort compared to traditional methods.

The significance of TileLang lies in its potential to accelerate the development and deployment of state-of-the-art AI models. By empowering developers to build efficient, custom kernels without needing extreme low-level expertise, it democratizes access to high-performance computing for novel AI architectures. The project's rapid adoption, extensive hardware support, and integration into industrial and open-source projects underscore its practical impact and its role in shaping the future of AI infrastructure, making it a pivotal contribution to the machine learning systems landscape.

Background

▶ Watch: Problem: AI kernels are hard to build and optimize (0:00)

The rapid evolution of AI models has led to a corresponding increase in the complexity and diversity of neural network operators. Modern architectures frequently employ sophisticated operations such as multi-head attention (MHA) and specialized DeepSeek sparse attention, which are crucial for achieving state-of-the-art results. However, the efficient execution of these operators presents a significant challenge: they are inherently hardware-sensitive. Their performance is critically dependent on how effectively they utilize on-chip memory for intermediate results, and how well they leverage specialized hardware units like Tensor Cores and Tensor Memory Accelerators (TMA) found in modern GPUs. Optimizing these kernels requires meticulous attention to details such as memory layout, data movement patterns, and parallel execution strategies.

Historically, developers have faced a stark trade-off when building these kernels. On one hand, high-level compilers and frameworks like Triton offer improved development efficiency by abstracting away much of the underlying hardware complexity. This allows for quicker implementation and iteration. However, this convenience often comes at a substantial performance cost. These compilers frequently hide performance-critical control, preventing developers from applying the deep optimizations necessary to fully exploit hardware capabilities. For instance, on an NVIDIA H100 GPU, high-level compilers like Triton might achieve only about 20% of the performance of a meticulously hand-tuned kernel for operations like Matrix-Multiply-Accumulate (MLA).

On the other hand, achieving peak performance has traditionally necessitated writing kernels directly in low-level languages such as CUDA. While CUDA grants developers granular control over every aspect of hardware interaction, enabling them to reach near-theoretical performance limits, it demands an extreme level of expertise. Developing a highly optimized kernel in CUDA involves managing hundreds of lines of complex code—up to 500 lines for a simple MLA operation—to handle intricate low-level optimizations. These include explicit memory allocation and layout (e.g., shared memory, registers), fine-grained software pipelining to overlap computation and memory access, and precise warp partitioning strategies to ensure optimal utilization of GPU cores. The sheer manual effort, coupled with the propensity for error in such low-level programming, makes it an unsustainable approach for the rapid development and experimentation required by contemporary AI research.

This dichotomy—programmability at the expense of performance, or performance at the expense of programmability—has created a significant gap in the ML/systems space. The need for a programming paradigm that can bridge this gap, offering a balance between development efficiency and hardware performance, has become paramount. Developers require a tool that allows them to express complex computation logic intuitively while still providing explicit control over performance-critical aspects, without forcing them into the tedious and error-prone domain of raw low-level assembly or CUDA programming. It is precisely this problem that TileLang aims to solve by introducing a structured, tile-level abstraction.

Key Findings

▶ Watch: TileLang core APIs: allocation, operations, and scheduling (2:00)

TileLang's primary contribution is its novel approach to bridging the notorious programmability-performance gap in modern neural kernel development. The core idea revolves around using tiles as fundamental units for both computation and data movement, providing explicit control to developers while automating tedious low-level details. This innovative abstraction yields several key findings and benefits:

Firstly, TileLang demonstrates that explicit tile-level control can significantly enhance performance without sacrificing programmability. By exposing tile APIs that allow developers to describe, place, move, and schedule these computational tiles across different memory layers and execution units, TileLang enables fine-grained optimization. This includes capturing data reuse, managing memory hierarchies efficiently, and tuning critical parameters like partitioning and pipeline depth, all within a more abstract and manageable framework than raw CUDA.

Secondly, the framework achieves performance comparable to expert hand-tuned kernels while requiring significantly less code. For standard kernels like Multi-Head Attention (MHA), TileLang matches the performance of highly optimized libraries such as FlashAttention. More impressively, for specialized kernels like AttentionSinks, TileLang delivers over 20 times speedup compared to PyTorch, all while maintaining a code conciseness similar to high-level compilers like Triton. This directly addresses the problem where high-level compilers often yield only 20% of hand-tuned performance.

Thirdly, TileLang introduces a multi-modal programming approach that accommodates users with varying degrees of hardware expertise. The beginner mode allows for hardware-agnostic tensor expressions, ideal for quick prototyping. The developer mode provides control over thread block tiles, memory allocation, tiling strategies, and scheduling policies, enabling complex algorithms like FlashAttention to be implemented in approximately 50 lines of Python. Finally, the expert mode offers thread-level control over memory, synchronization, and hardware instructions, allowing for performance close to meticulously hand-optimized implementations. This tiered approach allows users to explicitly navigate the trade-off between programmability and performance as needed.

Finally, TileLang has demonstrated rapid and widespread adoption and real-world impact since its open-sourcing. Within a year, it garnered over 55,000 GitHub stars and attracted more than 130 contributors from both academia and industry. It supports a diverse range of hardware backends, including NVIDIA and AMD GPUs, MetaX GPUs, Ascend NPUs, and other platforms like CPUs, WebGPU, and Metal. Industrially, it has been adopted by organizations like DeepSeek (e.g., in DeepSeek-V32 and their TileKernels library) and Microsoft Research. Furthermore, it has been integrated into prominent open-source projects and frameworks such as vLLM, SGLang, and FlashLinearAttention, proving its capability to accelerate the research-to-development pipeline and meet production demands.

Technical Deep Dive

▶ Watch: Three programming modes: beginner, developer, and expert (3:20)

TileLang's technical foundation lies in its innovative use of tiles as the fundamental unit for both computation and data movement, coupled with a set of explicit APIs that grant developers control over performance-critical aspects. This design allows for efficient lowering to hardware while abstracting away the most tedious low-level details.

At its core, TileLang operates by defining a tile as a logical block of data or computation. Developers interact with these tiles through a set of high-level, yet precise, tile control APIs. These APIs are categorized into allocation, operators, and scheduling, providing a comprehensive toolkit for kernel development.

Tile Allocation APIs manage the placement of data within the memory hierarchy:

  • alloc_shared: This API is used to allocate a tile within the shared memory of a GPU, which is a fast, on-chip memory accessible by threads within the same thread block. Efficient use of shared memory is crucial for data reuse and reducing expensive global memory accesses.
  • alloc_fragment: This API further shards a tile across individual threads. Each fragment is then placed into the register file of the corresponding thread. Registers represent the fastest memory level, and keeping data in registers minimizes latency during computation.

Once tiles are allocated, Tile Operators facilitate their manipulation and computation:

  • copy: This is a fundamental operator for transferring tiles across different layers of the memory hierarchy. For example, it can move a tile from slow global memory to faster shared memory, or from shared memory to registers. Efficient data movement is paramount for performance in memory-bound kernels.
  • gemm: This operator performs a general matrix multiply-accumulate operation. It typically operates on tiles residing in registers, accumulating results within a register tile. This directly leverages specialized hardware units like Tensor Cores on NVIDIA GPUs.
  • reduce: This operator applies a reduction (e.g., sum, max) over a tile along a specified dimension, a common operation in many neural network layers.

Scheduling APIs provide mechanisms for orchestrating the execution of tile tasks, enabling overlap and parallelization:

  • pipelined: This API automatically overlaps computation and memory movement across different iterations of a loop. By hiding data transfer latency behind ongoing computations, it significantly improves hardware utilization and overall throughput. This is a common technique in high-performance computing, often requiring manual implementation in CUDA.
  • parallel: This API transforms a sequential computation into a parallel one, allowing multiple threads to cooperatively work on the same computation. This is essential for harnessing the massive parallelism offered by modern GPUs.

To illustrate these concepts, consider a General Matrix Multiplication (GEMM) example. Initially, the input matrices A and B reside in global memory.

  1. Using copy, a tile of A and a tile of B are loaded from global memory into shared memory.
  2. Subsequently, copy is used again to load sub-tiles of A (e.g., A_shared) and B (e.g., B_shared) from shared memory into the register files of the individual threads.
  3. With data in registers, the gemm operator performs the matrix multiply-accumulate operation.
  4. After the main computation loop completes, the resulting tile of C is stored from registers back into shared memory.
  5. Finally, another copy operation writes the completed C tile from shared memory back to its corresponding location in global memory.

A key aspect of TileLang's design is its multi-modal programming approach, catering to different levels of user expertise:

  • Beginner Mode: This mode is designed for maximum convenience. Users only need to specify a simple tensor expression, similar to what one might write in frameworks like PyTorch or NumPy. TileLang automatically generates efficient tile-level code. This mode is hardware-agnostic and ideal for rapid prototyping or users who prefer not to deal with hardware specifics.
  • Developer Mode: For users who understand part of the hardware abstraction, this mode allows programming with thread block tiles. Developers can explicitly control memory allocation strategies (e.g., shared memory usage), tiling strategies (how data is partitioned), and scheduling policies (e.g., pipelining). This mode enables the implementation of complex algorithms like FlashAttention and FlashMLA in a concise manner, often around 50 lines of Python code, striking a balance between control and ease of use.
  • Expert Mode: This mode provides the highest level of control, operating on thread tiles. Users can control per-thread memory allocation, fine-grained synchronization primitives, and even direct thread-level hardware instructions. This mode is intended for highly specialized optimizations, enabling performance extremely close to carefully hand-optimized CUDA implementations, offering the ultimate flexibility for performance-critical scenarios.

The underlying mechanism of TileLang involves automatically lowering these tile tasks, described through the various APIs and programming modes, into efficient hardware instructions. This means developers gain the advantage of explicit control over tile placement and scheduling without needing to manually manage the tedious and error-prone low-level details of instruction scheduling, register allocation, and thread synchronization that characterize raw CUDA programming. The compiler infrastructure handles these complexities, translating the tile-level directives into highly optimized machine code for the target hardware.

Experimental Setup & Results

▶ Watch: Real-world impact and broad industry adoption (5:00)

The evaluation of TileLang's performance and programmability was conducted on an NVIDIA H100 GPU, a cutting-edge accelerator widely used for modern AI workloads. The primary metrics for evaluation were speedup normalized to PyTorch (serving as a common, high-level baseline) and the Lines of Code (LoC) required to implement an operator, which serves as a proxy for development effort and programmability. The ideal outcome, visually represented on a graph, would place TileLang in the "top-left corner": achieving high performance (high speedup) with minimal code (low LoC).

The results unequivocally demonstrated TileLang's ability to consistently hit this "sweet spot," bridging the gap between performance and programmability:

Performance in Standard Kernels:

For widely used and relatively standard kernels, such as Multi-Head Attention (MHA), TileLang proved capable of matching the performance of highly optimized, expert-tuned libraries. Specifically, it achieved performance levels comparable to FlashAttention, a renowned library known for its state-of-the-art efficiency in attention mechanisms. This indicates that TileLang can generate code that is as performant as hand-optimized solutions for foundational AI operations.

Performance in Specialized Kernels:

TileLang's capabilities extended even further to specialized and more complex kernels. For an operator like AttentionSinks, a novel attention variant, TileLang delivered a remarkable over 20 times speedup compared to its implementation in PyTorch. Crucially, this significant performance gain was achieved while maintaining an impressive level of conciseness, with the TileLang implementation being as compact as one written using a high-level compiler like Triton. This highlights TileLang's particular strength in optimizing unique or emerging operators where hand-tuned CUDA might be prohibitively complex, and high-level compilers fall far short on performance.

Programmability and Development Effort:

Throughout the evaluation, TileLang consistently demonstrated its ability to achieve high performance with minimal lines of code. The multi-modal programming approach played a key role here. For instance, in developer mode, complex algorithms like FlashAttention or FlashMLA could be implemented in approximately 50 lines of Python code. This stands in stark contrast to the nearly 500 lines of CUDA code often required for similar operations to achieve peak performance, as mentioned in the background. The visual representation of these results clearly showed TileLang (represented by blue dots) occupying the desirable top-left quadrant, indicating its superior balance of performance and development efficiency compared to both raw CUDA (high LoC, high performance) and high-level compilers like Triton (low LoC, low performance).

In summary, the experimental results on NVIDIA H100 showcased TileLang's effectiveness in delivering high-performance neural kernels across a spectrum of operators. It not only matched the efficiency of highly optimized, expert-level libraries for standard tasks but also provided substantial speedups for specialized kernels, all while drastically reducing the development effort measured in lines of code. This empirical validation underscores TileLang's promise as a practical solution for modern AI kernel development.

Practical Implications

▶ Watch: Summary: TileLang simplifies AI kernel development and optimization (6:00)

TileLang presents transformative practical implications for various stakeholders involved in the AI/ML ecosystem, from individual model builders to large-scale infrastructure teams. Its core value proposition—bridging the gap between programmability and performance—directly addresses critical pain points in the research-to-deployment pipeline.

For practitioners and model builders, TileLang means a significant acceleration in the development and iteration cycle for novel AI operators. Historically, implementing a new, complex operator like a custom attention mechanism or a sparse convolution either meant sacrificing performance by using high-level frameworks or investing immense time and expertise into low-level CUDA optimization. TileLang changes this paradigm. Developers can now implement complex algorithms, such as FlashAttention or FlashMLA, in concise Python code (around 50 lines), achieving performance levels previously only attainable with hundreds of lines of highly specialized CUDA. This empowers researchers to experiment with cutting-edge architectures more freely, knowing that their custom operators can be efficiently executed without becoming a performance bottleneck. The explicit control over tile placement and scheduling allows for targeted optimization of critical sections, leading to faster research-to-prototype cycles.

For ML infrastructure teams and deployers, TileLang offers substantial benefits in terms of hardware compatibility and production readiness. The language has already been adapted to a wide range of hardware backends, including NVIDIA and AMD GPUs, MetaX GPUs, Ascend NPUs, and other platforms like CPUs, WebGPU, and Metal. This broad support simplifies the deployment of AI models across diverse and heterogeneous computing environments, reducing the effort needed to port and optimize kernels for different accelerators. The ability to achieve high performance with a more manageable codebase also translates to easier maintenance, debugging, and integration into existing ML frameworks. Its adoption by industrial players like DeepSeek (for DeepSeek-V32 and their TileKernels library) and Microsoft Research, along with integration into open-source projects like vLLM, SGLang, and FlashLinearAttention, validates its robustness and readiness for real-world production needs. TileLang can streamline the entire research-to-development pipeline, ensuring that cutting-edge models can be deployed efficiently and scalably.

Tradeoffs and Limitations:

While TileLang offers a compelling solution, it also involves certain tradeoffs and has inherent limitations. The most prominent tradeoff is the explicit choice users make regarding programmability versus performance through its multi-modal programming modes. While the beginner mode is entirely hardware-agnostic, achieving the highest performance often requires moving to the developer or expert modes, which demand a greater understanding of hardware abstractions, tiling strategies, and memory hierarchies. This means that while TileLang significantly lowers the barrier to high-performance kernel development compared to raw CUDA, it doesn't entirely eliminate the need for some level of hardware intuition for peak optimization. The learning curve for the developer and expert modes, though mitigated by structured APIs, still exists.

Another implicit limitation is the scope of its applicability. While highly effective for low-level kernel optimization, TileLang is not intended to be a general-purpose programming language for entire AI applications. It focuses specifically on the computationally intensive operators that form the building blocks of neural networks. Its effectiveness is maximized when developing or optimizing custom operators where existing high-level libraries fall short, or where unique hardware features need to be exploited. For standard, well-optimized operations, existing libraries might still be sufficient. Nevertheless, by providing a powerful tool for the most performance-critical components, TileLang significantly enhances the overall efficiency and flexibility of AI system development.

Key Takeaways

  • Bridges Programmability-Performance Gap: TileLang directly addresses the long-standing tension between ease of programming and achieving optimal hardware performance for complex neural network kernels.
  • Tile-Level Explicit Control: It introduces tiles as fundamental units for computation and data movement, providing explicit control through APIs for allocation, operations (e.g., copy, gemm, reduce), and scheduling (e.g., pipelined, parallel).
  • Multi-Modal Programming: TileLang offers Beginner, Developer, and Expert modes, allowing users to choose the level of hardware abstraction and control based on their expertise and performance requirements.
  • High Performance with Conciseness: It achieves performance comparable to expert-tuned CUDA (e.g., matching FlashAttention for MHA) and delivers significant speedups (over 20x for AttentionSinks) while maintaining code conciseness similar to high-level compilers like Triton.
  • Rapid Adoption & Broad Hardware Support: The project has seen rapid adoption, attracting over 55k GitHub stars and 130+ contributors, with support for diverse hardware backends including NVIDIA, AMD, MetaX, Ascend, CPUs, WebGPU, and Metal.
  • Real-World Industrial Impact: TileLang has been adopted by industry leaders like DeepSeek and Microsoft Research and integrated into open-source frameworks (vLLM, SGLang, FlashLinearAttention), demonstrating its practical utility in accelerating the research-to-development pipeline.

About the Speaker(s)

The talk "TileLang: Bridge Programmability and Performance in Modern Neural Kernels" was presented by Yu Cheng. The work is a collaborative effort by a team of researchers including Lei Wang, Yu Cheng, Yining Shi, Zhiwen Mo, Zhengju Tang, Wenhao Xie, Tong Wu, Lingxiao Ma, Yuqing Xia, Jilong Xue, Fan Yang, and Zhi Yang. While specific affiliations were not detailed in the transcript, the comprehensive list of authors indicates a substantial research effort behind this significant contribution to the field of AI/ML systems.

Reviews

→ Top-rated talks at International Conference on Learning Representations 2026

All talks from International Conference on Learning Representations 2026