Triton 3.8: A Compiler for GPU Kernels That Skips the CUDA Boilerplate
Development repository for the Triton language and compiler
At a glance
- What is it?
- Triton is an open-source language and compiler for writing custom deep-learning primitives with higher productivity than CUDA and more flexibility than fixed DSLs. This review covers installation, architecture, limitations, and who should adopt it.
- Who is it for?
- Adopt Triton if you write custom GPU kernels for deep learning and want a higher-level language than CUDA, especially if you already use PyTorch and need to target NVIDIA or AMD GPUs. Do not adopt it if you need a stable LLVM API, if you cannot tolerate a build that pins to a specific LLVM revision, or if you require a fully turnkey test suite.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository last received commits 1 day ago.
- What is it written in?
- Mainly MLIR, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on September 14, 2026, and from our analysis. They are not legal advice.
DEEP OPEN-SOURCE ANALYSIS
What Triton Solves and Who It Is For
Triton is a language and compiler for writing custom deep-learning primitives. The README states its aim: provide an open-source environment to write fast code at higher productivity than CUDA, but with higher flexibility than other existing DSLs. The target audience is engineers and researchers who need custom kernels for neural network operations that are not covered by existing libraries. Instead of writing raw CUDA C++ with explicit thread management and memory coalescing, you write in a Python-like language that the compiler translates into GPU code. The project traces back to a 2019 MAPL publication, which describes the tiled computation model. If you have ever spent days debugging a CUDA kernel, Triton is designed to shorten that cycle.
The Tiled Computation Model and Compiler Pipeline
The core idea, as described in the MAPL2019 paper, is tiled neural network computations. You write programs that operate on blocks of data, not individual threads. The compiler takes care of mapping those blocks to threads and memory hierarchy. The repository is written primarily in MLIR, which suggests the compiler uses MLIR as its intermediate representation. The README mentions that Triton uses LLVM to generate code for GPUs and CPUs. The pipeline likely goes from the Triton language frontend to MLIR, then to LLVM IR, and finally to target machine code. The interpreter mentioned in the README allows running Triton puzzles without a GPU, which is a useful debugging feature. This design separates the user-facing language from the backend, allowing the same source to target different hardware.
Installation: Pip Wheels and Source Builds
The quickest way to get Triton is via pip: `pip install triton`. Binary wheels are available for CPython 3.10 through 3.14. For development or custom LLVM needs, you clone the repository and install from source. The README gives a straightforward recipe: clone, create a virtualenv, install build-time dependencies from `python/requirements.txt`, then run `pip install -e .`. The build downloads a prebuilt LLVM by default, but you can build LLVM from source. The critical detail is that LLVM does not have a stable API, so Triton only works with a specific LLVM revision. You find that revision in `cmake/llvm-info.json` under the `llvm_hash` field. The README even includes a humorous step: 'Grab a snack, this will take a while' when building LLVM from source. For faster builds, you can set `TRITON_BUILD_WITH_CLANG_LLD=true` and `TRITON_BUILD_WITH_CCACHE=true`. Memory constraints can be managed with `MAX_JOBS`.
Configuration Knobs and Hacking the Backend
Triton exposes a set of configuration knobs, listed in `python/triton/knobs.py`. You can set these knobs directly in Python or via environment variables. The README gives one example: `MLIR_ENABLE_DUMP=1` dumps the IR before every MLIR pass. This is invaluable for compiler developers. The README also mentions that the build system generates a `compile_commands.json` file, which you can point VSCode's C/C++ extension at for IntelliSense. That file is produced under the build directory, and the README provides a `find` command to locate it. This level of detail suggests the project is serious about supporting contributors who want to hack on the backend. However, the README does not list all knobs, so you must inspect the source to understand the full set.
Testing: Not Turnkey, and GPU Requirements
The README is candid: there is no turnkey way to run all Triton tests. You can run `make dev-install` for one-time setup, which reinstalls local Triton because torch overwrites it with the public version. Then `make test` runs all tests, but requires a GPU. If you do not have a GPU, `make test-nogpu` runs tests without one. This is a genuine limitation. If you are evaluating Triton for a production environment, you need to budget time for test setup and ensure you have GPU access. The lack of a single command to run the full test suite is a friction point, especially for CI pipelines. The README does not describe the test framework or how to run individual tests, so you will need to explore the repository structure.
Limitations and Failure Modes
The most significant limitation is the tight coupling to a specific LLVM revision. The README states plainly: 'LLVM does not have a stable API, so the Triton build will not work at an arbitrary LLVM version.' This means that if you need to upgrade LLVM for other reasons, you cannot simply point Triton at the new version. You must either use the prebuilt LLVM that Triton downloads or build the exact revision specified in `llvm-info.json`. This is a maintenance burden for teams that manage their own LLVM toolchain. Another limitation is that the source build is resource-intensive. The README mentions running out of memory and suggests limiting `MAX_JOBS`, but that only mitigates the problem. Also, the test suite is not turnkey, as noted. For users who just want to run kernels, the pip wheel is fine, but for those who need to modify the compiler, the setup cost is high.
Alternatives: CUDA and Other DSLs
The primary alternative is writing kernels directly in CUDA C++. CUDA gives you full control over thread scheduling and memory, but at the cost of productivity. Triton's value proposition is that you write at a higher level and let the compiler handle the low-level details. Another alternative is using domain-specific languages like Halide or TVM, which also aim to separate computation from implementation. However, the README claims Triton offers higher flexibility than 'other existing DSLs.' The difference in approach is that Triton uses a tiled model specifically designed for neural network computations, whereas CUDA is a general-purpose GPU language and TVM focuses on whole-graph optimization. If you need fine-grained control over every instruction, CUDA remains the choice. If you want to write a single kernel without worrying about thread indexing, Triton is the alternative.
Maintenance and Upgrade Cost
Triton is under active development, with releases v3.7.0, v3.7.1, and v3.8.0 in 2026. The last push to the main branch was August 28, 2026. This cadence means you can expect regular updates, but also that APIs may change between versions. The README does not provide a migration guide, so upgrading from one minor version to another may require checking release notes. The build system uses a pinned LLVM hash, which means each Triton release may require a different LLVM build if you build from source. That is a concrete upgrade cost. The license is MIT, which is permissive and imposes few restrictions on commercial use, but you should verify the license implications for your specific use case. The project is not archived, which is a positive sign for long-term maintenance.
Editorial conclusion
Adopt Triton if you write custom GPU kernels for deep learning and want a higher-level language than CUDA, especially if you already use PyTorch and need to target NVIDIA or AMD GPUs. Do not adopt it if you need a stable LLVM API, if you cannot tolerate a build that pins to a specific LLVM revision, or if you require a fully turnkey test suite. Before committing, verify that the nightly wheel supports your Python version and GPU target, and check the llvm_hash in cmake/llvm-info.json to understand which LLVM version you are tied to. The project is actively maintained with regular releases, but the source build is not for the faint of heart.
Community notes