首页 > 代码库 > meaning of "%U0%X0" in PowerPC in the GCC inline asm
meaning of "%U0%X0" in PowerPC in the GCC inline asm
There are idiosyncrasies in the GCC inline assembly syntax.in the line,
__asm__ __volatile__("stw%U0%X0 %1,%0" : "=m"(v->counter) : "r"(i));
the stw
assembly instruction takes 2 arguments and the %U0%X0 are constraints on the arguments. These constraints are to force GCC to analyze the arguments and make sure you dont do something stupid. As it turns out, ‘U‘ is powerpc-specific. The full list of constraints can be found in :
http://gcc.gnu.org/onlinedocs/gcc/Machine-Constraints.html#Machine-Constraints
https://gcc.gnu.org/onlinedocs/gcc/Simple-Constraints.html#Simple-Constraints
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。