From 030a848c5f5b8778f654008378d95f865322ef1e Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Thu, 26 Nov 2009 18:21:21 +0000 Subject: [PATCH] Fix SPARC asm operand failure. Refs #3678. Refs #3341. [SVN r57949] --- .../boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp b/include/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp index 8af6f0a..21fa59d 100644 --- a/include/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp +++ b/include/boost/smart_ptr/detail/sp_counted_base_gcc_sparc.hpp @@ -30,9 +30,9 @@ namespace detail inline int32_t compare_and_swap( int32_t * dest_, int32_t compare_, int32_t swap_ ) { - __asm__ __volatile__( "cas %0, %2, %1" - : "+m" (*dest_), "+r" (swap_) - : "r" (compare_) + __asm__ __volatile__( "cas [%1], %2, %0" + : "+r" (swap_) + : "r" (dest_), "r" (compare_) : "memory" ); return swap_;