To summarize in the simplest terms, it is the language used by the CPU hardware to receive instructions, complete calculations, and interact with the software when outputting results. Each new instruction generally corresponds to one or several pieces of assembly language, compiled Finally, it corresponds to the machine code that can be recognized by the CPU. Instruction set support is the result of the simultaneous action of hardware and software. If you want the CPU to support a certain instruction set, you must modify the hardware circuit. If you want the software to support a new instruction set, you must modify the program and recompile it. To perform the same operation and perform the same purpose of calculation, you can use different methods (different assembly statements, machine code). The SSE2 optimized code is the statement in the SSE2 instruction set used in the program, which can be used by the P4/K8 decoder ( The cores of the current X86 CPU are all RISC computing cores, and the decoder does the conversion work) identification to perform more efficient calculations. However, the K7 CPU does not support this code, so other methods are used to perform this operation, such as using X87 FPU instructions
The instruction set is the set of instructions that the CPU can support. Theoretically, designing a CPU requires designing the instructions that the CPU supports. If the instructions are different, the software will not be universal. The problem is that usually the lifetime of the software Longer than the CPU, so when designing the CPU at the current stage, the instruction system of the new CPU is often designed according to the instructions supported by the existing CPU, or even directly standardizes the instruction list of some existing CPUs to form a standard instruction list. In this way, as long as these instructions are supported in the future, different CPUs can be interchanged; when releasing a new CPU, it is also necessary to clearly establish an instruction code table. This standardized instruction list is the instruction set.