ComputingRevision.net

1.1.1a The Purpose of the CPU

What is a Computer?

Before looking at the role of the CPU (central processing unit), it is useful to take a look at what a computer actually is.

A computer takes input, processes it, and delivers the output (results) of processing.

The CPU performs the processing part.

What is the CPU?

CPU and brain

The CPU (central processing unit) can be thought of as the computer's brain.

Within the input – process – output procedure, the CPU…

  • Receives instructions and data from RAM.
  • Processes those instructions and data
  • Send the results of the processing back to RAM.

It does this using the fetch – decode – execute cycle


The Fetch–Decode–Execute Cycle

  • FDE Cycle - Fetch

    Fetch

    The CPU fetches an instruction from the computer's RAM (like getting a command from a to-do list).

  • FDE Cycle - Decode

    Decode

    The instruction is then passed to decode.

    The CPU decodes the instruction. This means it figures out what the instruction is telling it to do and converts it into instructions which can be carried-out.

  • FDE Cycle - Execute

    Execute

    The decoded instructions are passed to execute.

    The CPU executes the instruction – it does what the instruction says.

  • FDE Cycle - Repeat

    Repeat

    The processed data is now passed back to RAM to be stored.

    Because this is a cycle, it starts all over again.

    Remember, CPUs are super-fast, and they can do billions of these cycles every second!

x/x