- Linus Torvalds committed 'mm: read from the page cache without folio references' on October 10, 2026, to a branch named noref-filemap-read-with-llm in his kernel tree. It's an eight-patch experiment on 7.3-rc6, not merged into mainline.
- His commit message says 'the code, the test programs, the review behind the list above and the first draft of this text were done with an LLM coding assistant (Claude Code) under my direction,' and that 'the measurements were run on my machine.'
- On his 4-core i7-8565U laptop, 8 threads doing 16-byte reads of one cached page went from 9.9–10.4 million to 30–33 million reads per second. Single-thread gains were about 10%, and the message lists ten open problems.
Contents
On October 10, 2026, Linus Torvalds committed an experimental Linux kernel change to a branch in his own tree. It changes how the kernel reads files that are already cached in memory, so that many threads reading small amounts from the same file stop fighting over a shared counter. Torvalds says Claude Code wrote the code, the test programs and the first draft of the description, "under my direction." On his laptop, one narrow benchmark ran about three times faster.
This story is based on Torvalds' commit message in his torvalds/linux.git repository, the Linux kernel's documentation on AI-assisted contributions, and reporting by Phoronix and Linuxiac, checked October 14, 2026.
The short version
- What: "mm: read from the page cache without folio references," an eight-patch series on Linux 7.3-rc6.
- Where: branch
noref-filemap-read-with-llmin Torvalds' tree. The series description sits in commit4c0f3697118e, on top of the eight patch commits. It's not in mainline. Phoronix spotted the branch on October 11; neither it nor Linuxiac cites a mailing-list posting. - AI's role: Claude Code produced the code, test programs, review and first draft of the text, under Torvalds' direction. "The measurements were run on my machine," he writes.
- Result: 8 threads went from about 10 million to 30–33 million reads per second on a 4-core laptop. It's one microbenchmark, published by the author from his own laptop.
- Status: Torvalds lists ten known problems and asks for review. There's no word on whether it targets Linux 7.4.
What problem does the patch solve?
When a program reads from a file that's already in the page cache, the kernel takes a reference on the folio (the memory structure holding the page) and drops it afterward. Both steps write to the same cache line. "Small reads of one file from many threads contend on the folio refcount," the commit message says, so "every read writes the struct page line twice."
The commit message says a kernel developer named Matthew raised the issue in 2024 "from a customer workload," and links a 2024 mailing-list message for it. The commit gives no surname. On Torvalds' laptop, with 8 threads each doing 16-byte reads of one page, that single line accounted for "99.92% of the load HITMs," the cache-line transfers between cores that show contention.
The series avoids the reference entirely. Freed page cache folios are held until a read-copy-update (RCU) grace period has passed. A lockless reader can then copy data from a page without pinning it, because the page can't be reused under it.
How much faster is it?
All numbers are from Torvalds' commit message and come from one machine: "My laptop only, ext4, mitigations off, CONFIG_HARDENED_USERCOPY off." The laptop has an Intel Core i7-8565U with 4 cores and 8 threads. The test is a "16-byte pread() at offset 0 of a one-page file, one fd per thread." The message also warns that the laptop throttles on temperature, "so compare cost per read, not reads per second." That makes the kernel-cycles column the more reliable comparison.
| Test | Reads per second, before | Reads per second, with series | Kernel cycles per read, before → after |
|---|---|---|---|
| 1 thread | 7.9–8.1 million | 8.8–8.9 million | 452–454 → 408–409 |
| 4 threads, one per core | 8.9–11.6 million | 25–26 million | 1,318–1,401 → 417–438 |
| 8 threads | 9.9–10.4 million | 30–33 million | 2,937–2,975 → 725–726 |
Cross-core cache-line transfers in the 8-thread test fell from 30,538 to 101, as measured with perf c2c. The message notes that this count is from an earlier build of the series.
This is a best case: tiny reads of one hot page with security mitigations turned off. Torvalds writes that "a machine with more CPUs, or more than one socket, should gain more; nothing bigger has been measured." The message also says cost outside the read path "is not measured," and Linuxiac notes the series adds overhead in some cases.
What did Claude Code write, and what did Torvalds do?
The commit message is direct about the split:
"The code, the test programs, the review behind the list above and the first draft of this text were done with an LLM coding assistant (Claude Code) under my direction. The measurements were run on my machine."
So Claude Code produced the patches, the benchmark programs, the review that fed the known-problems list, and a first draft of the description. Torvalds set the direction, the measurements were run on his laptop, and he published the result under his own name: each of the eight patch commits carries his Signed-off-by: line. The message doesn't name the Claude model, show prompts or say how much of the final text he rewrote.
It isn't his first public use of AI on the kernel. In August 2026, Phoronix reported that Torvalds described an Intel Xe graphics driver fix as "a debug session from hell, enormously helped by an AI doing much of the grunt-work." Reports on that fix, including Linuxiac's, don't name the tool.
What problems does Torvalds list?
The section "Known problems, and what I'd like eyes on" lists ten items, including:
- Memory pressure: "The allocator cannot see the waiting pages," so the kernel could make out-of-memory decisions while freed pages wait for a grace period. Matthew's objection was that "it just feels too risky to have so much memory waiting to be reused," and the message calls this "the part of this series that is least solved."
- One more page flag: the message asks whether a bit is free once a folio has left the page cache.
- splice: moving page cache pages into FUSE with
SPLICE_F_MOVE"is gone." - Testing gaps: the series hasn't been run through xfstests (two cases failed with an earlier 2024 version of the idea), lockdep, KASAN, a kernel linked by clang, 32-bit or "any machine but this one."
- Open questions for RCU and scheduler maintainers about grace-period costs.
That reads like an invitation to review, not a merge request.
What is the kernel's policy on AI-assisted code?
The kernel accepts AI-assisted work, with disclosure and human responsibility. Its guidelines for tool-generated content ask contributors to disclose which tools were used, which parts they affected and how the change was tested, and say maintainers may apply extra scrutiny or reject it. The AI coding assistants guide says "AI agents MUST NOT add Signed-off-by tags," that the human must take full responsibility, and that AI help should be marked with an Assisted-by: tag.
Torvalds' series follows those rules. The description commit discloses the tool, its role and the test setup in prose. Each of the eight patch commits ends with an Assisted-by: LLM trailer followed by Torvalds' own Signed-off-by: line, so the human sign-off comes from him, not the agent. The trailers don't name Claude Code; only the description does.
For how Claude Code compares with other agents, see Claude Code vs Codex vs Cursor. For steering an agent on a large codebase, see our guide to writing a CLAUDE.md file, and for long sessions, our explainer on Claude Code's idle compaction.
What's confirmed, reported and uncertain
- Confirmed (commit messages): the date, branch, title, eight-patch structure, base, Claude Code's role in Torvalds' words, the
Assisted-by: LLMandSigned-off-by:trailers on each patch, the benchmark setup and numbers, and the known-problems list. - Confirmed (kernel docs): the disclosure and
Assisted-by:rules. - Reported: Phoronix's October 11 discovery of the branch; Linuxiac's note on overhead in some cases.
- Uncertain: whether the series will be posted for review or merged, which Claude model was used, how much of the code Torvalds changed by hand, and results on larger machines.
About this storyBased on the sources linked below. Editorial standards




