Arm VERSION 1.2 Manuel d'utilisateur Page 223

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 360
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 222
Thumb Instruction Reference
ARM DUI 0068B Copyright © 2000, 2001 ARM Limited. All rights reserved. 5-29
Condition flags
MOV Rd,#expr
and
MVN
instructions update the N and Z flags. They have no effect on the
C or V flags.
NEG
instructions update the N, Z, C, and V flags.
MOV Rd, Rm
behaves as follows:
if either
Rd
or
Rm
is a high register (
r8
-
r15
), the flags are unaffected
if both
Rd
and
Rm
are low registers (
r0
-
r7
), the N and Z flags are updated, and C
and V flags are cleared.
Note
You can use
LSL
, with a shift of zero, to move between low registers without
clearing the C and V flags (see ASR, LSL, LSR, and ROR on page 5-24).
Architectures
These instructions are available in all T variants of the ARM architecture.
Examples
MOV r3,#0
MOV r0,r12 ; does not update flags
MVN r7,r1
NEG r2,r2
Incorrect examples
MOV r2,#256 ; immediate value out of range
MOV r8,#3 ; cannot move immediate to high register
MVN r8,r2 ; high registers not allowed with MVN or NEG
NEG r0,#3 ; immediate value not allowed with MVN or NEG
Vue de la page 222
1 2 ... 218 219 220 221 222 223 224 225 226 227 228 ... 359 360

Commentaires sur ces manuels

Pas de commentaire