Addressing modes are an aspect of the instruction set architecture in most central processing unit (CPU) designs. The various addressing modes that are defined in a given instruction set architecture define how machine language instructions in that architecture identify the operand (or operands) of each instruction. An addressing mode specifies how to calculate the effective memory address of an operand by using information held in registers and/or constants contained within a machine instruction or elsewhere.
what is the difference between direct and indirect instruction ?
If the second part of an instruction
code specifes an operand, then it is said that the instruction has an
immediate operand. If the second part specifies the address of an
operand, then it is said that the instruction has a direct address.There
is also a third possibility called indirect address, where the bits in
the second part of the instruction specify an address of a memory word
in which the address of the operand is obtained. In the instruction
code, one bit is used to distinguish between a direct and an indirect
address.
Indirect address
An address that serves as a reference point instead of the address to
the direct location. For example, if a programmer saved something to an in memory, the data is saved to any free spot in the memory, instead of a specific address.
No comments:
Post a Comment
its cool