COMPUTER
ORGANISATION & ARCHITECTURE
MEMORY ADDRESSING PART-2
SAJEENA SHAJI
Addressing Mode
The different ways of specifying the location of an operand in an
instruction are called as addressing modes.
Elements of an instruction
❏ Immediate Addressing mode
❏ Direct/ Absolute addressing mode
❏ Indirect addressing mode
❏ Register direct addressing mode
❏ Register indirect addressing mode
❏ Implicit addressing mode
❏ Stack addressing mode
❏ Displacement addressing mode
❏ Auto_increment addressing mode
❏ Auto_Decrement addressing
Type of Addressing
Immediate Addressing Mode
● The operand is specified in the instruction explicitly.
● Instead of address field, an operand field is present
that contains the operand.
● Example
MOV R1,#100
LOAD R1,#10
Direct Addressing Mode
● The address field of the instruction contains the
effective address of the operand.
● Only one reference to memory is required to fetch
the operand.
● It is also called as absolute addressing mode.
● Example
MOV R1,1000
InDirect Addressing Mode
● The address field of the instruction specifies the
address of memory location that contains the effective
address of the operand.
● Two references to memory are required to fetch the
operand.
● Example
MOV R1,(1000)
Register Direct Addressing Mode
● The operand is contained in a register set.
● The address field of the instruction refers to a CPU
register that contains the operand.
● No reference to memory is required to fetch the operand.
Example
MOV R1, R2
Register InDirect Addressing Mode
● The address field of the instruction refers to a CPU register
that contains the effective address of the operand.
● Only one reference to memory is required to fetch the
operand.
Example
MOV R1, (R2)
Implied Addressing Mode
● The definition of the instruction itself specify the
operands implicitly.
● It is also called as implicit addressing mode.
Example
PUSH, Complement Accumulator
Stack Addressing Mode
● The operand is contained at the top of the stack.
○ Example - ADD
● This instruction simply pops out two symbols
contained at the top of the stack.
● The addition of those two operands is performed.
● The result so obtained after addition is pushed again
at the top of the stack.
Displacement Addressing Mode
● Relative Addressing mode
● Base register Addressing mode
● Indexed Addressing mode
Relative Addressing mode
Effective address of the operand is obtained by adding the
content of program counter with the address part of the
instruction.
Indexed Addressing mode
Effective address of the operand is obtained by adding the
content of index register with the address part of the
instruction.
Base Register Addressing mode
Effective address of the operand is obtained by adding the
content of base register with the address part of the
instruction.
Auto Increment Addressing mode
● After accessing the operand, the content of the register is
automatically incremented by step size ‘d’.
● Step size ‘d’ depends on the size of operand accessed.
● Only one reference to memory is required to fetch the
operand.
Auto decrement Addressing mode
● First, the content of the register is decremented by step
size ‘d’.
● Step size ‘d’ depends on the size of operand accessed.
● After decrementing, the operand is read.
● Only one reference to memory is required to fetch the
operand.
THANK YOU

Addressing modes in computer organization

  • 1.
    COMPUTER ORGANISATION & ARCHITECTURE MEMORYADDRESSING PART-2 SAJEENA SHAJI
  • 2.
    Addressing Mode The differentways of specifying the location of an operand in an instruction are called as addressing modes. Elements of an instruction
  • 3.
    ❏ Immediate Addressingmode ❏ Direct/ Absolute addressing mode ❏ Indirect addressing mode ❏ Register direct addressing mode ❏ Register indirect addressing mode ❏ Implicit addressing mode ❏ Stack addressing mode ❏ Displacement addressing mode ❏ Auto_increment addressing mode ❏ Auto_Decrement addressing Type of Addressing
  • 4.
    Immediate Addressing Mode ●The operand is specified in the instruction explicitly. ● Instead of address field, an operand field is present that contains the operand. ● Example MOV R1,#100 LOAD R1,#10
  • 5.
    Direct Addressing Mode ●The address field of the instruction contains the effective address of the operand. ● Only one reference to memory is required to fetch the operand. ● It is also called as absolute addressing mode. ● Example MOV R1,1000
  • 6.
    InDirect Addressing Mode ●The address field of the instruction specifies the address of memory location that contains the effective address of the operand. ● Two references to memory are required to fetch the operand. ● Example MOV R1,(1000)
  • 7.
    Register Direct AddressingMode ● The operand is contained in a register set. ● The address field of the instruction refers to a CPU register that contains the operand. ● No reference to memory is required to fetch the operand. Example MOV R1, R2
  • 8.
    Register InDirect AddressingMode ● The address field of the instruction refers to a CPU register that contains the effective address of the operand. ● Only one reference to memory is required to fetch the operand. Example MOV R1, (R2)
  • 9.
    Implied Addressing Mode ●The definition of the instruction itself specify the operands implicitly. ● It is also called as implicit addressing mode. Example PUSH, Complement Accumulator
  • 10.
    Stack Addressing Mode ●The operand is contained at the top of the stack. ○ Example - ADD ● This instruction simply pops out two symbols contained at the top of the stack. ● The addition of those two operands is performed. ● The result so obtained after addition is pushed again at the top of the stack.
  • 11.
    Displacement Addressing Mode ●Relative Addressing mode ● Base register Addressing mode ● Indexed Addressing mode
  • 12.
    Relative Addressing mode Effectiveaddress of the operand is obtained by adding the content of program counter with the address part of the instruction.
  • 13.
    Indexed Addressing mode Effectiveaddress of the operand is obtained by adding the content of index register with the address part of the instruction.
  • 14.
    Base Register Addressingmode Effective address of the operand is obtained by adding the content of base register with the address part of the instruction.
  • 15.
    Auto Increment Addressingmode ● After accessing the operand, the content of the register is automatically incremented by step size ‘d’. ● Step size ‘d’ depends on the size of operand accessed. ● Only one reference to memory is required to fetch the operand.
  • 17.
    Auto decrement Addressingmode ● First, the content of the register is decremented by step size ‘d’. ● Step size ‘d’ depends on the size of operand accessed. ● After decrementing, the operand is read. ● Only one reference to memory is required to fetch the operand.
  • 19.