Unit 1 - Components of a CPU Flashcards

1
Q

Arithmetic and Logic Unit (ALU)

A

This performs any arithmetic calculations (e.g. adding binary) or any logic comparisons (using AND, OR, NOT)

The ALU is made up of several components

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Control Unit

A

This is where instructions are decoded. The CU also controls the data within the CPU and how it moves around

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Program Counter (PC)

A

This stores the address in memory of the next instruction to be fetched

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Accumulator (ACC)

A

This is where values are stored temporarily, either after they’ve been inputted or loaded, or after being calculated in the ALU

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Memory Address Register (MAR)

A

This is where addresses are stored, either for where data is being sent in memory, or where it is being fetched from

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Memory Data Register (MDR)

A

This is where data/instructions are stored, either before it sent to memory, or after being fetched

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Current Instruction Register (CIR)

A

When an instruction has been fetched from memory it is loaded here before being split into opcode and operand. After this, it will be decoded.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What components does the ALU consist of?

A

Arithmetic circuit, Logic circuit, Registers, Status flags, Buses

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Purpose of Arithmetic Circuit

A

This carries out any arithmetic (addition, subtraction, multiplication or division)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Purpose of Logic circuit

A

This carries out operations like AND, OR, NOT, XOR

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Purpose of Registers

A

These are additional registers to those mentioned above and can store data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Purpose of Status flags

A

This includes overflow flags (if the value is too large for the register) or could include a zero flag (to tell if the answer is 0 easily)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Purpose of Buses

A

These are used to transport data around the ALU and to other parts of the CPU

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Buses within the CPU

A

Data bus, Address bus, Control bus

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Data Bus

A

Holds data being sent to/from the CPU and RAM (Read/ Write)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Address Bus

A

Holds addresses being sent to/from the CPU and RAM (Read/ Write)

17
Q

Control Bus

A

Sends Signals to determine whether the other buses are in read or write mode (Sends signals)

18
Q

3 Stages of the FDE

A

Fetch, Decode, Execute

19
Q

Fetch

A

Fetching an instruction from memory - supplying the address and receiving the instruction from memory

20
Q

Decode

A

Decoding the instruction - interpreting the instruction and then reading and retrieving the required data from their addresses

21
Q

Execute

A

Executing the instruction - the CPU carries out the required action

22
Q

Steps of Fetch

A

The PC is loaded with 0

The value from the PC (0) is copied to the MAR

The data from the MAR (0) is sent across the address bus with the instruction to read the data sent across the control bus

The data from that location in memory (0) is sent down the data bus to the MDR

The PC is incremented by 1

23
Q

Steps of Decode

A

The data is sent from the MDR to the CIR where it is split into the opcode and operand

This is sent to the CU to be decoded

24
Q

Steps of Execute

A

Which registers are used here will depend on the instruction being executed

If a value is being inputted the ACC will store the value

If a value is being outputted this will be the value currently in the ACC

If a value is loaded from RAM this will be sent across the data bus from RAM (in the address location in the MAR) to the MDR

If a value is to be stored it will take the value from the ACC, send it to the MDR and then send it across the data bus to RAM (to the address location in the MAR)

If a value is being added to or subtracted from another value

If the LMC code is to branch the comparison will take place in the ALU

25
Q

Factors affecting CPU performance

A

Clock Speed, Number of cores, Cache

26
Q
A