Change from [Color][PieceType] to [Piece]

Speed up of almost 1% in both normal and
pgo builds.

No functional change.
This commit is contained in:
syzygy
2016-09-03 18:14:01 +02:00
committed by Marco Costalba
parent c5828c4eba
commit ca6c9f85a5
6 changed files with 124 additions and 119 deletions

View File

@@ -650,7 +650,7 @@ namespace {
}
// Extra penalty for a quiet TT move in previous ply when it gets refuted
if ((ss-1)->moveCount == 1 && !pos.captured_piece_type())
if ((ss-1)->moveCount == 1 && !pos.captured_piece())
{
Value penalty = Value(d * d + 4 * d + 1);
Square prevSq = to_sq((ss-1)->currentMove);
@@ -1138,7 +1138,7 @@ moves_loop: // When in check search starts from here
}
// Extra penalty for a quiet TT move in previous ply when it gets refuted
if ((ss-1)->moveCount == 1 && !pos.captured_piece_type())
if ((ss-1)->moveCount == 1 && !pos.captured_piece())
{
Value penalty = Value(d * d + 4 * d + 1);
Square prevSq = to_sq((ss-1)->currentMove);
@@ -1147,7 +1147,7 @@ moves_loop: // When in check search starts from here
}
// Bonus for prior countermove that caused the fail low
else if ( depth >= 3 * ONE_PLY
&& !pos.captured_piece_type()
&& !pos.captured_piece()
&& is_ok((ss-1)->currentMove))
{
int d = depth / ONE_PLY;