Retire per-thread stopRequest flag

This is a per split-point request, not per-thread. When we find
a beta cut-off in current thread's split point or in or in some
ancestor of the current split point then threads should stop
immediately the search and return to idle_loop().

The check is done by thread_should_stop() that now looks only
at split point's chain.

No functional change and a good semplification.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
Marco Costalba
2010-02-20 17:52:09 +01:00
parent b39a24ecca
commit 2da290d72b
2 changed files with 12 additions and 55 deletions

View File

@@ -61,7 +61,7 @@ struct SplitPoint {
MovePicker *mp;
volatile int moves;
volatile int cpus;
bool finished;
volatile bool stopRequest;
};
// ThreadState type is used to represent thread's current state
@@ -81,7 +81,6 @@ struct Thread {
volatile int activeSplitPoints;
uint64_t nodes;
uint64_t betaCutOffs[2];
volatile bool stopRequest;
volatile bool printCurrentLineRequest;
volatile ThreadState state;
unsigned char pad[64]; // set some distance among local data for each thread