Master the fundamental concepts of arm assembly (aarch64) through this focused micro-challenge.
AArch64 exposes x0-x30 plus sp and xzr. More registers than x86 means Clang spills less often, part of why Apple Silicon feels fast at modest clocks. w0 is the low 32 bits of x0; writing w0 zero-extends into x64.
asmLoading…
For this exercise, you will move immediates through several registers and print results with sys_write. This task asks you to mix x and w forms deliberately, because ABI docs and crash logs report both names for the same physical register.
Keep the relevant man page, ABI doc, or Rust reference chapter open while you work. When your output disagrees with the reference implementation on the same machine, the mismatch is usually an alignment rule, an off-by-one terminator, or a register slot you misread in GDB. Skim the official documentation for the tool or ABI named in the exercise; the prose changes, but register roles, syscall numbers, and ownership rules stay stable across releases. Treat each failure as a contract test: the CPU, kernel, and borrow checker enforce rules whether or not the tutorial mentioned them explicitly.
Write ARM assembly demonstrating various register usages.
Requirements:
Three hints are available for this task, revealed one at a time inside the code workspace so you can struggle productively before seeing them.
All starter code and reference implementations are available for your local setup.
View on Github