I have a line of assembly code below (in AT&T assembly lang):
movl myvar, %eax
I am a bit confused as to how this would work because %eax is a 32-bit register and myvar seems like a label which is basically an address. Can you store addresses in registers?
For instance, lets say myvar is a label with an address like 1234. Wouldn't that line of code be saying movl 1234, %eax? Can that 1234 which is a memory address be stored in %eax without having to do movl $1234, %eax or movl $myvar, %eax?