This action might not be possible to undo. Are you sure you want to continue?
By Hiren Sardhara
Introduction An instruction is normally made up of a combination of an operation code and some way of specifying an operand. most commonly by its location and address in memory though non memory reference instruction can exists. .
Gain Understand . familiarity with memory addressing modes.OBJECTIVES OF INSTRUCTION Understand the factors involved in instruction set architecture design. the concepts of instruction-level pipelining and its affect upon execution performance.
TYPES OF COMPUTER INSTRUCTIONS Four address instruction Three address instruction Two address instruction One address instruction Zero address instruction .
FOUR ADDRESS INSTRUCTION:The instruction specifies the address of operands in memory.Q.S P and Q address of two operands R is address of memory where result is stored S is location of next instruction to be executed. the address where results is stored and also the address where the next instruction to be carried out is stored Example:-ADD P. .R.
In these fields.ADD R1. Example:. either a processor register or a memory operand can be specified.R3 implies R1 R2+R3 The general format is dest [src1] op [src2] .R2.THREE ADDRESS INSTRUCTION:The instruction specifies three address.
ADD R1. The first operand listed in the instruction is assumed to be both a source and destination where the result of the operation is stored.R2 implies R1 R1+R2 .TWO ADDRESS INSTRUCTION:They are most commonly used in commercial computers. Example:.
ONE ADDRESS INSTRUCTION:The operations which are done between the AC register and a memory operand. For these kind of operations the one address instruction is used. the accumulator will be used for all data manipulation Example:. By default .ADD B implies AC [AC]+[B] .
.PUSH A pushes A onto the top of the stack. The operands are stored in a stack. Stack is a sequence of memory locations where data can be inserted and deleted from only one end called top of the stack.ZERO ADDRESS INSTRUCTION:There are instruction where the location of operands is denied implicitly. Example:. Stack is in generally last-in-first-out format.
a register. They can specify a constant. Certain addressing modes allow us to determine the address of an operand dynamically. or a memory location. The actual location of an operand is its effective address.ADDRESSING Addressing modes specify where an operand is located. .
. Register addressing is where the data is located in a register. Direct addressing is where the address of the data is given in the instruction. Indirect addressing gives the address of the address of the data in the instruction.Addressing Immediate addressing is where the data is part of the instruction. Register indirect addressing uses a register to store the address of the address of the data.