7

I was reading this article on wikipedia about list of assmeblies

http://en.wikipedia.org/wiki/List_of_assemblers

turns out there are alot of assembly languages out there.. so for example if u learn the Yasm assembly language, would be hard to read the TCCASM code? is it like completely different than all the other asem.. languages? I wana learn this language but i dont know which one to choose.. if u could recommend some good books for novice programers that covers assembly x86 in general i would be more than grateful

John Sly
  • 97
  • 1
  • 2
  • 3
    I would not learn x86 first, not a good first asm. msp430, arm, thumb, avr, there are a number of them, do mips after one or two then x86 if you bother. yes each instruction set has an assembly language to go with it, and there may be more than one assembler (program that parses assembly language and makes machine code from it) for each instruction set, and sometimes the syntax or certainly directives are different. Once you learn a good instruction set, the second is much easier and the third and so on, much easier than learning multiple high level languages – old_timer Sep 07 '12 at 20:48

2 Answers2

6

You should not confuse the following:

  • assembly language (abstract idea with different implementations)
  • assembler (a program, a kind of a compiler (if you will) that implements the language)
  • syntax (yet another implementation-specific detail; compare AT&T and Intel syntaxes for the x86 platform)
  • instruction sets (different for different CPUs)

The general idea of the assembly language is one. But its embodiments are many and different (e.g. MASM, TASM, NASM, (G)AS, etc etc). They differ in what CPUs they support and what instruction (sub)sets, what features they support (e.g. expressions, macros, support for structured programming, object/binary file formats) and what it all looks like (syntax, mnemonics, directives, comments).

If you know how to use one assembler for a specific platform, it shouldn't be very hard to learn another one. Likewise, if you know how to write assembly code for one platform, it shouldn't be much of a deal to learn to write asm code for another one. All that, of course, is true if you have a good understanding of at least one assembler and one instruction set.

Alexey Frunze
  • 61,140
  • 12
  • 83
  • 180
0

I would start with Z80, to get the idea of registers, program counter, stack, flags, mnemonics, etc. It is very clean and useful, and not too complicated, but has everything you need to program a processor. This is biased of course, as this was my first encounter with a processor :) But most others are just more complicated, with more possibilities and power of course, but it may confuse you only at the beginning.

Ho Zong
  • 523
  • 1
  • 4
  • 22