Tuesday, April 1, 2014

Moving data in assembly language

mov is the most frequently used instruction in assembly language.



•mov is probably one of the most frequently used instruction in assembly language

•Usage: movx source, destination

–Where x is the following

–l for a 32-bit long word value

–w for a 16-bit word value

–b for an 8-bit byte value



–movl = Moves a 32 bit word value

•Movl %eax, %ebx

–movw=moves a 16 bit word value

•Movw %ax, %bx

–movb=moves a 8 bit byte value

•Movb %ah, %bh

No comments:

Post a Comment