AArch64/ARM64 Tutorial

Chapter 1: Intro, What is an Assembly Language?

This tutorial is designed to teach an absolute Beginner about the ARMv8 AArch64 Assembly Language. It is assumed that said Beginner knows absolutely nothing about Assembly Languages in general. This is a pure Beginner-to-Pro tutorial.

Your desktop/laptop/video-game-console/etc is controlled by a CPU (Central Processing Unit). A CPU doesn't understand any Human Language, but a CPU can understand two things. 0's and 1's. 0 meaning no voltage. 1 meaning voltage.  These 0's and 1's are what is known as Binary numbers, which will be later explained in next Chapter. A CPU will perform tasks based on receiving fixed or variable length blocks that are made up of certain combinations of 0's and 1's. These blocks are known as CPU Instructions. It goes without saying that attempting to make a program writing in blocks of 0's and 1's is insanity. Therefore, we use what is called Assembly Language.

Assembly Language is a human readable form of these blocks of 0's and 1's (CPU instructions). We can write out Assembly Language in a program to have the CPU execute instructions. Therefore Assembly Language is a Computer Programming Language. A tool called an Assembler will take in a source text file written in a CPU's Assembly language, and will translate it into a hexadecimal representation (more on Hex in Chapter 2) of the CPU's Instructions (blocks of 0's and 1's). The CPU instructions will be written to an executable file that the CPU can launch and run it as program.

As CPU's get more advanced, they will use different/improved Assembly Languages. Some group or production line of CPUs may use the same Assembly Language. Or a new line of CPUs can use the same Assembly Language as a previous line but with subtle differences for improvements. Either way, understand that if two different CPUs use a different Assembly Language, they cannot run each other's instructions.

This problem is solved by "higher level" Computer Programming Languages, such as C, C++, etc. A tool called a Compiler takes in a source text file written in C/C++/etc, and translates it to a desired Assembly Language (which is changed to the actual CPU instructions) so the targeted/desired CPU can run the program. Therefore, this allows the Developer to not have to learn 100's of Assembly Languages, he/she can just learn one of the higher level languages.

With that being said, there are still some use cases where Assembly is necessary to learn. Such as...


Next Chapter

Tutorial Index