Do not copy master position in split()

A pointer is enough because after a split point has been
setup master and slaves thread end up calling sp_search() or
sp_search_pv() and here a full copy of split point position is
done again, note that even master does another copy (of itself)
and this is done before any do_move() call so that master Position
is never updated between split() and sp_search().

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
Marco Costalba
2010-01-25 12:44:30 +01:00
parent c2df60048e
commit 0ff91e16da
4 changed files with 8 additions and 13 deletions

View File

@@ -46,7 +46,7 @@ const int ACTIVE_SPLIT_POINTS_MAX = 8;
struct SplitPoint {
SplitPoint *parent;
Position pos;
const Position* pos;
SearchStack sstack[THREAD_MAX][PLY_MAX_PLUS_2];
SearchStack *parentSstack;
int ply;