The instruction cycle (also known as the fetch–decode–execute the process, or simply the fetch-execute cycle) is the cycle that the central processing unit (CPU) follows from boot-up until the computer has shut down to process instructions. It comprises four main stages: the fetch stage, the decode stage, the read cycle, and the execute stage.
Fetch Stage: The following instruction is fetched from the memory address currently stored in the program counter and stored in the instruction register. At the end of the fetch operation, the PC points to the next instruction that will be read in the next cycle.
Decode Stage: The decoding of instruction is the second phase. In this phase, the CPU determines which instruction is fetched from the instruction and what action needs to be performed on the instruction. The opcode for the instruction is also fetched from memory and decodes the related operation which needs to be performed for the related instruction.
Read Cycle: The reading of an effective address is the third phase. This phase deals with the decision of the operation. The operation can be of any type of memory type non-memory type operation. Memory instruction can be categorized into two categories: direct memory instruction and indirect memory instruction.
Execute Stage: The execution of the instruction is the last phase. In this stage, the instruction is finally executed. The instruction is executed, and the result of the instruction is stored in the register. After the execution of an instruction, the CPU prepares itself for the execution of the next instruction. For every instruction, the execution time is calculated, which is used to tell the processing speed of the processor.
Reference:
- 4 stages of instruction cycle: Instruction cycle in Computer Architecture (2022) CodingHero. Available at: https://codinghero.ai/instruction-cycle-in-computer-architecture/ (Accessed: December 5, 2022).
- Libretexts (2022) 4.1: Instruction cycles, Engineering LibreTexts. Libretexts. Available at: https://eng.libretexts.org/Courses/Delta_College/Introduction_to_Operating_Systems/04:_Computer_Architecture_-_the_CPU/4.01:_Instruction_Cycles (Accessed: December 5, 2022).

Comments
Post a Comment