Zilog Z80380 Manuel d'utilisateur Page 31

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 268
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 30
4-6
Z380
USER'S MANUAL
DC-8297-03
ZILOG
4.2.6 Program Counter Relative Mode (RA) (Continued)
PCz PC
Before instruction execution 0000 1000
After instruction execution 0000 0FFE
Address calculation: In Native mode, –2 is encoded as
0FEH in the instruction, and it is sign extended to a 16-bit
value before added to the Program Counter. Calculation is
done in modulo 2
16
and does not affect the Extended
portion of the Program Counter.
1000
+ FFFE
FFFE
Address calculation: Since this is a 4-byte instruction, the
PC value after fetch but before jump taking place is:
19590807
+ 00000004
1959080B
The displacement portion, –5000H, is sign extended to a
32-bit value before being added to the Program Counter.
Calculation is done in modulo 2
32
and affects the Extended
portion of the Program Counter.
1959080B
+ FFFFB000
1958B80B
2. Jump relative in Extended mode, 16-bit displacement
SETC XM ;Put it in Extended mode of operation
JR $-5000H ;Jumps to the location
;(Current PC value) – 5000H
;$ stands for current PC value
;This instruction jumps to itself.
PCz PC
Before instruction execution 1959 0807
After instruction execution 1958 B80B
Vue de la page 30
1 2 ... 26 27 28 29 30 31 32 33 34 35 36 ... 267 268

Commentaires sur ces manuels

Pas de commentaire