diff options
author | H.J. Lu <hongjiu.lu@intel.com> | 2009-01-28 03:38:41 +0000 |
---|---|---|
committer | H.J. Lu <hjl@gcc.gnu.org> | 2009-01-27 19:38:41 -0800 |
commit | 0c6390fae9478618548c4d4c64483b85ae9f28ac (patch) | |
tree | c28aea5a229761267ff4a52bd552f902c42784ee /gcc/doc | |
parent | bee6fa6d32b8a231cae2af0cf700456d827a507e (diff) | |
download | gcc-0c6390fae9478618548c4d4c64483b85ae9f28ac.zip gcc-0c6390fae9478618548c4d4c64483b85ae9f28ac.tar.gz gcc-0c6390fae9478618548c4d4c64483b85ae9f28ac.tar.bz2 |
re PR target/38941 (CX isn't preserved with shift)
2009-01-27 H.J. Lu <hongjiu.lu@intel.com>
PR target/38941
* doc/extend.texi: Improve local variable with asm reg.
From-SVN: r143719
Diffstat (limited to 'gcc/doc')
-rw-r--r-- | gcc/doc/extend.texi | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi index 79a8c2e..c2c1381 100644 --- a/gcc/doc/extend.texi +++ b/gcc/doc/extend.texi @@ -4852,6 +4852,8 @@ asm ("sysint" : "=r" (result) : "0" (p1), "r" (p2)); In the above example, beware that a register that is call-clobbered by the target ABI will be overwritten by any function call in the assignment, including library calls for arithmetic operators. +Also a register may be clobbered when generating some operations, +like variable shift, memory copy or memory move on x86. Assuming it is a call-clobbered register, this may happen to @code{r0} above by the assignment to @code{p2}. If you have to use such a register, use temporary variables for expressions between the register |