Qdatasheet_Logo
Integrated circuits, Transistor, Semiconductors Search and Datasheet PDF Download Site

ST20-C1 View Datasheet(PDF) - STMicroelectronics

Part Name
Description
MFG CO.
ST20-C1
ST-Microelectronics
STMicroelectronics ST-Microelectronics
'ST20-C1' PDF : 205 Pages View PDF
5 Multiply accumulate
5.6.3 Pre-scaling and rounding - smacloop
The initial accumulator value must be loaded into the accumulator for the start of the
smacloop instruction. The initial accumulator is either in Q31 format (LongMode), or
Q15 format (ShortMode) and is handled accordingly.
In LongMode,
left shift by 7 places (right 1 + left 8)
sign extend from bit 38 to the most significant bit
set bit 6 = 1 (for rounding)
In ShortMode,
left shift by 23 places (left 15 + left 8)
sign extend from bit 38 to the most significant bit
set bit 22 = 1 (for rounding)
Note that rounding is achieved by adding half of the least significant bit to the initial
value, which by associativity is equivalent to adding it to the final value.
5.6.4 Pre-scaling and rounding - biquad
The biquad instruction starts with an empty accumulator. Since the result is always
Q15 (equivalent to ShortMode), rounding is achieved by loading the accumulator with
222 (which is half of the least significant bit of the result).
5.6.5 Post-scaling and saturation - smacloop
At the end of a smacloop instruction the final accum ulator value is saturated and
scaled to the appropriate format, according to mac_mode.
If either the overflow or underflow bits in the status register are set, then the final value
is set to the appropriate exceptional value from Table 5.6. Note that this does not
involve testing the accumulator value, which is considered to be invalid if either of
these status register bits are set.
Otherwise, when the status register reports no overflow or underflow, bits 38 to 47
inclusive of the accumulator are tested for mutual equality. If they are all the same, the
accumulator value is well-formed and post-scaling is applied to produce the final accu-
mulator value.
In LongMode,
arithmetic right shift by 7 places(left 1 + right 8)
truncate to low 32 bits
In ShortMode,
arithmetic right shift by 23 places (right 15 + right 8)
truncate to low 32 bits
63/205
®
Share Link: GO URL

All Rights Reserved © qdatasheet.com  [ Privacy Policy ] [ Contact Us ]