Arithmetic and logic unit carries out the arithmetic operations (addition, subtraction, division andmultiplication) and logic operations (comparison of two pieces of data to determine whether oneis greater than, smaller than or equal to the other).Control unit controls the timing and routing of signals inside the processor. It also decodes theinstruction which is held in the current instruction register.
Fetch – Decode – Execute Cycle
This is the set of repetitive tasks always being carried out by the processor when it is switched on.
What is “fetch”?
This is fetching a machine code instruction from the memory
This is “decode”?
This is the process of analyzing a machine code instruction by the control unit to determine itsfunction.
What is “execute”?
This is carrying out of an instruction
Format of assembly code
Assembly code statements have the following general format
Some examples of op codes
ADD, SUB, MUL, DIV, JMP, LDA
Fetch phaseExecute phaseDecode phase
op code operand