EasyManuals Logo

Texas Instruments TMS320C28x User Manual

Texas Instruments TMS320C28x
695 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #360 background imageLoading...
Page #360 background image
MOVH loc16, P
6-203
MOVH loc16, P Save High Word of the P Register
SYNTAX OPTIONS OPCODE OBJMODE RPT CYC
MOVH loc16,P 0101 0111 LLLL LLLL X Y N+1
Operands loc16 Addressing mode (see Chapter 5)
P Product register
Description The contents of the P register are shifted by the amount specified in the
product shift mode (PM), and the upper half of the shifted value is stored into
the 16-bit location pointed to by the “loc16” addressing mode. The P register
is not modified by the operation:
[loc16] = (P << PM) >> 16;
Flags and
Modes
N If (loc16 = @AX) and bit 15 of the AX register is 1, then the N bit is set;
otherwise, N is cleared.
Z If (loc16 = @AX) and the value of AX after the load is zero, then the Z bit is
set; otherwise Z is cleared.
PM The value in the PM bits sets the shift mode for the output operation from the
product register. If the product shift value is positive (logical left shift
operation), then the low bits are zero filled. If the product shift value is
negative (arithmetic right shift operation), the upper bits are sign extended.
Repeat This instruction is repeatable. If the operation follows a RPT instruction, then
it will be executed N+1 times. The state of the Z, and N flags will reflect the
final result.
Example
; Calculate Y32 = M16*X16 >> 6
MOV T,@M16 ; T = M
MPY P,T,@X16 ; P = T * X
SPM −6 ; Set product shift to >> 6
MOV @Y32+0,P ; Y32 = P >> 6
MOVH @Y32+1,P

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TMS320C28x and is the answer not in the manual?

Texas Instruments TMS320C28x Specifications

General IconGeneral
BrandTexas Instruments
ModelTMS320C28x
CategoryProcessor
LanguageEnglish

Related product manuals