How I Booted Linux On an Intel 4004 from 1971 (dmitry.gr) 53
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..."
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..."
And the funny thing is (Score:5, Funny)
It still feels faster than Windows 11 on a 5 year-old machine.
Re: (Score:1)
I don't think Windows 11 will even run at all on a 5 year old machine.
Re: (Score:2)
You can coax it into running on older hardware. It might not even run halfway badly (by Windows standards, at least) on older hardware that was at least somewhat cutting-edge when new.
Recently, I've set up some Win11 VMs for testing purposes. They're running on Proxmox on a server that's probably somewhere around 12-13 years old...a pair of Opteron 6272s, IIRC. I didn't do anything special to the image to get it to run. QEMU emulates
Re: (Score:2)
Seriously, why? (Score:2)
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?
Re:Seriously, why? (Score:5, Informative)
Re: Seriously, why? (Score:1)
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...
Re: (Score:3, Informative)
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.
Re: Seriously, why? (Score:2)
Re: Seriously, why? (Score:2)
Re: Seriously, why? (Score:2)
Re: (Score:2)
qemu seems to only support the R4000, did you re-use any qemu code?
Re: Seriously, why? (Score:5, Informative)
Re: (Score:3)
I was already impressed, but now you're just showing off :-)
Thanks for bringing some actual fun tech stories back to Slashdot.
Re: (Score:3)
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?
Re: (Score:3)
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.
Re: (Score:2)
qemu seems to only support the R4000, any insight if he re-used any qemu code?
Re: (Score:2)
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
Re: (Score:2)
Re: (Score:3)
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 /.".
Re:Seriously, why? (Score:5, Insightful)
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.
Re: (Score:1)
Sure but emulating a foreign CPU architecture on a 4 bit machine seems hella crazy slow.
What you want is to ask ChatGPT to design a 32 bit extension to the 4004, emit Verilog, prototype it on a FPGA running many times faster than the original hardware from 1971. LLVM then can bootstrap a c compiler and from there you get Qemu environment in 32bit 4004 FPGA capable of booting the original 4004. Then a reverse JIT can output multi-stage pipelined native 4-bit 4004 instructions to bootstrap the 32 bit Linux en
Re: Seriously, why? (Score:1)
Re: Seriously, why? (Score:1)
A half dozen of those 4004's in parallel with the mips emulation like you described and you have something not unlike a 286?
Re: (Score:2)
Imagine a Beo*BANG*
Os2 warp on 386 (Score:1)
I got my hands on an install set of floppy disks for os2 warp way back when and figured I'd give it a go.
I spent a good part of the weekend swapping disks but eventually I did get through and it booted up. Took about 45 minutes from off to the Home Screen (or whatever they called it).
Os2 wasn't bad especially compared to the alternatives at the time but I was poor and couldn't afford more than the minimum hardware it required. Too bad IBM dropped the ball so hard on this one. It was way better than windo
Re: Os2 warp on 386 (Score:2)
OS/2 had a very productive life in several verticals - insurance and finance, as I recall. It just wasn't WinNT, and (as I recall) needed apps written specifically for it. When the applications were written in-house for internal applications, it was fairly well-regarded. If you hoped to sell your software to others, it was never gonna be successful.
Re: (Score:2)
It seemed to be quite stable as long as it was only doing one or two things, so it made a good dedicated machine for things like phone systems and ATMs (where I encountered it). Its security sucked and my own experience was that it didn't multitask well. NT 3.51 could run circles around it as a general purpose OS and was miles ahead in security when it was released, David Cutler and his team of DEC refugees did a great job on it.
Re: (Score:1)
OS/2 was bad compared to the alternatives at the time, just not compared to ALL the alternatives. IBM didn't "drop the ball on this one", it never had the ball to begin with.
4 bit? (Score:2)
How many bits does the microcontroller in the attached keyboard have?
Re: 4 bit? (Score:2)
At least 8, I suspect...
Cost (Score:3)
Well done, sir (Score:5, Interesting)
That's awesome! It's hilarious watching the hours blow by on the clock in between each individual notification during the boot sequence.
Re: (Score:2)
I am more impressed in the fact that the guy typed ls into the console and finally got the directory listing up 20 hours later.
Linux kernel = bloatware (Score:1)
I couldn't help but think how bloated Linux must be to take days to boot.
Re: (Score:2)
Seriously long pauses, lots of patience (Score:2)
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.
When was the uptime calculated... (Score:3)
It took three hours between typing "uptime" and the uptime being displayed. I'm very curious at what point the uptime was actually calculated.
Fun projects (Score:2)
An acquaintance of mine once told me he was working on a similar(?) project. Emulating DEC PDP-8 with SIMH emulator on a modern computer, then emulating some Linux-supporting machine on the virtual PDP-8, then running Linux on that.
I guess the performance of that Linux would be comparable to what we're talking about in this thread, with the added benefit of not requiring any special hardware. OTOH, if you DO have a real i4004, what better way to make use of it? :)
Imagine⦠(Score:3, Funny)
Imagine a Beowulf cluster of these things.
Does it run Doom?
Re: (Score:2)
Waiting for the *BSD port . . . . .
Re: (Score:2)
Yes, at over 9000spf
Priority Mail (Score:2)
I like the subtle reference to the US postal service :-)
Geniuses that have too much time (Score:2)
Obviously a very smart person that couldn't find a better use of his free time.
You can* run linux on that 1bit paper and pen machine too, if you had the patience of tectonic plates. What I want to convey is that sooner or later we will have to give up on trying to run this or that (linux and DOOM) on hardware that should run appliances or have been obsolete for decades.
I wish one superrich supervillain would kidnap all these stupid smart people, put them on an secluded island and tell them they will get rel
Re: (Score:1)
You want to control others, even by kidnapping and imprisoning them. You imagine yourself as a judge of others worth and works.
People like you are the problem and the threat to humanity.
Re: (Score:2)
Yes. (to the second line).
And maybe you wish to tell others what they want.
Couldn't you tell that my comment was satire when I used an obvious trigger word like "supervillain"?
Re: (Score:1)
they say jokes are half meant.
It turns out people who seem to spend their time on complex pointless things have advanced humanity.
Imagine a patent clerk frittering away his free time for 3 years, after looking at devices and procedures for syncing remote locks, about the nature of time.
Re: (Score:2)
"Those poor poor people" - Galaxy Quest
Ok, Cool, What next? (Score:2)
HP-65? A programmable calculator?
Nice job (Score:2)