meaning of "%U0%X0" in PowerPC in the GCC inline asm
2014-06-23 19:50
369 查看
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
http://gcc.gnu.org/onlinedocs/gcc/Machine-Constraints.html#Machine-Constraints
https://gcc.gnu.org/onlinedocs/gcc/Simple-Constraints.html#Simple-Constraints
__asm__ __volatile__("stw%U0%X0 %1,%0" : "=m"(v->counter) : "r"(i));
the
stwassembly 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
相关文章推荐
- 转载:GCC inline asm
- Laravel 出现"RuntimeException inEncrypter.php line 43: The only supported ciphers are AES-128-CBC and AES-256-CBC with the correct key lengths."问题的解决办法
- when execute the ASM "LOCK" prefix, are all the memory being locked or are the relevant area in the
- An Inline Function is As Fast As a Macro(《Using the GNU Compiler Collection (GCC)》)
- run "mysqld --verbose --help" to list mysqld startup options in the command line
- There are inconsistent line endings in the "XXX.cs" script
- inline javascript cannot have the string "</script>"
- SSISThe Address in the "To" line is malformed
- How to inline ASM in C (gcc)
- "不是所有工作区中的窗口无法打开"错误消息(Not all of the Windows in the workspace could be open)
- Server Error in '/' Application. Access to the Path Is Denied" error message appears
- Travel on the TranzAlpine Rail Line in New Zealand
- classical dialog in the movie "rachel's wedding "
- Solve the problem "Value was invalid" in .Net ICryptoTransform
- The " count " function in map (STL)
- gcc inline
- Extended Inline Assembly in GCC
- How to compile GCC-4.3.3 in the Linux?
- 打开一个VC工程提示"Not all of the windows in the workspace could be opened."
- the way to compart a long code line into parts in order to make the Horizontal scroll bar disappear in V.S' Text Editor