Reading and Understanding Code
摘要
Now that the core of RISC-V Assembly Language has been covered, this chapter provides the fundamentals to read another programmer’s code. Reading other programmer’s code is a great way to not only add to a toolkit of tips and tricks but also improves coding. Also, where Assembly Language source code for the RISC-V processor can be found will be reviewed. One of the Assembly Language routines from the Linux kernel will be examined to learn new optimization techniques. Then how the GNU C compiler writes Assembly Language code will be examined and analyzed. The NSA’s Ghidra hacking tool that converts Assembly Language code back into C code, at least approximately, will be studied.