Reputation: 103
I'm looking for a good, concise, structured way to start learning x86 ASM. I have experience with Perl, Python, and C/C++, and I've been wanting to 'get under the hood' so to speak for quite awhile now but every time I research it I find nothing but confusing, conflicting, and largely out of date information.
I've messed with MASM, FASM, HLA, and a few other things I've found just googling around, but none of them seem to offer what I'm looking for: a quick introduction with good information into the nitty gritty low level world of ASM.
I don't want things like HLA that give you things like stdout.put(), etc. I want to be able to see actual interrupts being called, and learn how everything does what it does. Any advice?
(Editor's note: resource-request questions are off-topic these days.
Some good tutorials and guides are linked in the x86 tag wiki.)
Upvotes: 5
Views: 1578
Reputation: 2117
There is the definite bible of Assembly: Art of Assembly.What is more, it is freely available online!It is a bit out of date, which is good since you will be able to learn the basics without diving into the terribly complicated new "features" only useful for operating systems.
(source: computer-books.us)
A few tips:
Use nasm, it is the 'standard' compiler in the unix and the windows world, and is has a syntax which is very similar to masm, used by the book.(that is not to say that it is better, only better-documented).
You are right, HLA is the wrong way to learn assembly.Save it for high-level languages:)
You can run the programs either on top of an os, or, use Virtualbox
Try to 'stick to the metal' for the beginning.That is, no libraries and nothing else than assembly.Nothing that the machine itself does not provide.
Once you pick up the theory(it is important!) you can try reading about bios functions and specifically the print to screen ones(they are very simple) so that you can test your code on a virtual machine, or real hardware quickly.
Albeit not necessary, you can also try learning c, since they share the low level concepts with assembly and is reasonably similar to c++.
A quick hello world tutorial to get you started on linux.
The bios functions(actually interrupt calls).
Upvotes: 3
Reputation: 159
For the concepts it is always good to start with the basic books. I would suggest the book "8086 Microprocessor: Programming and Interfacing the PC" by Kenneth J. Ayala. It is a textbook used in many universities around the world and will introduce you to the topic.
Upvotes: -1
Reputation: 1131
You should try MIPS assembly, It's way easier and good if you want to understand how assembly works. There's a simulator called MARS that can be downloaded here: http://courses.missouristate.edu/KenVollmar/Mars/download.htm
This can help you yoo: http://www.inf.pucrs.br/~calazans/undergrad/arq1/mips/cod-appa.pdf
Sorry not answering your question properly.
Upvotes: 3