Monday, August 21, 2023

Central processing unit (CPU)


The processor is responsible for logical and computational operations processing data. It is the main part of the computer. Externally, the CPU is a small square board covered with a metal plate at the top. It is necessary to use a metal cover to protect the microchips. The bottom surface includes a large number of pins. The CPU is installed in a socket on the motherboard.

nothing

Any computing device needs a CPU. The CPU is connected to the memory system and the input and output devices.

Components of the processor

The CPU consists of:

  • CPU lid. It ensures ingress protection against small particles and prevents mechanical damage. The lid is made of a material with a high thermal conductivity coefficient. Thus, heat can be extracted from the chip, and the CPU temperature is maintained at a normal range.

nothing

  • The processor crystal.

nothing

All computation operations take place through the processor crystal. The crystal is made of silicon. There can be several crystals.

  • Textolite plate.

All parts of the processor are attached to this plate. The backside of the textolite plate has a lot of pins.

nothing

Integrated graphics processor

Besides the main core, one part of a CPU may be the graphics processor. There is no requirement to have an integrated graphics core, as not every CPU has one. It provides support for graphics.

Integrated graphics are more common in laptops or office desktops, which do not have high graphics requirements.

CPU Throttling

This is a safety mechanism that prevents the CPU from overheating or causing hardware failures during operation. The mechanism activates when the temperature rises to a critical level. As a result, protection is provided by reducing the performance of the core.

Through the BIOS settings, it is possible to forcibly change the trotting settings to overclock the CPU without triggering the protection.

Principle of operation

  1. Sequential data processing. The CPU extracts the necessary data from the program code each time a process is started. This data is loaded into the cache memory.
  2. Caching means using an additional fast memory to store copies of data blocks from the main (RAM) memory. There is a distinction between level 1, level 2, and level 3 caches. Level 1 cache has the shortest access time and smallest size. Layer 2 cache usually has a much longer access time. Layer 3 cache is the largest and quite slow but still much faster than RAM.
  3. Data is divided into two categories when it comes out of the cache: instructions and values. Instructions are redirected to the instruction registers, and values are transferred to the data registers. Registers refer to memory cells (SRAM).
  4. Registers provide service to the ALU (arithmetic and logic unit). The ALU supplies power to the processor and processes the mathematical data.

nothing

The dotted line indicates the CPU.

  • 1. Arithmetic and logic unit (~ 1 KB, 1-2 cycles)
  • 2. Registers (~ 100 KB, 2-3 cycles)
  • 3. Level 1 instruction cache (~ 100 KB, 2-3 cycles)
  • 4. Level 1 data cache (~ 100 KB, 2-3 cycles)
  • 5. Level 2 cache (~500 KB, 3-5 cycles)
  • 6. Level 3 cache (~ 10-15 MB, 3-5 cycles)
  • 7. DRAM - dynamic random-access memory (~ 10 GB, 50-200 cycles)
  • 8. Storage space (~ 1000 GB, 50,000 cycles)
  1. Computation results are divided into two different parts- finished and unfinished, which are sent back to the cache memory.
  2. At the end of the computing cycle, the final result is written to RAM. This is necessary to free up space in the cache buffer, which is needed for new operations.  

Specifications

Clock rate

The rate of cycle transition from one step to the next is determined by the clock. The frequency of the clock pulses per unit time (1 second) is called the clock rate. The measurement unit of the clock frequency is Hertz. The higher the clock rate, the more operations the computer carries out.

When a voltage is applied to the clock resonator, electrical current oscillates due to the action of a quartz crystal. These oscillations are sent to a clock generator, which converts them into pulses that are sent to the data buses.

Bit width

The bit width of the CPU specifies the amount of data processing per clock cycle, which is exchanged between the CPU and the main memory.

The data processing size can be as follows:

  • 1 byte (8 bit);
  • 2 bytes (16 bits);
  • 4 bytes (32 bit);
  • 8 bytes (64 bit).

Electric energy consumption

The electric energy consumption of a processor determines its performance. For example, dual-core processors running at low frequencies consume less energy than an octa-core processor.

Architecture

In terms of hardware, the architecture of a CPU (also called microarchitecture) is the internal design of a CPU of the same generation or model.

In terms of software, the architecture of a CPU is the compatibility with a specific set of instructions (x86), their structure (register set, addressing system), and the way they are implemented (program counter). That is the ability of an x86 compatible program to work on the x86 architecture. At the same time, such a program will not work on other systems (e.g., ARM).

Main CPU architectures:

  • CISC architecture (Complex Instruction Set Computer).
  • RISC architecture (Reduced Instruction Set Computer).
  • MISC architecture (Minimal Instruction Set Computer).
  • VLIW architecture (Very Long Instruction Word).
  • Hybrid architecture.

No comments:

Network Layer

The Network Layer is the third layer of the OSI model. It handles the service requests from the transport layer and further forw...