Tech media LWN reports that Linux creator Linus Torvalds has pushed a new branch named noref-filemap-read-with-llm in his personal Git repository, officially delivering his first kernel patch series developed with the assistance of a large language model. This developer, who normally maintains code only on the master branch, rarely opened an experimental branch with the "llm" suffix, and the behind-the-scenes helper was Anthropic's AI coding tool Claude Code.
The patches Torvalds submitted to that branch on October 13, with the subject "improving page reference count scalability", target a long-standing ailment of Linux memory management. When multiple threads simultaneously read the same file at high frequency but in small amounts, the traditional mechanism repeatedly triggers reference count updates to the page cache, causing multi-core CPUs to fall into severe race contention. He admitted that the core code, test programs, vulnerability review, and even the first draft of the announcement documentation of this patch series were all completed in collaboration with Claude Code under his personal guidance.
8-thread real-world test: throughput triples, clock cycles cut by seventy percent
After turning off some local security protections, Torvalds ran a test workload with 8 threads concurrently reading the same file: read throughput jumped from the original 9.9 million to 10.4 million operations per second to 30 million to 33 million, an improvement of about 3x; the kernel clock cycles consumed by a single read also plunged from about 2,950 to 725.
However, the patches currently remain on the experimental branch and have not yet been merged into the official Linux 7.4 mainline. More notably, in the recent Maintainers Summit and a cleanup of the assoc_array codebase elsewhere, Torvalds likewise used an LLM to refactor old code, uncovering in one go 3 hidden bugs that had lurked in Linux systems for 13 years, traceable back to the first commit in 2013 — AI-assisted kernel writing seems to have moved from "speeding things up" to "minesweeping".