Small cleanup of unused code in sp_search
authorJoona Kiiski <joona.kiiski@gmail.com>
Sun, 17 Jan 2010 13:05:28 +0000 (15:05 +0200)
committerMarco Costalba <mcostalba@gmail.com>
Sun, 17 Jan 2010 13:21:14 +0000 (14:21 +0100)
futilityValue is now calculated immediately after
staticValue, so remove small bunch of unused code

No functional change

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
src/search.cpp

index c7d8d792fee4bb231a559e506ba501c7410c2177..64cdf1c4e5fac5f27d679e7ed4c2ad865c961a19 100644 (file)
@@ -1817,7 +1817,6 @@ namespace {
                               && !isCheck;
 
     const int FutilityMoveCountMargin = 3 + (1 << (3 * int(sp->depth) / 8));
-    const int FutilityValueMargin = 112 * bitScanReverse32(int(sp->depth) * int(sp->depth) / 2);
 
     while (    sp->bestValue < sp->beta
            && !thread_should_stop(threadID)
@@ -1851,12 +1850,6 @@ namespace {
               continue;
 
           // Value based pruning
-          if (sp->futilityValue == VALUE_NONE)
-          {
-              EvalInfo ei;
-              sp->futilityValue = evaluate(pos, ei, threadID) + FutilityValueMargin;
-          }
-
           Value futilityValueScaled = sp->futilityValue - moveCount * IncrementalFutilityMargin;
 
           if (futilityValueScaled < sp->beta)