Difference between revisions of "CPU"

From UNSW PCSoc Wiki
Jump to navigation Jump to search
m
Line 1: Line 1:
A Central Processing Unit (CPU), is a computer component that performs the bulk of computational work for the PC.  
+
The Central Processing Unit (CPU), is a computer component that performs the bulk of computational work for the PC. It does this by carrying out instructions in a computer program. Due to its role, it is often described as the "brain" of a computer.
  
Due to its role, it is often described as the "brain" of a computer.
+
A good CPU is essential for workstation tasks such as video editing and music production!
  
==Function==
+
==Intel vs AMD==
A CPU's purpose is to compute things for the computer. It does this by following the set of instructions (see the Instruction Sets section below) detailed in a computer program.
+
I'll do this later, or someone else can make a start - Sabine
  
In current times CPUs are not just processing units but also handle other tasks. One such controller that has been moved onto the CPU is a memory controller.
+
==Cores & Multithreading==
 +
Most modern day CPUs are multi-core. Having more than one core allows the system to run multiple tasks at the same time.
  
==Instruction Sets==
+
This can be better explained using an analogy. Imagine that a core is a worker in a factory. In this case the worker needs to do multiple tasks in the factory so they rotate around doing each task so they do not spend too much time on a single task. If we were to add more workers we would be able to do more work if their were tasks the other user could do.
A CPU follows instructions which it uses to carry out arithmetic and logical operations, conditional subroutines and memory operations, amongst many others. These instructions are stored in the form of binary (1s and 0s) bytes within memory and generally consist of an opcode (the name of the instruction, such as add or store to memory) and operands (the data the instruction should be performed on, such as the number stored in a certain memory address).
 
  
All programs get compiled into instructions which the CPU executes. Note that Operating Systems are also programs and thus are just instructions as well.  
+
As most games only utilise one or two threads, having more cores does not normally impact gaming performance significantly. An i5 does not perform much worse in gaming than an i7, for example.
  
The reason this is important is that you can only run programs that are compiled for your instruction set.
+
Workstation tasks however do benefit greatly from having more cores!
 
 
The instruction set which Intel and AMD CPU use is called x86 and x86_64 (a 64 bit extension of the original x86). Another common instruction set is ARM which is is used by most popular smartphone cpus.
 
 
 
Windows RT and the surface RT is an example of an operating system which which runs on ARM. As the operating system is for ARM, it is unable to run win32 applications (.exe) programs. This is the reason why you need to care about the instruction set.
 
  
 
==32 Bit vs 64 Bit==
 
==32 Bit vs 64 Bit==
Line 25: Line 21:
 
Higher bit systems and programs are able to address more memory. 32 bit programs for example are restricted to 4GB of memory, whereas 64 programs can access 16 EXABYTES!!! of memory. Far more than any modern system would have.
 
Higher bit systems and programs are able to address more memory. 32 bit programs for example are restricted to 4GB of memory, whereas 64 programs can access 16 EXABYTES!!! of memory. Far more than any modern system would have.
  
==Architecture==
+
==Sockets & Chipsets==
Architecture is the implementation of a CPUs instruction set. In simple terms, it is the design of the CPU internally. Different architectures often differ in ways such as number of cores, registers, cache size and implementation etc.
+
A CPU must integrate into a motherboard. The socket is the actual pin layout which the CPU connects to. Different sockets will accept different CPUs, for example the TR4 socket will accept Threadripper 1 and Threadripper 2 CPUs.
  
Architectures are often given names. When looking at Intel's CPU releases you have Skylake, Haswell and Coffeelake, amongst others. On the AMD side your may hear about Zen, Bulldozer and Piledriver. What are these referring too?
+
Intel has a tendency to change sockets with every new CPU generation, requiring consumers to buy a new motherboard when they wish to upgrade their Intel CPU. AMD in comparison tends to change sockets every 3 or 4 generations, allowing consumers to upgrade to a new AMD CPU without needing to buy a new motherboard.
  
==Cores & SMT==
+
==Instruction Sets (for technical people)==
Most modern day CPUs are multi-core. Having more than one core allows the system to run multiple tasks at once without having to switch context.
+
A CPU follows instructions to perform maths and do things when certain conditions are met (such as if statements and loops), amongst other things. These instructions are stored in the form of binary (1s and 0s) in memory and consist of an opcode (the name of the instruction, such as add or store to memory) and operands (the stuff the instruction should be performed on, such as two numbers).
  
