What will happen if the Linux kernel starts having AI generated code in it?

  • cecilkorik@piefed.ca
    link
    fedilink
    English
    arrow-up
    9
    ·
    15 hours ago

    Code is code. “Hello, my name is Fred.” is an equally valid sentence whether a human wrote it or an AI wrote it. It doesn’t contain some magical AI pollution that makes it different from the normal human-written sentence “Hello, my name is Fred.”

    AI written code, especially in largely “vibe coded” projects are written by people with zero experience in maintaining or developing software. They don’t understand what bad code is. They have no way of recognizing it when they see it. If AI writes bad code that works, it is indistinguishable from good code that works, from the perspective of somebody who knows nothing about coding, which an increasing amount of code and an increasing number of projects are submitted to and written by.

    The problem with AI is that it cannot be trusted to write good code. This is a problem when people who don’t know any better start trusting it to write code. It sometimes, often, writes REALLY BAD CODE. Code with GIANT security flaws. Code that is unmaintainable, that does not fit with the rest of the code or the goals of the project.

    The Linux kernel famously does not trust anyone except Linus. It has a very thorough process for reviewing all code that is suggested for inclusion, and all code is reviewed in extensive and sometimes expletive-laden detail, by Linus himself if it gets that far.

    Bad AI code will be caught by the same process that catches bad human written code (which there is also a fair bit of).

    Good AI code will be fine, because it gets reviewed by the same process that reviews good human written code, to ensure that it is, in fact, good code. Who actually wrote it is largely irrelevant, as long as the code is high quality and written in a safe, reliable way, because good code is still good code.

    Vibe code, on the other hand, is not always good code. Sometimes it is good enough code. Often it is atrocious code. It is not a substitute for experienced software developers, if anything, it necessitates them more. Reviewing complex AI generated code quickly and accurately enough to keep up with the relentless onslaught of even more generated AI code is no minor feat, and skilled, experienced software developers are required to accomplish this.