ARM ARM7TDMI User Manual Page 27

  • Download
  • Add to my manuals
  • Print
  • Page
    / 43
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 26
Page 23
4.19 MRS – Move PSR into General-Purpose Register
Syntax:
MRS{<cond>} <Rd >, CPSR
MRS{<cond>} <Rd >, SPSR
RTL:
if(cond)
Rd CPSR/SPSR
Flags updated:
None
Encoding:
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
cond 0 0 0 1 0 R 0 0 SB0 Rd SB0
Usage and Examples:
Moves the value of CPSR or the current SPSR into a general-purpose register.
MRS R0, CPSR
4.20 MSR – Move to Status Register from ARM Register
Syntax:
MSR{<cond>} CPSR_<fields>, #<immediate>
MSR{<cond>} CPSR_<fields>, <Rm>
MSR{<cond>} SPSR_<fields>, #<immediate>
MSR{<cond>} SPSR_<fields>, <Rm>
RTL:
if(cond)
CPSR/SPSR immediate/register value
Flags updated:
N/A
Encoding:
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
cond 0 0 1 1 0 R 1 0 field_mask SB0 rotate_imm immediate
cond 0 0 0 1 0 R 1 0 field_mask SB0 SBZ 0 0 0 0 Rm
Usage and Examples:
Moves the value of a register or immediate operand into the CPSR or the current SPSR.
This instruction is typically used by supervisory mode code. Further details on this
instruction can be found in the ARM Architecture Reference Manual.
Page view 26
1 2 ... 22 23 24 25 26 27 28 29 30 31 32 ... 42 43

Comments to this Manuals

No comments