This can be better explained using an analogy.
+
All programs get compiled into instructions which the CPU executes. Note that operating systems are also programs and thus are just instructions as well.
Imagine that a core is a worker in a factory. In this case the worker needs to do multiple tasks in the factory so they rotate around doing each task so they do not spend too much time on a single task. If we were to add more workers we would be able to do more work if their were tasks the other user could do.
 
  
SMT stands for Simultaneous Mutlithreading.  
+
The reason this is important is that you can only run programs that are compiled for your instruction set.
  
==Sockets==
+
The instruction set which Intel and AMD CPU use is called x86 and x86_64 (a 64 bit extension of the original x86). Another common instruction set is ARM which is is used by most popular smartphone cpus.
A CPU must integrate into a motherboard. The socket/package is the actual pin layout which the CPU will communicate through to the motherboard. Depending on the socket it will accept different CPUs, for example the TR4 socket will accept Threadripper 1 and Threadripper 2 CPUs.
 
  
Intel has a tendency to change sockets with every new CPU generation, requiring consumers to buy a new motherboard when they wish to upgrade their Intel CPU. AMD in comparison tends to change sockets every 3 or 4 generations, allowing consumers to upgrade to a new AMD CPU without needing to buy a new motherboard.
+
Windows RT and the surface RT is an example of an operating system which which runs on ARM. As the operating system is for ARM, it is unable to run win32 applications (.exe) programs. This is the reason why you need to care about the instruction set.
  
 
{{Parts}}
 
{{Parts}}

Revision as of 22:38, 1 March 2019

The Central Processing Unit (CPU), is a computer component that performs the bulk of computational work for the PC. It does this by carrying out instructions in a computer program. Due to its role, it is often described as the "brain" of a computer.

A good CPU is essential for workstation tasks such as video editing and music production!

Intel vs AMD

I'll do this later, or someone else can make a start - Sabine

Cores & Multithreading

Most modern day CPUs are multi-core. Having more than one core allows the system to run multiple tasks at the same time.

This can be better explained using an analogy. Imagine that a core is a worker in a factory. In this case the worker needs to do multiple tasks in the factory so they rotate around doing each task so they do not spend too much time on a single task. If we were to add more workers we would be able to do more work if their were tasks the other user could do.

As most games only utilise one or two threads, having more cores does not normally impact gaming performance significantly. An i5 does not perform much worse in gaming than an i7, for example.

Workstation tasks however do benefit greatly from having more cores!

32 Bit vs 64 Bit

You might see 32 or 64 bit specified on the end of some installer filenames. This is important as 64 bit programs cannot be run on 32 bit systems.

Higher bit systems and programs are able to address more memory. 32 bit programs for example are restricted to 4GB of memory, whereas 64 programs can access 16 EXABYTES!!! of memory. Far more than any modern system would have.

Sockets & Chipsets

A CPU must integrate into a motherboard. The socket is the actual pin layout which the CPU connects to. Different sockets will accept different CPUs, for example the TR4 socket will accept Threadripper 1 and Threadripper 2 CPUs.

Intel has a tendency to change sockets with every new CPU generation, requiring consumers to buy a new motherboard when they wish to upgrade their Intel CPU. AMD in comparison tends to change sockets every 3 or 4 generations, allowing consumers to upgrade to a new AMD CPU without needing to buy a new motherboard.

Instruction Sets (for technical people)

A CPU follows instructions to perform maths and do things when certain conditions are met (such as if statements and loops), amongst other things. These instructions are stored in the form of binary (1s and 0s) in memory and consist of an opcode (the name of the instruction, such as add or store to memory) and operands (the stuff the instruction should be performed on, such as two numbers).

All programs get compiled into instructions which the CPU executes. Note that operating systems are also programs and thus are just instructions as well.

The reason this is important is that you can only run programs that are compiled for your instruction set.

The instruction set which Intel and AMD CPU use is called x86 and x86_64 (a 64 bit extension of the original x86). Another common instruction set is ARM which is is used by most popular smartphone cpus.

Windows RT and the surface RT is an example of an operating system which which runs on ARM. As the operating system is for ARM, it is unable to run win32 applications (.exe) programs. This is the reason why you need to care about the instruction set.