Get coding on the Raspberry Pi 64-bit
Learning assembly language won’t make you a faster programmer (slower, more likely). However, it just might make you a better programmer. By learning just what a processor can and can’t do, you’re on the way to a deeper understanding of computer science.
Assembly language is a low-level language. It’s specific to a particular processor. You use it to program a specific processor at the hardware level. Compilers understand assembly language, because that’s what they use to create the instructions in high-level languages. Take a C++ compiler: it strings together lots of assembly language instructions to do its work.
Every kind of program ultimately executes machine language on the computer. Assembly language is simply machine language with mnemonics. Mnemonics are names given to machine language instructions, also known as op codes, so that we don’t have to remember hundreds of numeric values. It enables us to write a program using identifiers such as ADD, SUB and MOV.
Raspberry Pis can run in 32-bit mode (AArch32) or 64-bit mode (AArch64) depending on the OS. In this tutorial we’ll look at AArch64 and install a small 64-bit desktop machine on the Pi. The Pi is a Reduced Instruction Set Computer (RISC) that performs smaller and faster operations than a Complex Instruction Set Computer (CISC) like the Intel x86_64.
Making use of the kernel
We’re using Linux and so the assembly language we write will use Linux kernel services. Even when we use the C library (glibc), the library methods we call will, in many cases, be thin
You’re reading a preview, subscribe to read more.
Start your free 30 days