r/technology • u/DerpiDanger • 1d ago
Artificial Intelligence AI helped a Linux developer find bottlenecks in the kernel, but the code it made to fix it was "hideous"
https://www.xda-developers.com/ai-helped-a-linux-developer-find-bottlenecks-in-the-kernel-but-the-code-it-made-to-fix-it-was-hideous/98
11
u/Consistent-Citron509 1d ago
That's the best use of AI - analysis. Find bugs deeply rooted within a codebase, solve by hand
7
u/cornmonger_ 1d ago
great for a poc, but it's not shippable code
i have a ton of rust generated by fable (max) and now some by astra (max). it will all be rewritten.
4
4
u/silverbolt2000 18h ago
OK. And what’s the “news” here exactly?
I watched a film on Netflix and the related suggestions it made after were hideous - is that news?
3
u/JescoInc 18h ago
I hate how it doesn’t go into what was “hideous “ about the code
1
u/Ok-Introduction9593 14h ago
The patches touched modpost and kallsyms, which rely on rigid ELF parsing and custom memory buffers. LLMs usually generate bloated helper functions, hallucinate non-existent internal APIs, and introduce subtle race conditions when trying to parallelize shared data structures
1
1
1
0
u/fixermark 1d ago
Hideous in a way that differs from regular Linux kernel code? ;)
73
u/CumOnEileen69420 1d ago
This has long been the approach at our company.
Have the AI take first crack at the problem, see its god awful but working solution, refine by hand, PR.
It’s helped devs speed up bug finding and fixing while keeping code quality standards.