|
|
 |
|
|
|
|
and, or, not, xor, shift, rotate, |
|
|
|
 |
|
|
|
|
jump, branch, trap. |
|
|
|
|
|
|
|
|
Many machines have included additional instructions that many still consider to be part of the common core of operations: |
|
|
|
|
|
|
|
|
Floating-point arithmetic: |
|
|
|
 |
|
|
|
|
add, subtract, multiply, divide, square root |
|
|
|
 |
|
|
|
|
extract, insert, test, set, clear |
|
|
|
 |
|
|
|
|
less than or equal to, odd parity, carry |
|
|
|
|
|
|
|
|
Depending on the application of the machine, operations may be included for character translation and coding (IBM S/390), decimal number manipulation (many business-targeted machines), enhanced math support (including transcendental and other functions), and so forth. Many machines even provide combination instructions (such as test and branch, multiply then add, etc.). |
|
|
|
|
|
|
|
|
The addition of complex instructions to a machine has come back to haunt some designers. The DEC VAX, the Intel x86, and the Motorola 680x0 included a complex set of instructions to provide comprehensive facilities for the programmer. As the later models of these machines have been developed, many of the more complex (and less frequently used) instructions have been moved outside of a highly streamlined core processor to a separate microprogrammed processor or left entirely to software emulation. As the relative use of these instructions is very low, the practice of restricting the core processor to the commonly used operations has led to significant performance improvements in the majority of applications. Of course, those processes that use the emulated instructions frequently show dramatic performance degradation. |
|
|
|
|
|
|
|
|
There is considerable diversity between machines with regard to simple operations alone. Figure 1.14 illustrates the situation for the ADD operation. Some machines have several different varieties of instructions to account for specific cases, such as unsigned or extended precision instructions. For example, as shown in Table 1.5, the IBM S/390 has about 10 ADD instructions, while the VAX has more than 25 different forms for ADD instructions. VAX programming is not for the faint of heart! In contrast, the MIPS R2000 has only four ADD instructions. The R2000 is closely coupled with the R2010 floating-point unit, which provides several additional ADD operations. The variety of types of ADD is shown for each machine in Tables 1.61.8. |
|
|
|
 |
|
 |
|
|
7In this text, jump and branch are synonymous, with branch the preferred usage. |
|
|
|
|
|