← All posts
Tech · Aug 10, 2026 · 20 min

Part II: The 0s and 1s Inside CPUs and GPUs

Before we compare CPUs and GPUs, we need to understand what a core is doing from the inside. This part looks at instruction memory, the program counter, the instruction register, the control unit, the register file, and the ALU.

Note: This post follows my own attempt to understand how CPUs and GPUs work and why they are built differently. Some explanations are simplified, and any mistakes are part of the learning trail.

In Part I, we started with the building blocks of CPUs and GPUs, including silicon, charge, transistors, logic gates, and circuits. That journey showed that modern chips are built from billions of tiny switches turning ON and OFF. But switches alone are not enough. They have to be arranged into larger systems that can store bits, move bits, transform bits, and follow instructions. Before we compare CPUs and GPUs, we need to understand one of the most important systems built from those switches, the core.

A core is where tiny switches begin to act like a machine that can follow instructions.

When we say that a CPU has “cores” or a GPU has “many cores,” the word can sound simple. But what does it actually mean? In this context, a core is a small instruction-following system built inside a silicon chip. A chip is a piece of silicon that contains electronic circuits, and this system is one of the larger structures made from those circuits. It takes in instructions, works through them, and produces results. An instruction is a small command, such as set this value, add these two numbers, compare these values, load this data, or store this result.

At the micro level, a core is still built from the same pieces we discussed in Part I. Transistors act as tiny switches. Logic gates combine those switches into rules. Wires carry high and low voltages, which the chip treats as 1s and 0s. Tiny storage circuits hold those 1s and 0s long enough for the core to use them. So a core is a larger arrangement of the same small ideas: switches, gates, wires, and stored bits.

One important part is instruction memory. In this simplified picture, instruction memory is the storage area that holds the program’s instructions. Each instruction is stored as bits, not as words. For example, one bit pattern may tell the core to set R1 to 5, while another bit pattern may tell it to add R1 and R2. The first part of the bit pattern usually tells the core what kind of instruction it is, and the remaining bits can say which values or registers are involved. At the circuit level, this memory is made from many tiny storage cells built from transistors. Each cell holds one bit, either 0 or 1. When the core fetches an instruction, the selected bits leave memory and enter the core as high and low voltages, just like the voltage levels from Part I.

The program counter is a small storage circuit that keeps track of where the core is in the program. It holds a number, and that number is the address of the instruction the core should read next. An address is just a location number. For example, if the program counter holds 2, the core knows to fetch the instruction stored at location 2. After that instruction is fetched, another small circuit usually adds 1 to the program counter, so it points to the next instruction.

So the program counter is like a bookmark for the program, but physically it is not a paper bookmark. It is a group of stored bits that can be updated by logic gates. Those stored bits say, “fetch the instruction from this location next.”

The instruction register is another small storage circuit. When an instruction is fetched from instruction memory, its bits are copied into the instruction register. This gives the core a stable copy of the current instruction while it works on it.

A useful way to imagine it is like placing the current recipe step on the kitchen counter before doing it. The full recipe may still be in the book, but the step you are working on is held in front of you. At the circuit level, the instruction register is made from transistor storage circuits that keep each bit stable as a 0 or 1 until the next instruction replaces it.

The control unit is the part that figures out what the current instruction means. It does not read the instruction like a person reads a sentence. Instead, the bits from the instruction register enter a network of logic gates. Those gates are wired to respond to specific bit patterns.

If the instruction pattern means ADD, the control unit sends high voltages along the paths needed for addition. If the instruction pattern means SET, it sends high voltages along a different set of paths. These high and low voltages are called control signals. A control signal is simply a voltage that tells another part of the core what to do, such as read a register, write a result, or use the ALU for addition.

So the control unit is like a decision-making circuit. It looks at the instruction’s bit pattern and turns on the right paths inside the core.

The register file is a tiny, very fast storage area inside the core. It holds values the core is currently working with, such as R1, R2, and R3. Each register is a small row of stored bits. For example, R1 may hold the bit pattern for 5, and R2 may hold the bit pattern for 3.

To read a register, the control unit uses selection circuits to choose which row should send its bits out. To write into a register, it chooses which row should accept new bits. This connects directly back to Part I: transistors can act like switches, so they can open or block paths between stored bits and the wires that carry them.

In other words, the register file is not just “memory.” It is memory with tiny transistor switches that decide which stored values are allowed to move.

The ALU, or arithmetic logic unit, is the part that performs operations on bits. It can add numbers, compare values, and apply simple logic operations. The ALU is made from logic gates, just like the gates we built up to in Part I.

An adder inside the ALU can be built from AND, OR, and NOT gates arranged so that they add binary digits. Other gate arrangements can check whether two values are equal, flip bits, or combine bits using operations like AND and OR. The control unit tells the ALU which operation to perform, and the ALU turns the input bits into output bits.

So when the core adds two numbers, it is not doing math in the human sense. It is sending bit patterns through a carefully arranged network of gates. The output bit pattern is the answer.

So a core is not one single circuit. It is a small instruction-following system. Instruction memory provides the next command. The program counter keeps track of where that command is. The instruction register holds the current command steady. The control unit decides what the command means. The register file stores the values being worked on. The ALU performs the calculation or logic. Together, these parts let the core fetch an instruction, understand it, run it, and store the result.

Once these parts are clear, we can watch them work together as one simplified core.

At this point, the core is no longer a black box. It is not one single circuit, and it is not magic. It is a carefully arranged system of storage circuits, selection circuits, control circuits, wires, and logic gates. Some parts remember bits. Some parts move bits. Some parts decide what the bits mean. Some parts transform bits into new bits. Together, they create a small instruction-following system.

There is a quiet kind of beauty in that. Nothing inside the core understands a program the way we do. The instruction memory does not know it is holding a command. The program counter does not know it is keeping the core’s place in the program. The ALU does not know it is doing arithmetic. Each part only responds to voltages, switches, and patterns of bits. Yet when these tiny parts are arranged together, the chip begins to move with purpose. One instruction leads to the next, one result becomes the input for another, and stillness becomes computation. Now that we have looked inside a core, we can finally return to the question waiting above it all: why do CPUs and GPUs use these cores so differently?

سمیع