yujiri.xyz

Software

Learn programming for good instead of profit

Processor architectures

You've heard that processors execute a compact kind of instructions, but what are they? The processor's architecture or instruction set defines what instructions it understands. Most end-user computers nowadays use the same architecture: the 64-bit version of the "x86" architecture created by Intel. It can be written as x86_64, or amd64, or just x64 - I know, it sucks how many different names some of these things have!

When you compile a program, it's translated to a specific set of machine instructions, normally the same set your host computer uses. What happens if you try to run a program compiled for a different architecture? It won't run at all. You would need to get the source code and compile it for the correct architecture.

There are other architectures, they're just much less common than x86 (or meant for things other than end-user computers). I've met a few people who have computers using the ARM architecture - Apple recently switched to it for their new computers. Binaries compiled for x86 processors don't work on ARM processors, and vice versa.

Most architectures, including x86 and ARM, are proprietary and thoroughly encumbered by intellectual property. RISC-V is a relatively new architecture which is not encumbered by intellectual property. You're very unlikely to find an end-user computer with a RISC-V processor yet, but I hope it'll take off soon :)

Proxied content from gemini://yujiri.xyz/software/guide/arch.gmi

Gemini request details:

Original URL
gemini://yujiri.xyz/software/guide/arch.gmi
Status code
Success
Meta
text/gemini; lang=en
Proxied by
kineto

Be advised that no attempt was made to verify the remote SSL certificate.

What is Gemini?