From: Marco Costalba Date: Mon, 25 May 2009 06:52:59 +0000 (+0100) Subject: Merge hardware POPCNT detection and use X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=3d0b60b0653852198011306a4c8d34f8ef98fc5e;hp=-c Merge hardware POPCNT detection and use Tests on Joona luxury iCore7 QUAD show that speed increase against standrd 64bit routine is between 3% and 4%. So it seems a good thing to have. Also the user feedback at startup regarding the compile and the hardware detection can be an useful debug tool. No functional change. Signed-off-by: Marco Costalba --- 3d0b60b0653852198011306a4c8d34f8ef98fc5e diff --combined src/movegen.cpp index 3845cd97,1135c219..995f54f0 --- a/src/movegen.cpp +++ b/src/movegen.cpp @@@ -24,6 -24,7 +24,7 @@@ #include + #include "bitcount.h" #include "movegen.h" // Simple macro to wrap a very common while loop, no facny, no flexibility, @@@ -392,6 -393,7 +393,6 @@@ bool move_is_legal(const Position& pos assert(pinned == pos.pinned_pieces(pos.side_to_move())); Color us = pos.side_to_move(); - Color them = opposite_color(us); Square from = move_from(m); Piece pc = pos.piece_on(from); @@@ -400,7 -402,6 +401,7 @@@ if (color_of_piece(pc) != us) return false; + Color them = opposite_color(us); Square to = move_to(m); // En passant moves