* Switched to using '__builtin_popcount' for counting bits in bitfield.

git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1292 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2011-10-02 15:57:22 +00:00
parent 5f21e207c3
commit 0784d6540f
2 changed files with 35 additions and 0 deletions
+15
View File
@@ -181,6 +181,21 @@ AC_DEFUN([TORRENT_CHECK_MADVISE], [
])
])
AC_DEFUN([TORRENT_CHECK_POPCOUNT], [
AC_MSG_CHECKING(for __builtin_popcount)
AC_COMPILE_IFELSE(
[[
void f() { __builtin_popcount(0); }
]],
[
AC_MSG_RESULT(yes)
AC_DEFINE(USE_BUILTIN_POPCOUNT, 1, Use __builtin_popcount.)
], [
AC_MSG_RESULT(no)
])
])
AC_DEFUN([TORRENT_CHECK_CACHELINE], [
AC_MSG_CHECKING(for cacheline)