Ask the Expert

What are the differences among addressing modes like immediate, indirect and indexed?

What are the differences among addressing modes like immediate, indirect and indexed?

    Requires Free Membership to View

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

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: