Linus Torvalds, during a recent interview, made a characteristically blunt claim: roughly 99% of code submitted to the Linux kernel that appears to be AI-generated is code he considers garbage and rejects.
The internet focused on the number. The number is not the point.
What Torvalds Is Actually Saying
The Linux kernel is not a web app. It is low-level systems code where a bug does not cause a 500 error. It causes a kernel panic, a security vulnerability, or memory corruption that manifests six months later under a specific hardware configuration.
The code that gets merged into the kernel has to be correct at a level that most software does not demand. It has to be readable by maintainers who will look at it ten years from now. It has to handle edge cases that the original developer may not have considered. And it has to work across an enormous range of hardware architectures.
AI-generated code in its current form is pattern-matching on existing code. It produces code that looks plausible. It does not reason about correctness. It cannot think through the hardware edge case, the security implication, or the maintenance burden of a particular implementation choice.
For the kernel, that gap matters enormously.
Where This Does Not Apply
For the vast majority of software most engineers write, the bar is different. A function that parses a JSON response, a CRUD endpoint, a test fixture, a deployment script: these have lower correctness requirements and are easier to verify by inspection.
AI coding tools are genuinely useful for this work. The speed improvement for boilerplate and routine code is real. The productivity numbers from teams using these tools are real.
The mistake is applying Torvalds' judgment about kernel code to all code, or dismissing his concern because you primarily write application code.
The Actual Problem He Is Pointing At
AI-generated code introduces a specific failure mode: code that appears correct but has subtle issues that human review misses because the review is also faster and less careful when the code looks fine on the surface.
This is the real risk. Not that AI writes bad code. It is that AI-generated code changes the review dynamic in ways that let subtle bugs through.
The mitigation is maintaining rigorous code review standards regardless of how the code was produced. Review AI-generated code as carefully as you review human-generated code, possibly more carefully for security-sensitive paths. Use it to go faster on the easy parts, not to skip the hard parts.
Torvalds is not saying do not use AI tools. He is saying do not let them lower your correctness standards. For kernel code, those standards are extremely high. For your code, set the right bar for what you are building.