projects
/
stockfish
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
877b468
)
Fix a warning with __popcnt64() intrinsics
author
Marco Costalba
<mcostalba@gmail.com>
Sat, 15 Jan 2011 11:05:31 +0000
(12:05 +0100)
committer
Marco Costalba
<mcostalba@gmail.com>
Sat, 15 Jan 2011 11:05:31 +0000
(12:05 +0100)
Returns an int64_t while we want a simple int.
This occurs only when compiling with MSVC on a 64 bit platform.
No functional change.
Signed-off-by: Marco Costalba <mcostalba@gmail.com>
src/bitcount.h
patch
|
blob
|
history
diff --git
a/src/bitcount.h
b/src/bitcount.h
index
3c5ba2a
..
940dbaf
100644
(file)
--- a/
src/bitcount.h
+++ b/
src/bitcount.h
@@
-88,7
+88,7
@@
inline int count_1s<CNT_POPCNT>(Bitboard b) {
#elif defined(_MSC_VER) && defined(__INTEL_COMPILER)
return _mm_popcnt_u64(b);
#elif defined(_MSC_VER)
- return __popcnt64(b);
+ return
(int)
__popcnt64(b);
#elif defined(__GNUC__)
unsigned long ret;
__asm__("popcnt %1, %0" : "=r" (ret) : "r" (b));