We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
例如
.global my_memory_test my_memory_test: mov x1, 0x80000 mov x2, 0x200000 add x3, x1, 32 1: ldr x4, [x1], #8 str x4, [x2], #8 cmp x1, x3 b.cc 1b ret
.align 对齐,填充数据来实现对齐。可以填充0或者使用nop指令。
比如.equ abcd, 0x45 //让abcd 等于 0x45
.macro plus1 p, p1 // 定义了一个名为plus1的宏,有两个参数p,和p1。 // 在宏里使用参数需要前缀,“\p” 表示第一个参数, “\p1”表示第二个参数
.macro reserve_str p1=0 p2 // 第一个参数p1有一个初始化的值,0。这时候你可以使用reserve_str a,b或者reserve_str ,b来调用这个宏
解决办法:
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Arm64的汇编器
gas汇编器语法
例如
汇编器常用伪指令
对齐伪指令
.align 对齐,填充数据来实现对齐。可以填充0或者使用nop指令。
数据定义伪指令
比如.equ abcd, 0x45 //让abcd 等于 0x45
函数相关的伪操作
if语句
与段相关的伪操作
成对使用,仅仅是把 pushsection和popsection的圈出来的代码 加入到指定的section中,其他代码还是在原来的section
宏
解决办法:
Arm64编译选项
特殊字符
adrp x0, foo
ldr x0, [x0, #:lo12:foo ]
Arm64特有的伪操作
foo .reg w0
The text was updated successfully, but these errors were encountered: