diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-07-14 14:28:33 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-07-14 14:28:33 +0000 |
commit | 240f3056aa0e095a6b03d5763c2775e97b4ee7d3 (patch) | |
tree | 071e9f61ebc458a88ecc09f9ce0deb3940929a0c /internal.h | |
parent | b0eacd027a5f45c0135c7fa294bacb8162ae46b9 (diff) | |
download | ruby-240f3056aa0e095a6b03d5763c2775e97b4ee7d3.tar.gz |
* configure.in: Check __builtin_popcountl, __builtin_bswap32 and
__builtin_bswap64.
* internal.h (swap32): Use the configure result for the condition to
use __builtin_bswap32.
(swap64): Use the configure result for the condition to use
__builtin_bswap64.
* bignum.c (ones): Use the configure result for the condition to use
__builtin_popcountl.
(bary_unpack_internal): Use appropriate types for swap argument.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41963 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'internal.h')
-rw-r--r-- | internal.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/internal.h b/internal.h index f3ecf8be9f..a8243a793f 100644 --- a/internal.h +++ b/internal.h @@ -82,7 +82,7 @@ extern "C" { #endif #ifndef swap32 -# if GCC_VERSION_SINCE(4,3,0) +# ifdef HAVE_BUILTIN___BUILTIN_BSWAP32 # define swap32(x) __builtin_bswap32(x) # endif #endif @@ -95,7 +95,7 @@ extern "C" { #endif #ifndef swap64 -# if GCC_VERSION_SINCE(4,3,0) +# ifdef HAVE_BUILTIN___BUILTIN_BSWAP64 # define swap64(x) __builtin_bswap64(x) # endif #endif |