Section 2
CPU
Rev. 1.00 Mar. 12, 2008 Page 43 of 1178
REJ09B0403-0100
Table 2.4
Arithmetic Operations Instructions (2)
Instruction Size
*
1
Function
DIVXS
B/W
Rd ÷ Rs
→
Rd
Performs signed division on data in two general registers: either 16 bits
÷ 8 bits
→
8-bit quotient and 8-bit remainder or 32 bits ÷ 16 bits
→
16-bit
quotient and 16-bit remainder.
CMP
B/W/L
Rd – Rs, Rd – #IMM
Compares data in a general register with data in another general
register or with immediate data, and sets CCR bits according to the
result.
NEG
B/W/L
0 – Rd
→
Rd
Takes the two’s complement (arithmetic complement) of data in a
general register.
EXTU
W/L
Rd (zero extension)
→
Rd
Extends the lower 8 bits of a 16-bit register to word size, or the lower 16
bits of a 32-bit register to longword size, by padding with zeros on the
left.
EXTS
W/L
Rd (sign extension)
→
Rd
Extends the lower 8 bits of a 16-bit register to word size, or the lower 16
bits of a 32-bit register to longword size, by extending the sign bit.
TAS
*
2
B
@ERd – 0, 1
→
(<bit 7> of @ERd)
Tests memory contents, and sets the most significant bit (bit 7) to 1.
MAC
(EAs)
×
(EAd) + MAC
→
MAC
Performs signed multiplication on memory contents and adds the result
to the multiply-accumulate register. The following operations can be
performed:
16 bits
×
16 bits + 32 bits
→
32 bits, saturating
16 bits
×
16 bits + 42 bits
→
42 bits, non-saturating
CLRMAC
0
→
MAC
Clears the multiply-accumulate register to zero.
LDMAC
STMAC
L Rs
→
MAC, MAC
→
Rd
Transfers data between a general register and a multiply-accumulate
register.
Note: 1
.
Refers to the operand size.
B:
Byte
W:
Word
L:
Longword
2. Only register ER0, ER1, ER4, or ER5 should be used when using the TAS instruction.
Summary of Contents for H8S Family
Page 2: ...Rev 1 00 Mar 12 2008 Page ii of xIviii...
Page 8: ...Rev 1 00 Mar 12 2008 Page viii of xIviii...
Page 28: ...Rev 1 00 Mar 12 2008 Page xxviii of xIviii...
Page 48: ...Rev 1 00 Mar 12 2008 Page xlviii of xIviii...
Page 70: ...Section 1 Overview Rev 1 00 Mar 12 2008 Page 22 of 1178 REJ09B0403 0100...
Page 108: ...Section 2 CPU Rev 1 00 Mar 12 2008 Page 60 of 1178 REJ09B0403 0100...
Page 116: ...Section 3 MCU Operating Modes Rev 1 00 Mar 12 2008 Page 68 of 1178 REJ09B0403 0100...
Page 152: ...Section 5 Interrupt Controller Rev 1 00 Mar 12 2008 Page 104 of 1178 REJ09B0403 0100...
Page 206: ...Section 6 Bus Controller BSC Rev 1 00 Mar 12 2008 Page 158 of 1178 REJ09B0403 0100...
Page 420: ...Section 9 14 Bit PWM Timer PWMX Rev 1 00 Mar 12 2008 Page 372 of 1178 REJ09B0403 0100...
Page 476: ...Section 12 Watchdog Timer WDT Rev 1 00 Mar 12 2008 Page 428 of 1178 REJ09B0403 0100...
Page 552: ...Section 14 CRC Operation Circuit CRC Rev 1 00 Mar 12 2008 Page 504 of 1178 REJ09B0403 0100...
Page 712: ...Section 18 I2 C Bus Interface IIC Rev 1 00 Mar 12 2008 Page 664 of 1178 REJ09B0403 0100...
Page 804: ...Section 19 LPC Interface LPC Rev 1 00 Mar 12 2008 Page 756 of 1178 REJ09B0403 0100...
Page 838: ...Section 20 Ethernet Controller EtherC Rev 1 00 Mar 12 2008 Page 790 of 1178 REJ09B0403 0100...
Page 964: ...Section 24 RAM Rev 1 00 Mar 12 2008 Page 916 of 1178 REJ09B0403 0100...
Page 1066: ...Section 25 Flash Memory Rev 1 00 Mar 12 2008 Page 1018 of 1178 REJ09B0403 0100...
Page 1098: ...Section 26 Boundary Scan JTAG Rev 1 00 Mar 12 2008 Page 1050 of 1178 REJ09B0403 0100...
Page 1226: ...Rev 1 00 Mar 12 2008 Page 1178 of 1178 REJ09B0403 0100...
Page 1229: ......
Page 1230: ...H8S 2472 Group H8S 2462 Group Hardware Manual...