Standard Functions - Analog Devices adsp-2100 Manual

Adsp-2100 family programmable single-chip microprocessors
Table of Contents

Advertisement

Any of the registers associated with the ALU can be both read and written in
the same cycle. Registers are read at the beginning of the cycle and written at
the end of the cycle. A register read, therefore, reads the value loaded at the
end of a previous cycle. A new value written to a register cannot be read out
until a subsequent cycle. This allows an input register to provide an operand to
the ALU at the beginning of the cycle and be updated with the next operand
from memory at the end of the same cycle. It also allows a result register to be
stored in memory and updated with a new result in the same cycle. See the
discussion of "Multifunction Instructions" in Chapter 15, "Instruction Set
Reference" for an illustration of this same-cycle read and write.
The ALU contains a duplicate bank of registers, shown in Figure 2.2 behind the
primary registers. There are actually two sets of AR, AF, AX, and AY register
files. Only one bank is accessible at a time. The additional bank of registers can
be activated (such as during an interrupt service routine) for extremely fast
context switching. A new task, like an interrupt service routine, can be
executed without transferring current states to storage.
The selection of the primary or alternate bank of registers is controlled by bit 0
in the processor mode status register (MSTAT). If this bit is a 0, the primary
bank is selected; if it is a 1, the secondary bank is selected.
2.2.2

Standard Functions

The standard ALU functions are listed below.
R = X + Y
R = X + Y + CI
R = X – Y
R = X – Y + CI - 1
R = Y – X
R = Y – X + CI - 1
R = – X
R = – Y
R = Y + 1
R = Y – 1
R = PASS X
R = PASS Y
R = 0 (PASS 0)
R = ABS X
R = X AND Y
R = X OR Y
R = X XOR Y
R = NOT X
R = NOT Y
Computational Units
Add X and Y operands
Add X and Y operands and carry-in bit
Subtract Y from X operand
Subtract Y from X operand with "borrow"
Subtract X from Y operand
Subtract X from Y operand with "borrow"
Negate X operand (twos-complement)
Negate Y operand (twos-complement)
Increment Y operand
Decrement Y operand
Pass X operand to result unchanged
Pass Y operand to result unchanged
Clear result to zero
Absolute value of X operand
Logical AND of X and Y operands
Logical OR of X and Y operands
Logical Exclusive OR of X and Y operands
Logical NOT of X operand (ones-complement)
Logical NOT of Y operand (ones-complement)
2
2 – 7

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents