Besides the difference between Intel and AT&T syntax, different assemblers also have other subtle syntax differences.
GNU Assembler (GAS)
as -c <assembly file> -o <object file>
GAS uses AT&T syntax by default. We can making it to use Intel syntax by adding .intel_syntax noprefix
directive to assembly or pass -msyntax=intel
command line argument.
GCC’s inline assembly uses the syntax of GAS.
LLVM
LLVM’s assembler is designed to be compatible with the GNU one.
Microsoft Macro Assembler (MASM)
A popular assembler for Windows
Netwide Assembler (NASM)
NASM is a widely used cross-platform assembler that supports various object file formats. 8 . It uses a syntax similar to Intel’s, but with changes to make it simple and easy to understand 1 As of 2024, NASM remains actively developed. 2
YASM
YASM is a complete rewrite of the NASM assembler, designed to support multiple syntaxes (NASM, GAS, etc.). It’s also cross-platform and aims to be more modular and maintainable than NASM.