Assembler Syntax
Posted: Thu Mar 23, 2006 11:10 pm
I prefere the intel Syntax because it is more logical than AT&T
For example:
with like syntax Intel syntax
when you assign somthing in C/C++ (or any language for that matter) you do sothing like this:
destination = source.
converted to assembly would be
mov destination,source
with AT&T syntax the same insruction would be
mov{size} {some prefix stuff)source, {some prefix stuff)destination
which when converted to C it would look like this
source = destintation
also the memory addressing is also not logical. in AT&T sytax it would look like this
immed32(basepointer,indexpointer,indexscale)
which in mathimatics would be interpreted as
immed32 * basepointer + indexpointer + indexscale
wich is totaly wrong
For example:
with like syntax Intel syntax
when you assign somthing in C/C++ (or any language for that matter) you do sothing like this:
destination = source.
converted to assembly would be
mov destination,source
with AT&T syntax the same insruction would be
mov{size} {some prefix stuff)source, {some prefix stuff)destination
which when converted to C it would look like this
source = destintation
also the memory addressing is also not logical. in AT&T sytax it would look like this
immed32(basepointer,indexpointer,indexscale)
which in mathimatics would be interpreted as
immed32 * basepointer + indexpointer + indexscale
wich is totaly wrong