Fetch decode Execute Flashcards

Memorize what happens in each of the stages (4 cards)

1
Q

What happens in the fetch stage of the cycle

A

1.Program Counter (PC): The PC holds the memory address of the next instruction to be executed.
2.Memory Address Register (MAR): The contents of the PC (the address of the instruction) are copied to the MAR.
3.Address Bus: The address in the MAR is placed on the address bus, which sends the address to the memory location where the instruction is stored.
4.Data Bus: The instruction (data) at that memory location is read and placed on the data bus.
5.Memory Data Register (MDR): The instruction from the data bus is copied into the MDR.
6.Control Unit (CU): The CU then takes the instruction from the MDR and prepares it for decoding and execution.

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

What happens in the decode stage of the cycle

A
  1. Obtain the instruction:
    The CPU receives the instruction from the Current Instruction Register (CIR), which holds the instruction fetched from memory.
  2. Identify the opcode:
    The CPU determines the type of operation (e.g., add, subtract, move) by analyzing the opcode part of the instruction.
  3. Identify operands:
    The CPU identifies the operands, which are the data or memory locations the instruction will operate on.
  4. Interpret the instruction:
    The CPU interprets the instruction based on the opcode and operands, determining what actions need to be taken.
  5. Prepare for execution:
    The CPU prepares for the execution stage by setting up the necessary registers, memory addresses, and control signals.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What happens in the execute stage of the cycle

A

The CPU receives the decoded instruction and performs the necessary operations, for example if it is mathematical, it uses the ALU, if instruction requires reading/writing data in memory, it uses the memory acess register

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

Describe the role of the cache memory in the computer

A

It is a high speed memory that aids in the controlling of instructions, and the movement of data around the computer.

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