ASM86

from Wikipedia, the free encyclopedia

ASM86 was sold by Intel as an assembler for their x86 processor family. Today it is no longer marketed or developed. However, its syntax is widely used among x86 assemblers such as the Netwide Assembler , the Microsoft Macro Assembler or Borlands Turbo Assembler . The syntaxes of today's x86 assemblers are mostly based on that of the ASM86 or are identical to it, therefore it is also generally known as "Intel Syntax" or "Intel Assembler Syntax".

Syntax differences

There are two predominant syntaxes for x86 assemblies: Intel syntax and AT&T syntax . The Intel syntax dominates under Windows, while the AT&T syntax dominates in the GNU / Linux ecosystem.

AT&T Intel
Order of parameters First source, then destination
mov $5, %eax
First destination, then source
mov eax, 5
Parameter size Mnemonics are given a suffix that stands for the operand length : q = QWord , l = DWord, w = Word b = Byte.
addl $4, %esp
add esp, 4
Sigils Immediate values have the prefix "$", register "%".
Effective addresses DISP (BASE, INDEX, SCALE) . Example:
movl mem_location(%ebx,%ecx,4), %eax
Example:
mov eax, [ebx + ecx*4 + mem_location]

Individual evidence

  1. a b c Ram Narayam: Linux assemblers: A comparison of GAS and NASM . October 17, 2007. Retrieved January 13, 2015.
  2. ^ The Creation of Unix . Bell Labs. Archived from the original on May 20, 2011. Retrieved January 13, 2015.