Further reading
As already stated, this chapter gives you the intuition of the LLVM IR textual representation. To further deepen your expertise, we encourage you to read the following materials:
- https://llvm.org/docs/LangRef.html: The LLVM language reference that we mentioned time and time again! This is the full specification of the LLVM IR textual representation. In particular, you can find the full list of the supported generic intrinsics as well as how to interpret all the fields of the data layout string and so on.
- https://llvm.org/docs/GetElementPtr.html: This dedicated page gives a detailed explanation of one of the difficult-to-grasp LLVM instructions:
getelementptr
(orgep
for short). In a nutshell, this instruction allows you to describe which field you want to access in an aggregate type. We already gave you the intuition of how this works, but we guarantee you that you will often forget how this instruction works and thus, how to give it the right parameters...