Fundamentals of Computing System (1)

Write at the beginning

   接下来一系列博客将作为一个初学者对整体计算机系统的理解与概括,主要作为个人学习总结归纳使用,若能帮助初学者对计算机有整体了解,自然再好不过。

Reference book: "Computer System Foundation" of Nanjing University

1. The overall structure of the computer

What does "computer" mean? The most intuitive understanding: it is a machine that can do calculations, but we know that compared with calculators, it can use numbers to perform various activities, and even affect the real world. To achieve this, there must be a rigorous system to support it to achieve various possibilities within a certain range.

The American Hungarian mathematician von Neumann proposed the principle of stored programs in 1946, treating the program itself as data. The program and the data processed by the program are stored in the same way. This idea is still used today and is applied in every On a computer, that is, the famous von Neumann architecture .

   然而对于我们来说,冯·诺依曼体系结构仍然不足以让初学者对它有清晰的认知,据此,《计算系统基础》一书给出了如下的计算机结构图:

Fundamentals of Computing System (1)

  1. Based on this structure diagram, we can roughly explain the working principle of computers from top to bottom: People want to solve certain types of problems, so they design corresponding programs. Similar "programs" are actually in contact with high school mathematics. Over, the program flow chart:
    Fundamentals of Computing System (1)

  2. However, such a program cannot be "understood" by the machine. In order to make it easier for us to understand the "speaking" of the machine, and at the same time to let the machine understand our "speaking", a high-level language and a low-level language are designed separately, and at the same time, to support the machine to read The fetching process requires the support of the operating system. It is worth mentioning that there are high-level languages ​​such as C, JAVA, etc. One of the obvious differences between them and low-level languages ​​is that they are close to human languages, while low-level languages ​​are relatively close to the preset instruction format of the machine, which fits well in the computer. The instruction set structure .

  3. Why do you want to pre-set basic computer operations? Why is an instruction set structure required ? Because there are only two kinds of "pinyin" that computers can understand, namely 1 and 0. After stipulating the basic operations of computers (such as addition, subtraction, multiplication and division, or abnormalities encountered in high school physics), we can design programming languages ​​on this basis to facilitate human logical thinking to understand computers.

  4. Next, the design of the computer operation is completed. We need to implement it at the hardware level. Due to the complexity of the underlying circuit, "Computer System Fundamentals" chooses to gradually transition from the most basic components to the microprocessor and instruction set structure. The most basic components are generally composed of semiconductors, and the functions they can achieve are generally only two: input 1 (voltage), or input 0 (no voltage). It is not difficult to find that the use of component pairs 1 and 0 corresponds exactly to the "pinyin" of the computer. In actual operation, the reason for this design takes into account the actual situation: in the actual circuit due to various factors of force majeure, there may be a voltage of a few tenths of a volt in the open circuit. Therefore, in order to ensure the accuracy of the computer's underlying circuit, it will not be affected by various The interference of factors, in the thinking of the computer, we choose to regard 0V as 0, and all other situations as 1. And from this, a logic circuit based on the exclusive OR gates and gates encountered in high school physics is produced . The microprocessor composed of logic circuits realizes the calculation method specified by the instruction set structure at the physical level according to a specific design, and gradually moves upwards to realize the execution of the program language and solve the problem.

Although in the eyes of our beginners, such a computing system is too complicated, but it successfully separates each divided area completely. In other words, we use computers to solve problems without knowing the programming language, instruction set structure, etc. Moreover, in the further study of computer systems in the future, we will truly realize the importance of such a system.

Guess you like

Origin blog.51cto.com/14930847/2593512