I want to learn machine code. Not for a specific reason. Just for the heck of it. I was wondering if there were any good machine code tutorials. I have开发者_StackOverflow社区 a macbook with a 2.4 GHz Intel Core 2 Duo processor.
First of all, unless you are a masochist, I think you would prefer a tutorial on intel assembly language programming to machine code. Assembly language uses human readable instructions - kind of a low level programming language. Machine code is machine readable - good for machines, not so good for wetware ;-)
All intel chips use some variation of the x86 instruction set. The Wikipedia article referenced above gives examples of assembly vs machine code as well as resources to learn assembly language (see the external links at the bottom of the article).
It's a great question...and I had the same back in the 1980's on my Commodore 64 and Apple IIe (back when every byte and instruction mattered). Mike Smith wrote a great book titled "6502 Machine and Assembly Language Programming" that taught me to experiment in machine code. Similar books to this one are available as pdf online. A good book like this, written for the processor you choose, will ultimately teach you the logic of performing operations in assembly and how to convert into machine code. Most want to stop at Assembly Language, but it's worth taking the next step to machine code at least once.
Here's a site that gives some decent tutorials. I used this a while ago, but I learned a lot from it. =D http://www.angelfire.com/electronic2/machinelanguage/lesson1.html
精彩评论