当前位置:网站首页>ARM processor mode and register
ARM processor mode and register
2022-06-12 11:49:00 【fanxiaoyu321】
List of articles
Pattern
Different architectures define different patterns , But they are backward compatible , Here is ARM920T CPU Supported processor modes .
| Schema name | Code | describe |
|---|---|---|
| User(USR) | 10000 | The user mode in which most applications run , Also called non privileged mode |
| FIQ | 10001 | FIQ Abnormal interruption |
| IRQ | 10010 | IRQ Abnormal interruption |
| Supervisor(SVC) | 10011 | The management call instruction is executed or reset When |
| Monitor(MON) | 10110 | Security extension mode , For safety purposes only |
| Abort(ABT) | 10111 | Storage access mode |
| Hyp(HYP) | 11010 | Virtualization extension |
| Undef(UND) | 10011 | When the instruction execution is not defined |
| System(SYS) | 11111 | System mode , The pattern is related to USR Mode shared register |
The above modes are in addition to USR Out of mode , Other modes belong to privileged mode .
register

General registers
R0—R12 this 13 This is called a general purpose register , Generally speaking, they can be used for any purpose .
R13: Also called sp, Usually used as a stack pointer , Note that each pattern has its own R13 Register copy .
R14: Also called lr( Connection register ). This register serves two purposes : One is when subroutines are called ,lr Used to save the return address ; Second, when an abnormal interrupt occurs , The specific physics of the exception pattern lr The register is set to the address to be returned by the exception mode ( This step is done automatically by hardware ).
R15: Also called pc, Program counter , Always save the current address ( Pay attention to assembly line technology ) The address of the instruction . stay ARM State, , It differs from the address of the instruction currently being executed 8 Bytes (3 Class assembly line ).
Status register
CPSR( Current program status register ) Can be accessed in any processor mode , It contains conditional flag bits 、 Interrupt inhibit bit 、 The current processor mode flag and other control and status bits , The format is shown in the figure . Besides , There is also a dedicated physical status register for each exception mode , be called SPSR( Backup program status register ), When a particular exception occurs , This register is used to store CPSR The content of , When the exception mode returns , It can be used SPSR To restore CPSR.
- M: Processor mode bit , By modifying this section , You can switch the operating mode of the processor ;
- T: Identify whether you are currently using Thumb Instructions ,0 by ARM Command mode ,1 by Thumb Command mode ;
- F:FIQ Disable flag bit , If 1, Then disable FIQ,0 To open ;
- I: Allied , This is a IRQ Disable flag bit ;
- V:ALU Operation overflow flag ;
- C:ALU Carry mark ;
- Z:ALU Zero mark ;
- N:ALU negative ;
Instruction set
ARM The following commands are supported .


Instruction condition code
Almost all ARM Instructions can carry condition codes , Make the instruction execute only when the condition is satisfied , The supported condition codes are as follows :

边栏推荐
猜你喜欢

转载--win10打开任务管理器就蓝屏的问题

LeetCode 1037. 有效的回旋镖(向量叉乘)

UML series articles (31) architecture modeling - deployment diagram

Logrotate log rotation method create and copyruncate principles

Blue Bridge Cup 2015 CA provincial competition (filling the pit)

TinyMCE realizes automatic uploading of pasted pictures

5g NR Protocol Learning - - ts38.211 downlink channel

PDSCH related

Windows10 install mysql-8.0.28-winx64

C# 35. Select default network card
随机推荐
第六章 数据类型(五)
PIP install in the CONDA environment cannot be installed into the specified CONDA environment (the default PIP installation location of the CONDA environment)
Architecture training module 7
Node crawler puppeter usage
进程的创建和回收
Design of virtual scrolling list
[Blue Bridge Cup SCM 11th National race]
C# 35. Select default network card
Lambda expression | shallow solution
C# 37. textbox滚动条与多行
C# 36. DataGridView line number
The second regular match is inconsistent with the first one, and the match in the regular loop is invalid
Pessimistic lock and optimistic lock of MySQL
Mysql45 lecture 01 | infrastructure: how is an SQL query executed?
转载--win10打开任务管理器就蓝屏的问题
Lambda and filter, index of list and numpy array, as well as various distance metrics, concatenated array and distinction between axis=0 and axis=1
5G NR协议学习--TS38.211下行通道
ARM指令集之Load/Store指令寻址方式(二)
Unity connect to Microsoft SQLSERVER database
Windows10 install mysql-8.0.28-winx64