ARM base instruction -- cinc

Conditional Increment returns, in the destination register, the value of the source register incremented by 1 if the condition is TRUE, and otherwise returns the value of the source register.

如果条件为TRUE,则条件增量在目标寄存器中返回源寄存器的值加1,否则返回源寄存器。

32-bit variant

Applies when sf == 0.

CINC <Wd>, <Wn>, <cond>

64-bit variant

Applies when sf == 1.

CINC <Xd>, <Xn>, <cond>

Decode for all variants of this encoding

integer d = UInt(Rd);

integer n = UInt(Rn);

integer datasize = if sf == '1' then 64 else 32;

Operation

bits(datasize) result;

bits(datasize) operand1 = X[n];

if ConditionHolds(cond) then

result = operand1 + 1;

else

result = operand1;

X[d] = result;

404288: 710002ff cmp w23, #0x0 // w23=0

40428c: aa1b03fc mov x28, x27 // x28=x27=walk->next

404290: 110006f7 add w23, w23, #0x1 // w23=w23+1 count++

404294: 1a94069b cinc w27, w20, ne // w27=0, w20=0; if ConditionHolds(cond) then w27=w20+1=1

404298: 17ffffd2 b 4041e0 <ferror@plt+0x2300>

相关推荐
旧梦吟10 小时前
脚本语言 汇编
汇编
iCxhust11 小时前
8088单板机C语言汇编混合编程实验方法与步骤
c语言·汇编·单片机·嵌入式硬件·微机原理
元亓亓亓16 小时前
考研408--组成原理--day8--汇编指令&不同语句的机器级表示
开发语言·汇编·c#
缘友一世1 天前
计算系统安全速成之机器级编程(数组和指针)【3】
汇编·计算机组成原理·数组和指针
切糕师学AI1 天前
ARM 汇编指令:LDR
汇编·arm开发
询问QQ688238862 天前
探索多虚拟电厂联合调度优化模型:集中式算法的实践
汇编
草莓熊Lotso3 天前
C++11 核心特性实战:列表初始化 + 右值引用与移动语义(附完整代码)
java·服务器·开发语言·汇编·c++·人工智能·经验分享
西西弗Sisyphus3 天前
读第三方程序的变量的原理
汇编
西西弗Sisyphus3 天前
一个程序点击事件的汇编指令与解析 - 目标变量的真实虚拟地址 = 逐级解引用并叠加偏移后的结果
汇编
2501_918126914 天前
nes游戏语言是6502,有没有一种方法可以实现,开发另一种更高效的汇编语言,替代6052,并本土化,弯道超过nes的底层语言?
汇编·硬件工程·个人开发