145
11100B–ATARM–31-Jul-12
SAM4S Series [Preliminary]
11.6.6.9
SMUAD and SMUSD
Signed Dual Multiply Add and Signed Dual Multiply Subtract
Syntax
op{X}{cond} Rd, Rn, Rm
where:
Operation
The
SMUAD
instruction interprets the values from the first and second operands as two signed
halfwords in each operand. This instruction:
• Optionally rotates the halfwords of the second operand.
• Performs two signed 16 × 16-bit multiplications.
• Adds the two multiplication results together.
• Writes the result of the addition to the destination register.
The
SMUSD
instruction interprets the values from the first and second operands as two’s comple-
ment signed integers. This instruction:
• Optionally rotates the halfwords of the second operand.
• Performs two signed 16 × 16-bit multiplications.
• Subtracts the result of the top halfword multiplication from the result of the bottom halfword
multiplication.
• Writes the result of the subtraction to the destination register.
Restrictions
In these instructions:
• Do not use SP and do not use PC.
Condition Flags
Sets the Q flag if the addition overflows. The multiplications cannot overflow.
op
is one of:
SMUAD
Signed Dual Multiply Add.
SMUADX
Signed Dual Multiply Add Reversed.
SMUSD
Signed Dual Multiply Subtract.
SMUSDX
Signed Dual Multiply Subtract Reversed.
If
X
is present, the multiplications are bottom × top and top × bottom.
If the
X
is omitted, the multiplications are bottom × bottom and top × top.
cond
is an optional condition code, see
Rd
is the destination register.
Rn, Rm
are registers holding the first and the second operands.
Summary of Contents for SAM4S Series
Page 44: ...44 11100B ATARM 31 Jul 12 SAM4S Series Preliminary ...
Page 412: ...412 11100B ATARM 31 Jul 12 SAM4S Series Preliminary ...
Page 1105: ...1105 11100B ATARM 31 Jul 12 SAM4S Series Preliminary ...
Page 1143: ...1143 11100B ATARM 31 Jul 12 SAM4S Series Preliminary Figure 43 4 64 lead LQFP Package Drawing ...
Page 1145: ...1145 11100B ATARM 31 Jul 12 SAM4S Series Preliminary Figure 43 5 64 lead QFN Package Drawing ...