The first week of Linux kernel design--from the assembly language to understand how the computer works Song Juning (20135315) I. The experimental process figure 1 writing songchenning5315.c file
Figure 2 Compiling a C file into a 32-bit machine language
Figure 3 Removing the link statement from the. s file to get the final assembly code
Second, the analysis of stack changes
Summarize and clarify the understanding of "how the computer Works".
① computer is based on the storage structure of von Neumann body, according to its core idea--the computer working model of stored program, according to the Order of program arrangement, take out the instruction step by step, and automatically complete the operation stipulated by the instruction.
② from a hardware point of view, is to connect the CPU and memory through the bus, using the EIP register in the CPU to store the current execution instruction in memory address, to achieve the above process.
③ from the programmer's point of view, the computer saves instructions and data through memory, executes instructions through the CPU interpretation, and the programmer uses API application programming interfaces to implement the process of writing code and executing it.
④ through the use of high-level language close to human language, through the assembly language, machine language translation, the ultimate realization of the combination of human and machine, so that the computer can work perfectly.
Resources
1, "Linux kernel Analysis" MOOC course http://mooc.study.163.com/course/USTC-1000029000
2, experimental building 64-bit Linux virtual machine environment https://www.shiyanlou.com/courses/running/555
The first week of Linux kernel design--understanding computer working principle from assembly language