当前位置:网站首页>Summary of stack frame in arm assembly
Summary of stack frame in arm assembly
2022-06-25 02:26:00 【Hua Weiyun】
What is a stack frame ?
1. Stack is a kind of data organization with last in first out , That is to say, those stored later shall be taken out first , Store first and then take out . The bottom of the stack is where the first data in the stack is located , The top of the stack is where the last data is put into the stack .

Stack frame (stack frame): Is the part of the stack used by a function , The stack frames of all functions are strung together to form a complete stack . The two boundaries of the stack frame are respectively defined by fp(r11) and sp(r13) To limit .
How do stack frames come into being ? When the stack top pointer sp Less than the pointer at the bottom of the stack fp when , The stack frame is formed .
The use of stack frames in functions ?
ARM The order of stack pressing is very regular , In order is the current function pointer PC、 Return pointer LR、 Stack pointer SP、 Stack base address FP、 The number of parameters and pointers passed in 、 Local variables and temporary variables .
ARM The following statements are often used for function stack pressing and stack pushing :
stmfd sp!,{r0-r9, lr} ; Full decrement stack , Give the register r0-r9,lr Pressing stack ,sp Decreasing 4.
ldmfd sp!,{r0-r9, pc} ; Full decrement stack , Give the register r0-r9 Out of the stack , And make the program jump back to the call point of the function ,sp Increasing 4.
边栏推荐
- ProcessOn制作ER过程(自定义)
- 基本布局-QHBoxLayout类、QVBoxLayout类、QGridLayout类
- 保险APP适老化服务评测分析2022第06期
- 字符串数组转换为list集合
- QT package the EXE file to solve the problem that "the program input point \u zdapvj cannot be located in the dynamic link library qt5cored.dll"
- AI服装生成,帮你完成服装设计的最后一步
- Redistemplate operates redis. This article is enough (I) [easy to understand]
- 计网 | 【四 网络层】知识点及例题
- Jetson Nano 从入门到实战(案例:Opencv配置、人脸检测、二维码检测)
- 做软件安全测试的作用,如何寻找软件安全测试公司出具报告?
猜你喜欢

Test / development programmers, 30, do you feel confused? And where to go

Hashcat 的使用

Are programmers from Huawei, Alibaba and other large manufacturers really easy to find?
![[STL source code analysis] configurator (to be supplemented)](/img/87/0ed1895e9cdb5327411c0c9cb0197f.png)
[STL source code analysis] configurator (to be supplemented)

【Proteus仿真】Arduino UNO+数码管显示4x4键盘矩阵按键
Cusdis - 轻量级、隐私优先的开源评论系统 | 倾城之链

一线城市软件测试工资——你拖后腿了吗
![[analysis of STL source code] functions and applications of six STL components (directory)](/img/f2/872fd93ef52b1424343ba634be24f6.png)
[analysis of STL source code] functions and applications of six STL components (directory)

Pit entry machine learning: I. Introduction

Intranet learning notes (7)
随机推荐
3 years of testing experience. I don't even understand what I really need on my resume. I need 20K to open my mouth?
当他们在私域里,掌握了分寸感
把 Oracle 数据库从 Windows 系统迁移到 Linux Oracle Rac 集群环境(1)——迁移数据到节点1
Please run IDA with elevated permissons for local debugging.
Computing service network: a systematic revolution of multi integration
如何通过EasyCVR接口监测日志观察平台拉流情况?
背了八股文,六月赢麻了……
F - spices (linear basis)
实战攻防演练中的四大特点
把 Oracle 数据库从 Windows 系统迁移到 Linux Oracle Rac 集群环境(2)——将数据库转换为集群模式
Intranet learning notes (7)
Left hand dreams right hand responsibilities GAC Honda not only pays attention to sales but also children's safety
Logminer database log mining
Using qdomdocument to manipulate XML files in QT
02 common codes for Epicor secondary development
Once beego failed to find bee after passing the go get command Exe's pit
random list随机生成不重复数
It is said that Yijia will soon update the product line of TWS earplugs, smart watches and bracelets
ARM汇编中的栈桢小结
MOS管相关知识