-12
First code coded (lemmy.world)
top 25 comments
sorted by: hot top controversial new old
[-] Digit@lemmy.wtf 1 points 1 day ago

Wanna go back before punchcards?

Wanna go back before the loom?

Wanna go back before knitting?

[-] Simulation6@sopuli.xyz 1 points 1 day ago

I took a NRI learn to computer mail order class back in the 80's. You got to build your own computer as part of the class and you had to manually enter the boot sequence in 8 bit binary to write to the eprom (couple hundred instructions). You could then attach a cassette player to the computer and boot into an OS they sent you. An amazing learning experience.

[-] velindora@lemmy.cafe 66 points 4 days ago
[-] Zorsith@lemmy.blahaj.zone 23 points 4 days ago

scared voice i think i saw a 2

[-] hdsrob@lemmy.world 11 points 4 days ago

There's no such thing as 2.

[-] joyjoy@lemmy.zip 14 points 4 days ago

Its part of the bootstrap paradox. 

[-] dejected_warp_core@lemmy.world 30 points 4 days ago

The answer is: binary, sometimes with electrical switches.

As late as the very early 1980's, the PDP-11 could be started by entering a small bootstrap program into memory, using the machine's front panel:

You toggle the switches to make the binary pattern you want at a specific location in RAM, then hit another button to store it. Repeat until the bootstrap is in RAM, and then press start to run the program from that first address. Said start address is always some hardwired starting location.

And that's a LATE example. Earlier (programmable) systems had other mechanisms for hard-wired or manual input like this. Go back far enough and you have systems that are so fixed-function in nature that it's just wired to do one specific job.

[-] squaresinger@lemmy.world 18 points 4 days ago

Hole punch cards are an automated form of that. Punch the holes manually, feed the deck through an automated feeder.

It's a storage medium that you can write to by hand.

[-] MonkderVierte@lemmy.zip 3 points 3 days ago

Well, punching the computer instead of a bunch of cardboard has it's advantages.

[-] Skullgrid@lemmy.world 15 points 4 days ago
  1. Mechanical engineering during the Ada Lovelace days
  2. Electrical engineering during the Z3/Turing/Manchester Computer/Grace Hopper days
[-] Redkey@programming.dev 10 points 4 days ago

A couple of other commenters have given excellent answers already.

But on the topic in general I think that the more you learn about the history of computing hardware and programming, the more you realise that each successive layer added between the relays/tubes/transistors and the programmer was mostly just to reduce boilerplate coding overhead. The microcode in integrated CPUs took care of routing your inputs and outputs to where they need to be, and triggering the various arithmetic operations as desired. Assemblers calculated addresses and relative jumps for you so you could use human-readable labels and worry less that a random edit to your code would break something because it was moved.

More complex low-level languages took care of the little dances that needed to be performed in order to do more involved operations with the limited number of CPU registers available, such as advanced conditional branching and maintaining the illusion of variables. Higher-level languages freed the programmer from having to keep such careful tabs on their own memory usage, and helped to improve maintainability by managing abstract data and code structures.

But ignoring the massive improvements in storage capacity and execution speed, today's programming environments don't really do anything that couldn't have been implemented with those ancient systems, given enough effort and patience. It's all still just moving numbers around and basic arithmetic and logic. But a whole lot of it, really, really fast.

The power of modern programming environments lies in how they allow us to properly implement and maintain a staggering amount of complex minutiae with relative ease. Such ease, in fact, that sometimes we even forget that the minutiae are there at all.

[-] Mikina@programming.dev 4 points 3 days ago* (last edited 3 days ago)

To add to this excelent answer, one thing that made me really understand and realize quite a lot about how do CPUs actually work, and why is most of the stuff the way it is, was playing through the amazing "Turing Complete" puzzle game.

The premise is simple - you start with basic AND/OR/NOT gates, and slowly build up stuff. You make a NAND, and then can use your design. Then you make a counter, and can use that. The one bit memory. An adder. A multiplexer. All using the component designs you have already done before.

Eventually, you build up to ALU and RAM, until you end up with a working CPU. Later levels even add creating your instruction sets and assembly language, but I never really got far into that part.

It's a great combination of being a puzzle game - you have clear goals, and everything is pretty approachable and very well paced. I had no idea how is memory done on the circuit level, but the game made me figure it out, or had hints when I got stuck.

And seeing a working CPU that you've designed from scratch is pretty cool, but most importantly - even though I've had courses on hardware, CPU architecture and the like on college, there's a lot of stuff I kind of understood, but it never really clicked. This game has helped tremendously in that regard, and it was full of "aha moments" finally connecting a lot of what I know about low-level computing.

I'm not even into puzzle games that much, but this was just a joy to play. It was so fun I sat through it in one session, up until I got to a complete CPU. I very highly recommend it to anyone.

[-] trigg@lemmy.world 1 points 1 day ago

Thanks for this suggestion. I bought it last night and then forgot to sleep. Thoroughly enjoying wiring up my own opcodes.

[-] drosophila@lemmy.blahaj.zone 2 points 3 days ago* (last edited 3 days ago)

The microcode in integrated CPUs took care of routing your inputs and outputs to where they need to be, and triggering the various arithmetic operations as desired.

In the transition from plugboards to programmed sequence control the thing that took over the task of routing values between registers, through the ALU, and to/from IO ports was the control unit. Microcode being one way to implement functionality in the control unit.

One other approach was to use what was basically a finite state machine, implemented physically in-circuit. The output of that FSM was fed into a series of logic gates along with the current instruction value, with the output of that combination being connected to the control lines of the various CPU elements. Thus the desired switching/routing behavior occured.

Modern chips are really complicated hybrids of microcode and a ton of interacting finite state machines. Especially in x86 complex or less commonly used instructions will be implemented in microcode, whereas simple/common instructions will be implemented by being "hardwired", somewhat similar to the FSM technique described above (although probably more complicated).

[-] Kolanaki@pawb.social 8 points 4 days ago

They just typed 1s and 0s until something happened.

[-] ryokimball@infosec.pub 6 points 4 days ago

I'm imagining compilers evolving from digital primordial goo.

[-] squaresinger@lemmy.world 4 points 4 days ago

That would be fun, making a genetic algorithm-based compiler.

[-] ulterno@programming.dev 4 points 4 days ago

There is something to using the 8085 educational kit and feeding the values into RAM, via the HEX keyboard, that lets you connect the dots pretty easily.

[-] bitcrafter@programming.dev 4 points 4 days ago
[-] ekZepp@lemmy.world 2 points 4 days ago
[-] desmosthenes@lemmy.world 1 points 4 days ago

compilers were pretty early on

this post was submitted on 31 Dec 2025
-12 points (41.9% liked)

Programmer Humor

28225 readers
1225 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS