The difference is all in how you access memory on the CPU.
Immediate addressing is when a hard coded number (the immediate) is part of the instruction. In x86 assembly language, MOV EAX , 8 is the instruction for moving the hard coded value 8 into the EAX register and is immediate addressing.
Indirect addressing is when memory is read out of what a register points to. For example, MOV EAX , [ECX] shows the indirect addressing of the ECX register and can be thought of a *pVar in the C programming language.
Finally, indexed addressing is when a value is added to the register and the resultant value as used as the indirect value. MOV EAX , {ECX + 10] means add 10 hex bytes to the value in ECX and get the memory at that location.
This was first published in April 2002
Join the conversationComment
Share
Comments
Results
Contribute to the conversation