???Kemp wrote: Just in case anyone takes you seriously...
NASM -> GNU ASM
Re:NASM -> GNU ASM
Every good solution is obvious once you've found it.
Re:NASM -> GNU ASM
Lol, sorry. I meant in case anyone obssessive about Intel syntax took you too seriously. Don't want a religious war on our hands. I would never suggest people who use AT&T syntax shouldn't be taken seriously ;D
Re:NASM -> GNU ASM
Hi,
In my experience, it doesn't matter if it's "opcode, source, dest" or "opcode dest, source" - it takes just a little time to get used to if you change.
My main problem with AT&T syntax is things like "[label + esi + eax * 4 + structure.field]", which looks like normal maths in Intel syntax.
My favourite would be 6502 syntax, where there's never more than one operand:
[tt] lda 12 ;Load 12 into the accumlator
sta 0x100 ;Store the accumulator at 0x100[/tt]
Only having 3 general registers and a very limited instruction set makes it very easy to learn...
BTW, if the world was a democracy we'd probably be writing assembly like this:
[tt]m s a
o u d
v b d
e [ e
a b b
x a x
, r ,
[ ] e
f , a
o e x
o c
] x[/tt]
Just a thought....
Cheers,
Brendan
In my experience, it doesn't matter if it's "opcode, source, dest" or "opcode dest, source" - it takes just a little time to get used to if you change.
My main problem with AT&T syntax is things like "[label + esi + eax * 4 + structure.field]", which looks like normal maths in Intel syntax.
My favourite would be 6502 syntax, where there's never more than one operand:
[tt] lda 12 ;Load 12 into the accumlator
sta 0x100 ;Store the accumulator at 0x100[/tt]
Only having 3 general registers and a very limited instruction set makes it very easy to learn...
BTW, if the world was a democracy we'd probably be writing assembly like this:
[tt]m s a
o u d
v b d
e [ e
a b b
x a x
, r ,
[ ] e
f , a
o e x
o c
] x[/tt]
Just a thought....
Cheers,
Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
Re:NASM -> GNU ASM
Intel syntax can't even be compared to that AT&T %%&#"?@??!!! ;D
Re:NASM -> GNU ASM
bubach wrote: Intel syntax can't even be compared to that AT&T %%&#"?@??!!! ;D
Code: Select all
echo "....." >asmfile.asm
intel2gas -r <asmfile.asm >asmfile.S
diff asmfile.asm asmfile.S
Re:NASM -> GNU ASM
I don't get the point of arguing over the syntax, it's about as effective as arguing over which assembler is better (assuming the ones being compared both support the entire instruction set), or which code editor, etc, etc.
I personally prefer GAS because I find it easier to understand at a glance, is integrated into GCC and feels more logical to me (left to right as opposed to left to right to left ordering) but if you prefer Intel syntax then use whatever makes you happy.
Less seriously, I wonder if I could create a new dialect of ASM with the Intel layout to the extreme: ;D
I personally prefer GAS because I find it easier to understand at a glance, is integrated into GCC and feels more logical to me (left to right as opposed to left to right to left ordering) but if you prefer Intel syntax then use whatever makes you happy.
Less seriously, I wonder if I could create a new dialect of ASM with the Intel layout to the extreme:
Code: Select all
eax, 4 mov
ebx, 5 mov
eax, ebx add
; Or maybe even:
xae, 4 vom
xbe, 5 vom
xae, xbe dda