Skip to content

Commit

Permalink
break if hitting depth 0 after lmr, 12.66 +/- 8.04
Browse files Browse the repository at this point in the history
  • Loading branch information
tsoj committed Jun 7, 2024
1 parent 5281d7d commit 5bf3a1e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/search.nim
Original file line number Diff line number Diff line change
Expand Up @@ -137,12 +137,15 @@ func search(
newDepth = lmrDepth(newDepth, lmrMoveCounter)
lmrMoveCounter += 1

if newDepth <= 0:
break

# futility reduction
if moveCounter >= minMoveCounterFutility() and newDepth > 0:
newDepth -= futilityReduction(alpha + state.doEval(newPosition))

if newDepth <= 0:
continue
if newDepth <= 0:
continue

# first explore with null window
if hashResult.isEmpty or hashResult.bestMove != move or
Expand Down

0 comments on commit 5bf3a1e

Please sign in to comment.