summaryrefslogtreecommitdiff
path: root/src/root.c
diff options
context:
space:
mode:
authorScott Gasch <[email protected]>2026-10-05 13:05:34 -0700
committerScott Gasch <[email protected]>2026-10-05 13:05:34 -0700
commitbb7cdcda4c8c30ad0ed71d0f60427daf05977b24 (patch)
tree99a5a3f9fa6edcced73d966df0af07274ff67962 /src/root.c
parent5d9a5cf4036d07252e81d51e78e6dd36e65c9275 (diff)
New telemetry.
Diffstat (limited to 'src/root.c')
-rw-r--r--src/root.c44
1 files changed, 44 insertions, 0 deletions
diff --git a/src/root.c b/src/root.c
index bc6e3be..f9949a9 100644
--- a/src/root.c
+++ b/src/root.c
@@ -469,6 +469,45 @@ Return value:
Trace("Null move cutoff rate: %5.3f percent.\n",
((n / d) * 100.0));
#ifdef PERF_COUNTERS
+ Trace("Overt move skips: LMP=%llu EFP=%llu moves.\n",
+ ctx->sCounters.tree.u64LMPPruned,
+ ctx->sCounters.tree.u64EFPPruned);
+ {
+ ULONG uR;
+ UINT64 u64TotalTries = 0;
+ for (uR = 0; uR < NULL_R_BUCKETS; uR++)
+ {
+ u64TotalTries += ctx->sCounters.tree.u64NullMoveTriesByR[uR];
+ }
+ u64TotalTries += (0 == u64TotalTries); // avoid /0 if never tried
+ Trace("Null move (R): tries/successes, successes%% of ALL null-move "
+ "tries (sums to the overall cutoff rate above):\n");
+ for (uR = 0; uR < NULL_R_BUCKETS; uR++)
+ {
+ UINT64 u64Tries = ctx->sCounters.tree.u64NullMoveTriesByR[uR];
+ if (0 == u64Tries) continue;
+ Trace(" %u/%" COMPILER_LONGLONG_UNSIGNED_FORMAT
+ "/%" COMPILER_LONGLONG_UNSIGNED_FORMAT
+ "(%.1f%%)",
+ uR, u64Tries,
+ ctx->sCounters.tree.u64NullMoveSuccessByR[uR],
+ 100.0 * (double)ctx->sCounters.tree.u64NullMoveSuccessByR[uR] /
+ (double)u64TotalTries);
+ }
+ Trace("\n");
+ }
+ {
+ ULONG uTier;
+ Trace("LMR reductions (plies):");
+ for (uTier = 0; uTier < JOINT_EXTRA_TIER_COUNT; uTier++)
+ {
+ UINT64 u64Tries = ctx->sCounters.tree.u64JointExtraTries[uTier];
+ if (0 == u64Tries) continue;
+ Trace(" %u/%" COMPILER_LONGLONG_UNSIGNED_FORMAT,
+ uTier + 1, u64Tries);
+ }
+ Trace("\n");
+ }
// 2026-10-03: percentages added, each against the count of nodes of
// THAT TYPE (u64NodeTypeCount, incremented in CommonSearchInit),
// not against total nodes -- dividing by total nodes understates
@@ -1629,6 +1668,11 @@ Return value:
memcpy(g_Options.u64JointExtraResearch, ctx->sCounters.tree.u64JointExtraResearch,
sizeof(g_Options.u64JointExtraResearch));
g_Options.u64LMPPruned = ctx->sCounters.tree.u64LMPPruned;
+ g_Options.u64EFPPruned = ctx->sCounters.tree.u64EFPPruned;
+ memcpy(g_Options.u64NullMoveTriesByR, ctx->sCounters.tree.u64NullMoveTriesByR,
+ sizeof(g_Options.u64NullMoveTriesByR));
+ memcpy(g_Options.u64NullMoveSuccessByR, ctx->sCounters.tree.u64NullMoveSuccessByR,
+ sizeof(g_Options.u64NullMoveSuccessByR));
#ifdef PRUNE_VERIFY
memcpy(g_Options.u64PruneVerifyTries, ctx->sCounters.tree.u64PruneVerifyTries,
sizeof(g_Options.u64PruneVerifyTries));