Integer Instructions
MOTOROLA M68000 FAMILY PROGRAMMER’S REFERENCE MANUAL 4-195
UNPK Unpack BCD UNPK
(MC68020, MC68030, MC68040)
Operation: Source (Packed BCD) + Adjustment → Destination (Unpacked BCD)
Assembler UNPACK – (Ax), – (Ay),# < adjustment >
Syntax: UNPK Dx,Dy,# < adjustment >
Attributes: Unsized
Description: Places the two binary-coded decimal digits in the source operand byte into the
lower four bits of two bytes and places zero bits in the upper four bits of both bytes.
Adds the adjustment value to this unpacked value. Condition codes are not altered.
When both operands are data registers, the instruction unpacks the source register
contents, adds the extension word, and places the result in the destination register.
The high word of the destination register is unaffected.
Source:
Intermediate Expansion:
Add Adjustment Word:
Destination:
1514131211109876543210
uuuuuuuuabcdefgh
Dx
1514131211109876543210
0000abcd0000efgh
1514131211109876543210
16-BIT EXTENSION
1514131211109876543210
vvvva’b’c’d’wwwwe’f’g’h’
Dy
Comments to this Manuals