Re:Introduction to ARM Assembly Basics
by mishurov on Sunday May 28, 2017 @02:27AM
(#14433338)
Why don't people use AT&T syntax for ARM?
[ Parent
| on HN ]
Re:Introduction to ARM Assembly Basics
by theresistor on Sunday May 28, 2017 @02:38AM
(#14433358)
AT&T syntax is a uniquely X86 thing.
No it isn't, as AT&T syntax is used on SPARC and Motorola 68000, for example. It has nothing whatsoever to do with any processor in particular.
What do you mean by "AT&T syntax"? Neither 68000 nor SPARC use it, because it's an x86 thing. Do you really mean "operand order"? There's more to an assembly language syntax than just the order of the operands.
AT&T syntax is mainly about operand order, but there are assembler directives and constructs specific to AT&T as found in as(1) on any traditional UNIX, including illumos based ones. That every assembler has his own syntax is nothing new, compare and contrast Master SEKA with ASM-One on Amiga, or MASM, TASM or nasm, for example. AT&T as(1) syntax has nothing to do with x86. Any code written for SVR4 as(1) will be using AT&T syntax, irrespective of processor architecture. ISA used with AT&T as(1) will still be that of the processor, of course, but instead of things like a0 or d0, it'll be %a0 and %d0, for example.
Re:Introduction to ARM Assembly Basics
by FubarCoder on Sunday May 28, 2017 @03:00AM
(#14433402)
Intel syntax is an x86 thing.
I was very surprised when I'd discovered that the assembly in the Linux kernel sources for x86 was written in the AT&T syntax and the assembly for ARM was not. I always thought that the AT&T syntax was supposed to be independent from an architecture.
"Architecture independent assembly language". Just say that out loud and set it sink in for a moment. Anyways, glad that there's no AT&T abomination for ARM, too.
Re:Introduction to ARM Assembly Basics
by Houshalter on Sunday May 28, 2017 @06:57AM
(#14433883)
And web assembly is written in some kind of weird lisp inspired s expression format.
WebAssembly is really WebBytecode. https://en.wikipedia.org/wiki/WebAssembly