An AI-assisted kernel contribution

Linus Torvalds has used an LLM coding assistant in work on a Linux kernel patch series, a notable moment for one of the most influential open-source software projects. In the submission accompanying the work, Torvalds said that the code, test programs, review behind the patch list and the first draft of the explanatory text were done with Anthropic’s Claude Code under his direction.

The disclosure does not describe an autonomous system independently changing Linux. Instead, it describes AI assistance used within a developer-led process on a specific technical problem. Torvalds released the work as an eight-patch series on a branch named noref-filemap-read-with-llm in his repository.

The patches target a known Linux performance issue involving small reads from the same cached file on systems with multiple cores and processors. The problem has been known since 2024, and earlier attempts to address it had not solved it.

The bottleneck sits in the page cache

Linux uses its page cache to hold file data in memory. That ordinarily helps programs avoid repeated storage access, but the source of this patch series is a different kind of cost: coordination among processor cores.

When several threads repeatedly make small reads from the same cached file, they acquire and release references to the folio backing that data. Those reference-count updates require atomic writes to a shared cache line. On a multicore system, the resulting traffic can make cores compete over that line and slow down the workload.

The effect can be especially pronounced when the reads are small and frequent. The reported example used eight threads making 16-byte pread() calls against the same page on a four-core, eight-thread Intel Core i7-8565U laptop. In that test, the shared cache line accounted for 99.92% of measured cross-core load activity classified as Hit in Modified cache line, or HITM.

That measurement illustrates why a detail as low-level as a reference-count update can have an outsized impact. The individual reads are tiny, but repeated synchronization over shared memory can become the dominant cost when several execution threads contend for the same underlying data.

Why the disclosure matters

Linux development has rigorous review and testing expectations, particularly for changes that touch memory-management and file-cache behavior. Torvalds’ statement is therefore significant less because AI was involved at all than because he explicitly identified its role in generating code, tests, review material and an initial explanatory draft for a kernel patch series.

The account also offers a more concrete picture of how AI coding tools may be used in systems programming. The assistant was applied to a bounded performance problem with measurable behavior, test programs and a patch-based review process. Torvalds remained the person directing the work and submitting the changes.

That distinction matters for evaluating the claim. The source does not present the patches as a case of a model replacing kernel maintainers. It presents AI as a tool used under the author’s direction while tackling a difficult multicore memory-cache issue.

A test case for AI in infrastructure software

Infrastructure code is a demanding setting for coding assistance. A kernel change must do more than look plausible: it has to account for concurrency, performance characteristics and interactions that can emerge only under specific workloads. In this case, the work is tied to a clearly identified contention mechanism in the page cache and to a concrete benchmark scenario.

The patch series is also an example of AI use extending beyond code completion. Torvalds’ disclosure includes test programs, review work and the first draft of the accompanying text. Those are distinct parts of engineering work, and the statement suggests the assistant was used across them while the technical direction remained human-led.

Whether the approach becomes routine in Linux development will be decided by the project’s normal technical process: examination of the patch set, testing and review by maintainers and contributors. The immediate result is narrower but still consequential. One of open source’s most prominent maintainers has publicly documented using an LLM assistant on a proposed fix for a real kernel performance problem.

For developers watching the practical adoption of AI tools, the episode provides a useful frame. The technology was applied to a specific, measurable systems problem—not as a substitute for engineering accountability, but as an assistant in producing and examining a patch series under the direction of the person responsible for it.

This article is based on reporting by ZDNET. Read the original article.

Originally published on zdnet.com