Types of Addressing Modes in Computers

Written by jay rigsby
  • Share
  • Tweet
  • Share
  • Pin
  • Email
Types of Addressing Modes in Computers
random access memory (memory image by Valentin Mosichev from Fotolia.com)

Random access memory, or RAM, is the main memory for a computer. Applications are loaded and run in RAM. Addressing modes allocate RAM into portions that may be individually referenced so that the central processing unit, or CPU, can determine which memory location is being used by a machine instruction.

Immediate Addressing Mode

The immediate mode is the simplest form of addressing. The operand is part of the instruction, and therefore no memory reference, other than the instruction, is required to retrieve the operand. This mode is fast and can be used to define constants or set initial variable values. This mode has a limited range because it is limited to the size of the address field, which for most instruction sets is small compared with word length.

Direct Addressing Mode

In the direct mode, the address field contains the address of the operand. It requires a single memory reference to read the operand from the given location. However, it provides only a limited address space.

Indirect Addressing Mode

In the indirect mode, the memory cell pointed to by the address field contains the address of (pointer) the operand, which in turn contains the full-length address of the operand. This mode has a large address space, unlike direct and immediate addressing, but because multiple memory accesses are required to find the operand it is slower.

Register Addressing Mode

Register mode is similar to direct mode. The key difference between the two modes is that the address field of the instruction refers to a register rather than a memory location. Register addressing does not have an effective address. Three or four bits are used as the address field to reference registers.

Register Indirect Addressing Mode

This mode is similar to indirect addressing. The operand is in a memory cell pointed to by contents of a register. The register contains the effective address of the operand. This mode uses one fewer memory access than indirect addressing. This mode has a large address space, but it is limited to the width of the registers available to store the effective address.

Displacement Addressing Mode

Displacement mode consists of 3 variations:

1) Relative addressing

2) Base register addressing

3) Indexing addressing.

This mode can be considered a combination of direct and register indirect addressing. The address holds two values: base value and a register that contains an integer displacement that is added or subtracted from the base to form the effective address in memory.

Stack Addressing Mode

Stack mode, also known as implicit addressing, consists of a linear array of locations referred to as last-in first-out queue. The operand is on the top of the stack. The stack pointer is a register that stores the address of top of stack location.

Don't Miss

  • All types
  • Articles
  • Slideshows
  • Videos
  • Most relevant
  • Most popular
  • Most recent

No articles available

No slideshows available

No videos available

By using the eHow.co.uk site, you consent to the use of cookies. For more information, please see our Cookie policy.