securityonline.info 15 Oct 2026, 08:15 UTC

Torvalds Tests AI-Written Linux Patch That Triples Read Throughput

Torvalds Tests AI-Written Linux Patch That Triples Read Throughput
CyberSIXT Evidence Panel Source marked as original reporting

LINUS Torvalds has experimented with Claude Code, an AI-assisted coding tool, to craft patches for a key Linux memory management subsystem. The eight patches, produced with Claude Code, aim to speed up small-block reads from the page cache by changing how the kernel tracks memory page references. The work is explicitly described as experimental and not ready for mainline inclusion, with Torvalds retaining architectural oversight and benchmarking the changes on his local hardware.

The patches replace the traditional reference-counter mutation during reads with a Read-Copy-Update approach, delaying page reclamation until after critical read phases. In benchmarks reported by Torvalds, eight-thread workloads on a single laptop saw throughput climb from about 10 million to over 30 million read operations per second, while four-thread runs on dedicated cores rose from around 10 million to 26 million.

Single-thread performance improved more modestly (approximately 8.0–8.9 million reads/s), and inter-core contention, measured by Load HITM events, dropped dramatically (from 30,538 to 101). The tests used an ext4 filesystem on a quad-core, eight-thread laptop with several kernel mitigations disabled.

However, the work introduces trade-offs: increased RAM overhead due to delayed page reclamation, with early tests on a 2 GB system triggering the Out-Of-Memory killer; and a regression in a scenario where a needed user buffer page isn’t resident, raising cycles from roughly 4,100 to 6,500. The patches have not yet undergone full validation (xfstests, KASAN, 32-bit builds) and reside in a separate branch (noref-filemap-read-with-llm) built for Linux 7.3-rc6, not the mainline.

View full article

Article by CyberSIXT