Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror
×
Intel Linux

How I Booted Linux On an Intel 4004 from 1971 (dmitry.gr) 32

Long-time Slashdot reader dmitrygr writes: Debian Linux booted on a 4-bit intel microprocessor from 1971 — the first microprocessor in the world — the 4004. It is not fast, but it is a real Linux kernel with a Debian rootfs on a real board whose only CPU is a real intel 4004 from the 1970s.
There's a detailed blog post about the experiment. (Its title? "Slowly booting full Linux on the intel 4004 for fun, art, and absolutely no profit.")

In the post dmitrygr describes testing speed optimizations with an emulator where "my initial goal was to get the boot time under a week..."

How I Booted Linux On an Intel 4004 from 1971

Comments Filter:
  • by Rosco P. Coltrane ( 209368 ) on Saturday September 28, 2024 @07:42PM (#64824837)

    It still feels faster than Windows 11 on a 5 year-old machine.

  • How modified was that kernel to boot on a 4 bit processor? It had 2K of ROM, 320 bytes of RAM - how did they squeeze a kernel into a 2K ROM?

    • An unmodified kernel booting on an emulated MIPS R3000. The 4004 asm code is comprised of the MIPS R3000 emulator plus all the peripherals that make up the DECStation2100
      • So he booted a MIPS3100 kernel on an emulator running on a 4004 chip surrounded by tech from 50 years after the 4004 entered the market?

        The kernel code never touched the 4004, the /. Headline is misleading IMHO...

        • You seem to be hung up on the notion that he must have ported the Linux kernel to the 4004 instruction set architecture and memory model because the headline said that it booted on a 4004.

          You should look up the concept of Turing equivalence before spouting off. Of course the kernel code "touched" the 4004. At the end of the day, its ALU performed the logical operations.

      • That laptop looks really familiar, but I can't quite place it. You mind sharing the model?
      • by ls671 ( 1122017 )

        qemu seems to only support the R4000, did you re-use any qemu code?

      • by bobby ( 109046 )

        Incredible project, thank you for documenting it so well and sharing it. It's inspiring, shows what can be done with determination.

        I'm sorry if I missed it in your article, what Linux kernel version did you run?

    • by pz ( 113803 )

      He wrote a CPU emulator that ran on the 4004, emulating a more modern processor that then was used to boot linux. The article is an interesting read and has lots of details.

      I couldn't find the eventual boot time, but he did appear to get it under 5 days.

      • by ls671 ( 1122017 )

        qemu seems to only support the R4000, any insight if he re-used any qemu code?

        • by tlhIngan ( 30335 )

          qemu seems to only support the R4000, any insight if he re-used any qemu code?

          Nope, because the 4004 only has one instruction. And it's coded in that one instruction.

          The 4004 only has a 12K mask ROM and something like 256 byte RAM modules.

          The emulated machine RAM would have to be an external memory chip as well as storage, so you're probably looking at dozens of cycles just to access a byte of emulated memory. And for a chip running at 768kHz, that's probably a huge part of the lack of speed - accessing mem

    • Why? For fun, and learning.
    • by dfghjk ( 711126 )

      Translated: "I don't know how it's done and not going to read the article, so instead I'm gonna take a big shit on /.".

    • Because sometimes, a person gets this question stuck in their head, "I wonder if I could." And that leads to a journey that takes unexpected twists and turns. I personally am impressed, and I think it's cool that this guy even tried it.

  • How many bits does the microcontroller in the attached keyboard have?

  • The 4004 chip costs $250. AMD now sells a (different) 4004 for $150 [amd.com].
  • by 93 Escort Wagon ( 326346 ) on Saturday September 28, 2024 @09:26PM (#64825007)

    That's awesome! It's hilarious watching the hours blow by on the clock in between each individual notification during the boot sequence.

  • by Anonymous Coward

    I couldn't help but think how bloated Linux must be to take days to boot.

  • In the video, parts of the loading sequence appear to do *nothing* at all for hours. I'm pretty sure I would have given up waiting and pulled the plug, thinking that nothing was happening. That's a serious level of patience and commitment.

"How do I love thee? My accumulator overflows."

Working...