CO-PROCESSORS:
CPU architects often want to provide
flexibility in what features are implemented in the CPU. One way to provide such flexibility at the instruction set level
is to allow co-processors, which are attached to the CPU and implement some
of the instructions. For example, floating-point arithmetic was introduced into
the Intel architecture by providing separate chips that implemented the
floating-point instructions.
To
support co-processors, certain opcodes must be reserved in the instruction set
for co-processor operations. Because it executes instructions, a co-processor
must be tightly coupled to the CPU. When the CPU receives a co-processor
instruction, the CPU must activate the co-processor and pass it the relevant
instruction. Co-processor instructions can load and store co-processor
registers or can perform internal operations. The CPU can suspend execution to
wait for the co-processor instruction to finish; it can also take a more
superscalar approach and continue executing instructions while waiting for the
co-processor to finish.
A CPU
may, of course, receive co-processor instructions even when there is no
coprocessor attached. Most architectures use illegal instruction traps to
handle these situations. The trap handler can detect the co-processor
instruction and, for example, execute it in software on the main CPU. Emulating
co-processor instructions in software is slower but provides compatibility.
The ARM
architecture provides support for up to 16 co-processors. Co-processors are
able to perform load and store operations on their own registers. They can also
move data between the co-processor registers and main ARM registers.
An
example ARM co-processor is the floating-point unit. The unit occupies two
co-processor units in the ARM architecture, numbered 1 and 2, but it appears as
a single unit to the programmer. It provides eight 80-bit floating-point data
registers, floating-point status registers, and an optional floating-point
status register.
Related Topics
Privacy Policy, Terms and Conditions, DMCA Policy and Compliant
Copyright © 2018-2023 BrainKart.com; All Rights Reserved. Developed by Therithal info, Chennai.