/*
Stockfish, a UCI chess playing engine derived from Glaurung 2.1
Copyright (C) 2004-2008 Tord Romstad (Glaurung author)
- Copyright (C) 2008-2009 Marco Costalba
+ Copyright (C) 2008-2010 Marco Costalba, Joona Kiiski, Tord Romstad
Stockfish is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
{
TM.set_active_threads(newActiveThreads);
init_eval(TM.active_threads());
- // HACK: init_eval() destroys the static castleRightsMask[] array in the
- // Position class. The below line repairs the damage.
- Position p(pos.to_fen());
- assert(pos.is_ok());
}
// Wake up sleeping threads
print_pv_info(pos, ss, alpha, beta, value);
// Prepare for a research after a fail high, each time with a wider window
- researchCountFH++;
*betaPtr = beta = Min(beta + AspirationDelta * (1 << researchCountFH), VALUE_INFINITE);
+ researchCountFH++;
} // End of fail high loop
break;
// Prepare for a research after a fail low, each time with a wider window
- researchCountFL++;
*alphaPtr = alpha = Max(alpha - AspirationDelta * (1 << researchCountFL), -VALUE_INFINITE);
+ researchCountFL++;
} // Fail low loop