This preview shows page 1. Sign up to view the full content.
Unformatted text preview: iate rounding to the result. A floating-point operation can begin as soon as it is detected in the instruction pipeline (that is, before the ARM handshake has occurred), but the result write-back must await the handshake. Floating-point context switches The FPA registers represent additional process state which must be saved and restored across context switches. However, typically only a small number of active processes use floating-point instructions. Therefore saving and restoring the FPA registers on every switch is an unnecessary overhead. Instead, the software minimizes the number of saves and restores by the following algorithm: When a process using the FPA is switched out, the FPA registers are not saved but the FPA is turned off. 168 Architectural Support for High-Level Languages If a subsequent process executes a floating-point instruction this will trap; the trap code will save the FPA state and enable the FPA. Thus the FPA state saving and restoring overhead is only incurred for processes which use the FPA; in a typical system with only one process using the FPA, the overhead is avoided altogether. FPA10 applications TheVFPIO The FPA10 is used as a macrocell on the ARM7500FE chip (see Section 13.5 on page 360). A much higher performance floating-point unit, the VFP10, has been designed to operate with the ARM10TDMI processor core (see Section 12.6 on page 341). The VFP10 supports a different floating-point instruction set from the FPA 10 that includes support for vector floating-point operations. 6.5 Expressions
Unsigned arithmetic on an n-bit integer is defined in ANSI C to be modulo 2", so overflow cannot occur. Therefore the basic ARM integer data processing instructions implement most of the C integer arithmetic, bit-wise and shift primitives directly. Exceptions are division and remainder which require several ARM instructions. Register use Since all data processing instructions operate only on values in register, the key to the efficient evaluation of a complex expression is to get the required values into the registers in the right order and to ensure that frequently used values are normally resident in r...
View Full Document
- Spring '09