Texas Instruments MSP50C6xx Calculator User Manual


 
MSP50P614/MSP50C614 Computational Modes
4-50
Table 441. MSP50P614/MSP50C614 Computational Modes
Computational
Mode
Setting
Instruction
Resetting
Instruction
Function
Sign extension SXM RXM STAT.XM = 1 produces sign extension on data as it is
passed into accumulators. This mode copies the 16
th
bit of
the data in the multiplier/multiplicand to the 17
th
bit. This
causes signed multiplication of two signed numbers.
STAT.XM = 0 suppresses sign extension.
Unsigned none none STAT.UM = 1 causes unsigned multiplication where the mul-
tiplier assumes its arguments as unsigned value. MOVU
instruction can be used to enable this mode. STAT.UM = 0
disables unsigned multiplication.
Overflow SOVM ROVM STAT.OM = 1 initiates overflow mode. Overflows cause the
accumulator to acquired the most positive or most negative
value. In the case of string values, only the MSB 16 bits are
modified. The remaining bits in the string are unchanged.
STAT.OM = 0 normal overflow operation and the
accumulator content is unchanged if any overflow occurs.
Affects OF bit of STAT in case of overflow.
Fractional SFM RFM STAT.FM = 1 enables fractional multiplication shift mode.
The multiplier is shifted left 1 bit to produce a 17 bit operand.
This mode is used on signed binary fractions and does not
require the user to left shift as it would have been required if
the FM bit was not set. STAT.FM = 1 turns off fractional
mode.
Sign Extension Mode: Sign extension mode can be enabled/disabled by
setting/resetting the XM bit of STAT. When in sign extension mode, a multiply
operation will copy the 16
th
bit of the multiplier/multiplicand to the 17
th
bit.
When multiplied, this will give a 17 x 17 bit multiplication producing 34-bit result
where the upper two bits (33
rd
and 34
th
bits) are the sign bits and discarded
by the processor. Sign extension is also applicable in string mode. Sign
extension mode is the recommended mode to use for signed number
multiplication.
Example 4.6.1 SXM
MOV A0, 0x8000
MOV MR, 0x8000
MULTPL A0, A0
This example illustrates the sign extension mode during multiplication. Here,
two negative number 0x8000 are multiplied with 0x8000 to obtain a positive
number 0x40000000. If the signs were not extended, we would have obtained
0xC0000000, a negative number.