You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by hd...@apache.org on 2013/03/08 14:58:40 UTC
svn commit: r1454390 - /openoffice/trunk/main/sal/osl/unx/interlck.c
Author: hdu
Date: Fri Mar 8 13:58:40 2013
New Revision: 1454390
URL: http://svn.apache.org/r1454390
Log:
avoid expensive pthread interlocking on clang
Clang handles the GCC inline assembler syntax just fine
Modified:
openoffice/trunk/main/sal/osl/unx/interlck.c
Modified: openoffice/trunk/main/sal/osl/unx/interlck.c
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/sal/osl/unx/interlck.c?rev=1454390&r1=1454389&r2=1454390&view=diff
==============================================================================
--- openoffice/trunk/main/sal/osl/unx/interlck.c (original)
+++ openoffice/trunk/main/sal/osl/unx/interlck.c Fri Mar 8 13:58:40 2013
@@ -31,7 +31,7 @@
#error please use asm/interlck_sparc.s
#elif defined ( SOLARIS) && defined ( X86 )
#error please use asm/interlck_x86.s
-#elif defined ( GCC ) && ( defined ( X86 ) || defined ( X86_64 ) )
+#elif (defined(__GNUC__) || defined(__clang__)) && (defined(X86) || defined(X86_64))
/* That's possible on x86-64 too since oslInterlockedCount is a sal_Int32 */
extern int osl_isSingleCPU;
@@ -212,3 +212,4 @@ oslInterlockedCount SAL_CALL osl_decreme
}
#endif /* default */
+