Accumulator (A) - Fujitsu F2MC-16LX Hardware Manual

Mb90470 series 16-bit microcontroller
Hide thumbs Also See for F2MC-16LX:
Table of Contents

Advertisement

2.3.1

Accumulator (A)

This section explains the accumulator (A) functions.
I Accumulator (A)
An accumulator (A) consists of two 16-bit arithmetic operation registers (AH/AL) that are used to
store operation results and temporarily store data transfer results. For 32-bit data processing,
AH is connected with AL. For word processing in the 16-bit data processing mode and for byte
processing in the 8-bit data processing mode, only AL is used. Data stored in an accumulator
(A) is used together with that in memory and registers (Ri, Rwi, Rli); and similar to F
operations, the data item with a smaller word length is transferred to AL. This enables data
items in AL before the transfer to be automatically transferred to AH (data hold function). The
data hold function and operation between AL-AH support improvements in processing
efficiency.
During a transfer of a data item with a lower byte length to AL, a sign extension or zero
extension is added to the data, and the data is saved in AL as a 16-bit data item. Also, data in
AL is handled in either word lengths or byte lengths.
If an arithmetic operation instruction of byte processing is executed in AL, the upper 8 bits in AL
before the operation is ignored, and the upper 8 bits of operation results are reset to zero.
Resetting an accumulator (A) does not initialized it, and it has an undefined value after the
reset.
Figure 2.3-3 "32-bit data transfer" shows 32-bit data transfer processing, and Figure 2.3-4 "AL-
AH transfer" shows AL-AH transfer processing.
A before execution
A after execution
A before execution
A after execution
Figure 2.3-3 32-bit data transfer
MOVL A,@RW1+6
XXXX
XXXX
H
H
DTB
A6
8F74
2B52
H
H
Figure 2.3-4 AL-AH transfer
MOVW A,@RW1+6
XXXX
1234
H
H
A6
DTB
1234
2B52
H
H
MSB
A61540
H
A6153E
H
H
+6
RW1
MSB
A61540
H
A6153E
H
H
+6
RW1
CHAPTER 2 CPU
LSB
8F
74
H
H
2B
52
H
H
15
38
H
H
LSB
8F
74
H
H
2B
52
H
H
15
38
H
H
2
MC-8L
29

Advertisement

Table of Contents
loading

Table of Contents