The Basics of Arm64 Assembly
deusinmachina.net
deusinmachina.net
Oddly similar.
Good handwritten Asm has a very different texture to it than compiler output, and (at least for x86 - perhaps less so for RISCs like ARM) can be substantially more efficient. Many years ago, I remember having to grade students' assignments on writing (x86) Asm in an introductory course, and it was very obvious to see who cheated by using a compiler (probably at O0 too.)
I think the notion of compsci students still having to learn ASM is the relic of an older generation that needs to feel like their outdated skills are still relevant.
If you want to see more examples of handwritten Asm then look at the 512b and below categories in the demoscene. Some of those have appeared on HN too:
Regarding the first example: Cool! Really interesting and I wish the contractor / employee all the best. Not many people who can do something like this. That said, are we really forcing compsci students to learn ASM for an entire semester, on the off-chance that they'll end up in a leading security role managing major software products? I feel a different curriculum would be more effective (maybe one that teaches how to avoid these bugs in the first place?).
The only real life application of handwritten ASM that I'm aware of, are the initialization routines for most programming language runtimes (GoLang and C++ come to mind) and microcode optimized shaders in game engines.
The demand for a developer-oriented ARM workstation is there, but the market still hates us.
https://blog.smittytone.net/2022/06/19/get-started-with-arm-...
- The text claims to be geared towards beginners, but doesn’t explain what a register is.
- “you are left with an Executable and Linkable Format file (Elf) which is the Linux equivalent of a .exe file” indicates the text is geared towards people who know about execution formats, possibly even Windows users who are.
- “.section .text is where our code will live”, for beginners, needs to explain what sections are and needs a remark that it’s weird that the section named “text” doesn’t contain text, but code. At a very minimum, it should say the reader will have to accept that that magic incantation is needed for now, and that more info will follow.
- the text doesn’t say why you need both ”global _start” and ”_start:”. It does introduce labels, but that’s many lines after using the first one.