Collection
zero Useful+1
zero

Computer performance

Indicators used to measure the performance of computer systems
Computer performance refers to the indicators used to measure the performance of computer systems, but the most reliable measure is time. Time can be defined differently according to the calculation method, such as response time CPU Time, etc.
Chinese name
Computer performance
Foreign name
Computer performance
Discipline
Computer application
Indicator 1
CPU
Indicator 2
MIPS
Indicator 3
MFLOPS

Performance Introduction

Announce
edit
When designing a computer system, in addition to making clear the hardware interface, it is also necessary to achieve the most reasonable hardware functions according to the best performance and price ratio expected from the perspective of the designer. So what is the performance price ratio of computer systems? And how to measure them?
Various scales can be used to measure the performance of computer systems, but the most reliable one is time. Time can be defined differently according to the calculation method, such as response time, CPU time, etc. Response time refers to the waiting time required for a user to send a task to the computer system until he gets the results he needs. It includes the time of accessing disk and main memory, CPU operation time, I/O action time, and the time cost of operating system work. Although this definition is intuitive, for multi-channel programs, because the CPU can switch to execute other programs while one program is waiting for I/O operations, the response time cannot distinguish this situation. The other case is that only CPU time is considered, which can be distinguished at this time. It does not include the time spent waiting for I/O operations and the time spent by the CPU to run other programs. Of course, CPU time itself can also be divided into user CPU time and system CPU time. It is difficult to make accurate statistics of system CPU time, because this actually requires the operating system to measure itself. In addition, when comparing machines with different system codes, because the system CPU time is different, the error is large, so it is appropriate to use the user CPU time as the performance measurement time. Of course, when measuring the performance of the unloaded system, the response time is more appropriate, while the CPU performance should be measured by the user's CPU time. The following mainly discusses the CPU performance measured by the user's CPU time [1]

CPU performance

Announce
edit
Most computers use clocks that run at a fixed rate. Their running cycles are called clocks, which are often expressed in terms of time or running speed. The time needed for a program to run on the CPU (Tcpu) can be expressed by the following formula:
Where,
Indicates the total number of instructions in the program to be executed, CPI indicates the average number of clock cycles required to execute each instruction, and Tc indicates the length of the clock cycle. It can be seen from the above formula that the user CPU time depends on three characteristics: clock cycle (or rate), the number of time cycles required for each instruction and the number of instructions in the program. It mainly depends on machine instruction system and compilation technology. CPI is mainly related to computer composition and instruction system, while Tc is mainly determined by hardware technology and computer composition. The average number of clock cycles required by each instruction (CPI) can be expressed by the following formula:
Where, Ii represents the number of class i instructions executed in the program, CPIi represents the average number of cycles required to execute a class i instruction, and n represents the number of all instruction classes in the program. The above formula can also be rewritten as:
Among them,
Represents the proportion of class i instructions in the program [1]

MIPS

Announce
edit
MIPS (Million Instruction Per Second) refers to the number of million instructions per second. This is a scale used to describe computer performance. For a given program, MIPS can be defined as:
formula
Obviously, the faster the machine is, the higher and smaller its MIPS will be. However, MIPS has three defects:
  1. one
    MIPS depends on the instruction set, so it is not accurate to use MIPS to compare the performance of machines with different instruction sets.
  2. two
    On the same machine, MIPS varies with different programs, sometimes very large.
  3. three
    MIPS may be the opposite of performance!
A typical example is a machine with optional hardware floating-point arithmetic units. Because floating-point operations are much slower than integer operations, many machines provide optional hardware floating-point operations. However, the MIPS of software for floating-point operations is high, while the time for hardware to implement floating-point operations is small. At this time, MIPS is just the opposite of machine performance. A similar situation occurs in compilers with optimization functions.
In addition, when using MIPS, you should pay attention to its application range. It is only suitable for evaluating scalar machines, because executing an instruction in a scalar machine can generally get one operation result, while executing a vector instruction in a vector machine can usually get many operation results. Therefore, it is not appropriate to use MIPS to measure a vector machine. In MIPS, not only operation instructions, but also all service instructions, such as fetching, saving, and transferring, are counted, while in floating point operations, service instructions are not counted.

MELOPS

Announce
edit
Another alternative standard is MFLOPS (Million Floating Point Operation Per Second), which represents millions of floating point operations per second. MFLOPS can be expressed as follows:
formula
Obviously, MFLOPS depends on both the machine and the program. Therefore, MFLOPS can only be used to measure the performance of machine floating-point operations, and cannot reflect the overall performance of the machine. For example, no matter how good the performance of the compiler is, its MFLOPS will not be too high.
However, because MFLOPS is based on operations rather than instructions, it can be used to compare two different machines. Because the instructions executed by the same program on different machines may be different, but the floating-point operations executed by the same program are identical. However, MFLOPS is not reliable, because the floating point operation sets are different on different machines. For example, CRAY-2 does not have a division instruction, while Motorala 68882 does. In addition, MFLOPS also depends on the operation type. For example, 100% floating-point addition is much faster than 100% floating-point division. The MFLOPS value of a single program does not reflect the performance of the machine. So MFLOPS is not a very useful alternative standard.

Benchmarking Procedure

Announce
edit
When evaluating a computer system, it is not only related to the structure, function and other characteristic parameters of the evaluated machine, but also closely related to the input, that is, the workload of the computer system. A computer system being evaluated tends to show high performance for one kind of workload, while it may show low performance for another kind of workload. In order to objectively evaluate the performance of the computer system, it is necessary to select a real representative workload. Usually, different levels of benchmark programs are used to evaluate system performance.
  1. one
    Use actual applications. For example, various compilers developed by C language or C++; Photoshop graphics processing software, Premiere and CAD tool software.
  2. two
    Adopt core procedures. This is to extract a small number of key cycle program segments from the actual program and use them to evaluate the performance, but these core programs only have the value of evaluating the performance.
  3. three
    Toy benchmark test procedure. The toy benchmark program usually has only 10~100 lines and the running results are predictable. It is popular because it is small and easy to type and suitable for any machine.
  4. four
    Synthetic test procedure. It is similar to the core program method, but this synthetic test is artificially prepared. The popular synthetic test programs include WinBench 99, 3DMMARK2001, WhatCPUIs, and so on. In particular, WinBench 99 provides very convincing and authoritative test results. Therefore, when most newspapers introduce new hardware, the data they provide are all from the test results of WinBench 99.
Relevant experts analyzed the above methods and concluded the following deficiencies:
  1. one
    All the above methods try to use a test data to characterize the processing power of the computer.
  2. two
    The above methods are only used for performance testing, without performance analysis.
Through the above analysis, a relatively complete and comprehensive performance evaluation method is proposed, including two parts:
  1. one
    Computer performance test.
  2. two
    Analysis of test data.