Two-Operand Instructions

From CPUDev Wiki
Jump to: navigation, search

Two-operand instructions are generally instructions of the a := a <op> b form, that is one of the inputs being used for storing the output.


  • Shorter instruction size - Having only two instead of three operands in an instruction saves space that would otherwise be used for the third operand.


  • Moves sometimes needed more often - When an operation like c := a + b is encountered, (unless a is not used anymore) it needs to be broken up into two instructions:
a := a + b
c := a

See Also

Three-Operand Instructions