Computer Organization - Performance indicators: what to talk about what is the performance of the CPU clock speed

Computer Organization - Performance indicators: what to talk about what is the performance of the CPU clock speed

Principles of Computer Composition catalog: https://www.cnblogs.com/binarylei/p/12585607.html

1. Performance = 1 / Response Time

  • Response time (Response time) or call the execution time (Execution time)
  • Throughput (Throughput) or the bandwidth (Bandwidth)

Timing unit 2. computer: CPU clock

We mentioned above, use execution time (Wall Clock Time or Elapsed Time) to measure performance. But the direct use of the execution time, the following two questions.

  • Execution time allowed. Modern computers tend to run multiple programs simultaneously, switching the CPU, so that the reaction time is usually not a single task execution time. And the procedures are often required to read data from the network, a hard disk, this time need to eliminate.
  • Performing time-dependent performance of the device. The more the better high performance clocked device, such as the Intel Core-i5-8250U 1.6GHz / Intel Core-i7-7700HQ 2.8GHz.

Therefore, in order to have the program of the CPU calculates the execution time of the method the CPU clock is the smallest unit .

程序的 CPU 执行时间 = CPU 时钟周期数 × 时钟周期时间
                 
CPU 时钟周期数 = 指令数 × 每条指令的平均时钟周期数
程序的 CPU 执行时间 = (指令数 × CPI) × 时钟周期时间

The CPU execution time of each parameter is as follows:

  • Clock cycle time (the CPU Cycle) : is the computer frequency (Frequency / Clock Rate), clocked the more the better high performance, this depends on computer hardware. Moore's Law as we know it has been constantly improving our computer's clock speed.

    For example, 2.8GHz, we could start to think shallow, the number of simple instructions in 1 second of CPU time, you can perform is 2.8G bar. More correctly describes that the CPU clock cycles (Cycle CPU) is 1 / 2.8G.

  • The average number of clock cycles per instruction (Cycles Per Instruction, referred to as the CPI) : How much CPU Cycle is a need for instruction in the end. Different instructions needed Cycles are different, both addition and multiplication correspond to a CPU instruction, but the multiplication of Cycles will need to be more than addition, naturally slow.

    Later explained CPU architecture, we will see a modern CPU technology through the pipeline (Pipeline), so that one instruction requires the CPU Cycle as little as possible. Thus, to optimize CPI, it is also an important part of the composition and computer architecture.

  • The number of instructions : to perform on behalf of our program instruction in the end how much needs, with which instructions. Many times this put the challenge to the compiler. Same code, compiled computer instructions, when there are a variety of different representations.

For our "response time" this performance unraveling the dismantling of the product became the computer clock cycle, CPI and instruction number three separate indicators, and pointed out the three broad road to optimize computer performance for you. I.e., to enhance the frequency of the computer, CPU design optimization that can be performed in a single clock cycle more instructions, and to reduce the number of instructions required by a compiler.

3. How to improve computer performance

Since the 1980s, CPU clock speed in accordance with Moore's Law soared. But in the 21st century, single-core CPU clocked difficult to upgrade, hardware engineers turned to multi-core CPU design.

  • Moore's Law: increasing the CPU clock speed, every 18 months to double the CPU clock speed.
  • Amdahl's law: the multi-core CPU, parallel computing.

3.1 Moore's Law: From the 80's CPU clock speed soaring

When talking about the performance of CPU above, we mentioned that such a formula:

程序的 CPU 执行时间 = 指令数 × CPI × Clock Cycle Time

If you want to improve the performance of the computer, we can start from the number of instructions, CPI and CPU clocked at these three places. To get the number of instructions, or CPI, at first glance are not easy. Thus, the CPU hardware R & D engineers, from the beginning of the 1980s, the CPU will pick up on this "any punches." Put a little more on the CPU transistors and improve CPU clock frequency, so you can make faster CPU execution time of the program will be shortened.

Thus, from the Intel 8086 CPU 1978 Nian release start, clocked computer from 5MHz start rising. 80386 mid-1980s can run to 40MHz, 1989 486 years can go to 100MHz, until in 2000 the Pentium 4 processor, clock speed has reached 1.4GHz. But we can also see that in 2019 the maximum configuration Intel i9 CPU, clock speed is just a 5GHz only. Compared to 1978 and 2000, these 20 years, 300 times the clock speed increase, from 2000 to the present 19 years of this, CPU clock speed increase about 3 times.

Figure 1: CPU clock speed Pentium 4 era into a bottleneck

3.2 Power: CPU limit of the human body

In fact, the time has basically monopolized the desktop CPU market, Intel is even more exaggerated under the sea, it represents the CPU architecture used in the Pentium 4 can do 10GHz, but ultimately failed. Clocked Pentium 4 3.8GHz Why did not exceed the obstacles it? The answer is power consumption.

The answer is power consumption. What is the power consumption problem? We look at a visual example. A 3.8GHz Pentium 4 processor, full power is 130 watts. The 130-watt What is the idea? Airport allowed on the plane with its maximum capacity of charging treasure is 100 watts. If we put this CPU safe inside the phone, regardless of screen memory consumption and the like, the CPU load run 45 minutes, charging treasure which no electricity. The iPhone X using the ARM architecture CPU, power is only about 4.5 watts.

If you want to upgrade CPU clock speed, whether it is following these two operations will increase power consumption and problematic consumption and heat dissipation.

  1. Increasing density: the same area which, put some transistors;
  2. Lifting frequency: let the transistor "on" and "off" a little bit faster.

Inside the CPU, the number of transistors and the transistors can be put "on-off" frequency are also limited. A CPU power, may be represented by such a formula:

功耗 ~= 1/2 × 负载电容 × 电压的平方 × 开关频率 × 晶体管数量

Power consumption is increased too much, it will lead to CPU heat can not keep up, then, we need to reduce the voltage. There is very critical, in which the power consumption of the entire formula, the square of the voltage and power consumption is proportional. This means that the voltage drop to 1/5, the overall power consumption will become the original 1/25.

In fact, from 8086 to 5MHz frequency of 5GHz frequency of Intel i9, CPU voltage has dropped from about 5V to about 1V. That's why we enhance the CPU's clock speed 1000 times, but power consumption only increased by 40 times. For example, the Surface Go thin and light notebooks, Microsoft is to choose the voltage down to 0.25V low voltage CPU, so that the notebook can have a longer life.

3.3 Amdahl's Law: the arrival of multi-core era

When Intel Pentium 4 processor will strive to enhance the frequency to 10GHz, Intel rival AMD has a multi-core CPU with great success, but also represents the end of the "frequency era".


The intentions of recording a little bit every day. Perhaps the content is not important, but the habit is very important!

Guess you like

Origin www.cnblogs.com/binarylei/p/12603157.html