AArch64 assembly - part 0
Author: Carmelo C.
Published: Feb 27, 2025 (updated)assembly
arm64
aarch64
coding
AArch64
Index
Background
I’m not exactly a programmer. I can write some (mostly bad) code, understand a few tiny bits here and there, but I can’t claim to be an expert in this field.
Be that as it may, I’m curious, I’m an avid learner, I sweat my way through new things until I reach that A-HA moment.
I love tutorials on the Internet because, that’s my hope, one can quickly be projected into the practical parts of a new topic. Digging deeper is left as an exercise to the reader.
Clerk: You’ve got a pet halibut?
Man: Yes, I chose him out of thousands. I didn’t like the others, they were all too flat.
However, I have struggled to find the perfect tutorial. This one is too detailed, this one is too specific… I’m being picky, I know, but the impression I get is that assembly is somehow for the initiated.
BTW, some documents on the Internet are exceptionally good. You may want to take a look at the Resources page.
After reading a few very good ones, I have taken the bold move to write my own. I’ve done that with the intention to leave some notes to myself that would match my own learning process. I’d be glad if the same notes are helpful to others.
That being said, let’s start and feel free to ping me or open some meaningful(1) PR in case you’d like to contribute.
NOTE: The following outputs have been generated on a Raspberry Pi 4. Here’s what my environment looks like:
- board
$ lscpu
Architecture: aarch64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 4
On-line CPU(s) list: 0-3
Thread(s) per core: 1
Core(s) per socket: 4
Socket(s): 1
Vendor ID: ARM
Model: 3
Model name: Cortex-A72
...
- software
$ as --version
GNU assembler (GNU Binutils for Debian) 2.35.2
...
$ ld --version
GNU ld (GNU Binutils for Debian) 2.35.2
...
$ gdb --version
GNU gdb (Debian 10.1-1.7) 10.1.90.20210103-git
...
(1) meaningful: such as blatant errors or significant improvements. Syntax errors are also welcome but they are only accepted in multiples of three :)