mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-21 01:27:16 +08:00
Fix a warning with POPCNT and MSVC
Intrinsic __popcnt64() returns an unsigned __int64, cast to an integer and silence the warning. No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
@@ -51,7 +51,7 @@ inline bool cpu_has_popcnt() {
|
|||||||
return (CPUInfo[2] >> 23) & 1;
|
return (CPUInfo[2] >> 23) & 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
#define POPCNT_INTRINSIC(x) __popcnt64(x)
|
#define POPCNT_INTRINSIC(x) (int)__popcnt64(x)
|
||||||
|
|
||||||
#elif defined(__GNUC__) && defined(USE_POPCNT) // Gcc compiler
|
#elif defined(__GNUC__) && defined(USE_POPCNT) // Gcc compiler
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user