⚙️Machine Code
Also known as Machine Language, Native Code, Binary Code
The raw steps a chip runs on its own. Compilers make it for you.
Think of it like
Think of it like the holes in a music box drum. The box plays them, but people cannot read the tune from them.
Example
A phone chip and a laptop chip speak different machine code. That is why one app file cannot run on both.
Why it matters
All software ends up as machine code in the end. It is why a program built for one chip may not run on another.
Definition
Example code
console
$ objdump -d add.o
0000000000000000 <add>:
0: f3 0f 1e fa endbr64
4: 8d 04 37 lea (%rdi,%rsi,1),%eax
7: c3 retCommon mistake
Key takeaways
- 1Chip's own steps. The chip runs it with no help.
- 2One per chip family. Code for one chip may not fit another.
- 3Made, not written. Compilers write it, not people.