Addressing Modes in Computer Architecture YASH PAL, October 17, 2025November 8, 2025 Addressing Modes in Computer Architecture – The opcode (operation code) field of an instruction specifies the operation to be performed on some operands. These operands may be stored in processor registers or in memory or may be provided directly. The way in which the operands are provided during execution is called addressing mode of that instruction. In other words, the addressing mode specifies how to find the effective address of an operand using the information available in instruction. Addressing Modes The most common addressing modes are: Implicit addressing mode Immediate addressing mode Direct addressing mode Indirect addressing mode Register addressing mode Register indirect addressing mode Displacement addressing mode Auto increment/decrement addressing mode The availability of addressing mode gives the flexibility to the programmer for writing programs in more efficient way in terms of number of instructions (size of program) and execution time. Implicit Addressing Mode This addressing mode is also known as implied addressing mode. It does not explicitly specify an effective address for either source or the destination. Either the source (if any) or destination effective address is implied by the opcode itself. This addressing mode was quite common in older computers. For example, “Set Carry Bit” is an implicit mode instruction because the operand is carry bit in flag register, which is implicit in instruction. The instruction format for implicit addressing mode contains only opcode field. There is no operand field. Below figure shows the instruction format for this mode. Implicit Addressing Mode Immediate Addressing Mode This is the simplest form of addressing. Here, the operand is given in the instruction itself. This mode is used to define a constant or set initial valűes of variables. The advantage of this mode is that no memory reference other than instruction fetch is required to obtain the operand. The disadvantage is that the size of the operand is limited to the size of the address field, which makes instruction sets small compared to word length. In the immediate addressing mode, the instruction does not state explicitly the location of the operand, rather, it explicitly states the operand itself. The instruction format for immediate addressing mode is shown in below figure. The operand becomes an integral part of the instruction. Immediate Addressing Mode Direct Addressing Mode In direct addressing mode, effective address of the operand is given in the address field of the instruction. It requires one memory reference to read the operand from the given location and provides only a limited address space. Length of the address field is usually less than word length. The direct addressing mode was common in earlier generations of computers but is not common on current architectures. A simple example of direct addressing mode is shown in below figure. in which the instruction contains the opcode and effective address of the operand. Direct Addressing Mode Indirect Addressing Mode In indirect addressing mode, the address field of the instruction provides the address where the effective address is stored in memory. The advantage of this mode is that for the word length of N. An address space of 2N can be addressed. The disadvantage is that instruction execution requires two memory reference to fetch the operand. Multilevel or cascaded indirect addressing can also be used. In this mode, the processor fetches the instruction from memory and uses its address part to access memory again to read the effective address. Example of indirect addressing is shown in below figure. Indirect Addressing Mode Register Addressing Mode Register addressing mode is similar to direct addressing. The only difference is that the address field of the instruction refers to a register rather than a memory location. 3 or 4 bits are used in address field to reference 8 to 16 general purpose registers. The advantage of register addressing is small address field is needed in the instruction. In this mode the operands are in registers that reside within the processor unit. The particular register is selected from the address field of the register as shown in below figure. The disadvantage of register addressing is that the address space is very limited. Register Addressing Mode Register Indirect Addressing Mode Just as previous one, register indirect addressing is similar to indirect addressing. In both cases, the only difference is whether the address field refers to a memory location or a register. In this mode the instruction specifies a register in processor unit whose contents give the address of the operand in memory. The example of this addressing mode is shown in below figure. Register Indirect Addressing Mode The advantage of this mode is that address field of the instruction uses fewer bits to select a register than would have been required to specify a memory address directly. Displacement Addressing Mode This mode combines the capacity of direct addressing and register indirect addressing mode. This mode contains two address fields in which one provides the offset address and other provides reference address. From these two address fields, the effective address is calculated. There are three most common types of displacement addressing mode. Relative addressing mode Index addressing mode Base addressing mode. (a) Relative addressing mode: In this mode, the address given in address field of instruction is an offset, not the actual address. It is added to the contents of the program counter (PC) register to generate the effective address. The program counter stores the address of the instruction to be executed. Therefore the same relative instruction will produce different addresses at different locations in the program. Effective Address = Address in Program counter + offset Address The below figure shows relative addressing mode example. The address field of the instruction is usually a signed number which can be either positive or negative. So it can give the address positive and negative both side of the address in program counter. Relative Addressing Mode (b) Index Addressing Mode: This mode also works like relative addressing mode, except the address given by the instruction is added to the contents of an index register instead of the program counter. Index register is a special register of processor which contains the index value. The address field of the instruction provides the starting address of a data array in memory. The distance between the starting address and the address of the operand is the index value stored in index register. The index register can be incremented to access each data of array with the same instruction. The effective address in index address mode can be given as follows Effective Address = Starting Address in Instruction + Address in Index Register The below figure shows the index addressing mode. Index Addressing Mode (c) Base Address Mode: In this mode, base contains a memory address, and the address field contains a displacement from that address. The register reference may be explicit or implicit. This mode is similar to the indexed addressing mode with the difference that the register is now named as a base register instead of an index register. The other difference is the way they are used. An index register holds the index number that is relative to the address part of the instruction whereas the base register holds the base or starting addressing and the address field of instruction gives a displacement or offset address. The effective address of the operand is the sum of the contents of the base register and offset address given in instructions. Effective Address = Contents of Base Register + Offset Address Below figure shows the base addressing mode. Base Addressing Mode Auto increment/Decrement Addressing Mode This mode is similar to the register indirect mode except that the register is incremented or decremented automatically after or before its value is used to access the memory. When the address stored in the register refer to a table of data in memory, it is necessary to increment or decrement the register after every access to the table. This can be obtained using this mode. Related Questions and Answers What is the significance of addressing mode? The addressing mode specifies how to find the effective address of an operand using the information available in instruction. What are the addressing modes commonly available? The most common addressing modes are:Implicit addressing modeImmediate addressing modeDirect addressing modeIndirect addressing modeRegister addressing modeRegister indirect addressing mode Computer System Architecture engineering subjects Computer System Architectureengineering subjects