Search code examples
assemblymasmmasm32

MOV [EBX], AX - Pointer to a register?


MOV [1234H], AX means that the value of AX is copied to 1234 hexadecimal address in memory. So, please correct me if what I am saying is wrong, the [] operator functions as a pointer to, right?

This being said, I can't understand the following instruction: MOV [EBX], AX why the use of the [ ]? EBX is a general purpose register inside the processor, not a memory cell, so there is no pointer to it, right?

P.S. I am programming under masm32.

Thanks


Solution

  • Register EBX here holds a value, which is an address. MOV [EBX], AX means that: take the value stored in register AX; write it to the address which is stored in EBX.