Before you keep reading...
Runestone Academy can only continue if we get support from individuals like you. As a student you are well aware of the high cost of textbooks. Our mission is to provide great books to you for free, but we ask that you consider a $10 donation, more if you can or less if $10 is a burden.
Before you keep reading...
Making great stuff takes time and $$. If you appreciate the book you are reading now and want to keep quality materials free for other students please consider a donation to Runestone Academy. We ask that you consider a $10 donation, but if you can give more thats great, if $10 is too much for your budget we would be happy with whatever you can afford as a show of support.
6.2. The Processor¶
This basic model of a computer as a processing unit that takes input, communicates with a memory and produces output is known as the von Nuemann architecture after the early computer scientist John von Neumann. In this architecture, the processor itself consists of multiple specialized parts:
The arithmetic logic unit (ALU) - the central processing unit that can perform mathematical and logic operations.
The control unit that directs the movement of instructions in and out of the processor and sends control signals to the ALU to make it perform the correct operation at any given point in time.
The processor registers - small special-purpose storage areas used to store the information the ALU is working with.
The memory unit - not part of the processor - holds both data and instructions (program). To be used, this information must be transferred to registers.
Modern computers add many layers of complexity to this basic model. One such modification seen in the picture above is multiple busses - in the diagram on the previous page and the original von Neumann architecture, there is only one system bus that can carry messages from one component to another. This means that the processor and memory would have to take turns talking: “CPU: Please send me the data at address 1 in memory”; “Memory: OK, the data at 00001 is 01010111.”; “CPU: Please send me the data at address 2 in memory”… Having multiple busses avoids this bottleneck by allowing the CPU communicate the next address it wants at the same time memory sends data back to the CPU.
The arithmetic logic unit is the circuits that can do math and logic. Early processors could only do very simple operations - add or subtract numbers, compare two numbers to see which is larger, and do Boolean logic (to say combine two values with XOR). More complex operations, like multiplication, might have to be performed via simpler operations that the ALU can do directly. Instead of multiplying two numbers, a very simple computer would have to add them repeatedly.
As components became smaller, more and more logic could be built into ALUs - from circuits to do multiplication, to circuits to work with floating-point decimals or process text. Nowadays, almost every processor has multiple ALUs that work in parallel and are often specialized for specific jobs.
Microprocessor Tutorial by Matthew Eastaugh