what are the main functions performed by the CPU? explain in brief
Answers
Answer:
CPU helps in processing the data input in the computer.
The CPU processes instructions it receives in the process of decoding data. In processing this data, the CPU performs four basic steps:
Fetch: Each instruction is stored in memory and has its own address. The processor takes this address number from the program counter, which is responsible for tracking which instructions the CPU should execute next.
Decode: All programs to be executed are translated to into Assembly instructions. Assembly code must be decoded into binary instructions, which are understandable to your CPU. This step is called decoding.
Execute: While executing instructions the CPU can do one of three things: Do calculations with its ALU, move data from one memory location to another, or jump to a different address.
Store: The CPU must give feedback after executing an instruction, and the output data is written to the memory.