From 317595daf2ed2d6ac3b65c5bf088968ed47d81db Mon Sep 17 00:00:00 2001 From: thomasabishop Date: Wed, 1 Nov 2023 10:36:20 +0000 Subject: [PATCH] cpu: further notes --- Computer_Architecture/CPU/Arithmetic_Logic_Unit.md | 2 +- Computer_Architecture/CPU/CPU_architecture.md | 14 +++++++++++++- Computer_Architecture/Memory/Memory.md | 6 ++---- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/Computer_Architecture/CPU/Arithmetic_Logic_Unit.md b/Computer_Architecture/CPU/Arithmetic_Logic_Unit.md index 7f3b77b..c115115 100644 --- a/Computer_Architecture/CPU/Arithmetic_Logic_Unit.md +++ b/Computer_Architecture/CPU/Arithmetic_Logic_Unit.md @@ -8,7 +8,7 @@ tags: [CPU] The ALU is the centerpiece or core of the [CPU](/Computer_Architecture/CPU/CPU_architecture.md) architecture, where the binary calculations occur. All the other components on the CPU chip are appendanges to the execution that occurs within the ALU. -The ALU comprises [logic gates](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md) that execute the instructions passed from memory and where the data stored by the registers is acted upon. +The ALU comprises [logic gates](/Electronics_and_Hardware/Digital_circuits/Logic_gates.md) that execute the instructions passed from memory and where the data stored by the registers is acted upon. A processor's ALU is just a complex combinatorial logic circuit. It executes arithmetic and logical operations on binary numbers and where you will find operations conducted by [full-adders and half adders](/Electronics_and_Hardware/Digital_circuits/Half_adder_and_full_adder.md) etc. diff --git a/Computer_Architecture/CPU/CPU_architecture.md b/Computer_Architecture/CPU/CPU_architecture.md index b5f2682..797e342 100644 --- a/Computer_Architecture/CPU/CPU_architecture.md +++ b/Computer_Architecture/CPU/CPU_architecture.md @@ -20,7 +20,7 @@ The CPU comprises three core components: ## Registers -This is the part of the CPU that stores data. The memory cells that comprise it do not have [capacitors](/Computer_Architecture/Memory/Memory.md) (unlike RAM) so they cannot store very much data but they work faster, which is what is important. +This is the part of the CPU that stores data. The memory cells that comprise it do not have [capacitors](/Computer_Architecture/Memory/Memory.md) (unlike RAM) so they cannot store very much data but they work faster, which is what is important. Because their memory capacity is so small, we measure the size of registers in bits rather than bytes. In terms of speed, registers sit at the top part of the overall [memory hierarchy](/Computer_Architecture/Memory/Memory.md#the-memory-hierarchy). @@ -68,6 +68,18 @@ As the diagram above shows, a cycle is equal to one ascending and one descending ## Processor cores +// TODO: add to dedicated file + +// Add diagram The vast majority of general purpose computers are multi-core. This means that the CPU contains more than one processing unit. They are best thought of as mini-CPUs within the main CPU since they each have the same overall Von Neumann architecture. With Intel processors the two main consumer processors are the i5 and i7. The latter has more cores than the former. Consequently it has faster clock speeds and greater concurrency due to increased threads. + +### Cache access +// See pp.129 + +### History + +The development of multi-core processors emerged because practical limits began to be reached when trying to increase the clock speeds of processors. For a period, increased transistor density meant that there were steady increases in clock speeds. This meant that more instructions could be executed per second. + +When the 3GHz level was reached it became clear that pushing a CPU beyond this led to excessive heat production and the logic gates not being able to keep up at those speeds. Instead of maxing out the clock rate, attention turned to running multiple instructions in parallel in order to increase performance. diff --git a/Computer_Architecture/Memory/Memory.md b/Computer_Architecture/Memory/Memory.md index c054756..fb4fa0a 100644 --- a/Computer_Architecture/Memory/Memory.md +++ b/Computer_Architecture/Memory/Memory.md @@ -62,16 +62,14 @@ Registers are a form of memory that are positioned on the same chip as the CPU. The cache is SRAM memory that is separate from the DRAM memory which comprises the main memory. It exists in order to boost perfomance when executing the read/request cycles of the steps detailed above. -For more detail see [CPU architecture](/Computer_Architecture/CPU/CPU_architecture.md). - -The cache is SRAM memory that is separate from the DRAM memory which comprises the main memory. It exists in order to boost perfomance when executing the read/request cycles of the steps detailed above. - There are two types of cache memory: - L1 cache - Situated on the CPU chip itself + - Fastest to access but stores less - L2 cache - Situated outside of the CPU on its own chip + - Slower to access than L1 but can store more data The L1 cache is the fastest since the data has less distance to travel when moving to and from the CPU. This said, the L2 cache is still very fast when compared to the main memory, both because it is SRAM rather than DRAM and because it is closer to the processor than the main memory.