Initialize a new split point out of lock

Allocate and initialize a new split point
out of lock becuase modified data is local to
master thread only.

Also better document why we need a lock at
the end of split().

No functional change with faked split.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
Marco Costalba
2011-08-06 19:11:35 +01:00
parent cd27ed9a74
commit 9a542d9698
3 changed files with 34 additions and 32 deletions

View File

@@ -119,7 +119,7 @@ public:
Depth depth, Move threatMove, int moveCount, MovePicker* mp, int nodeType);
private:
Thread threads[MAX_THREADS];
Lock mpLock;
Lock threadsLock;
Depth minimumSplitDepth;
int maxThreadsPerSplitPoint;
int activeThreads;