From 3fc2aa73ad5f77b2443bf87909fe26c5710f83f3 Mon Sep 17 00:00:00 2001 From: Karma Riuk Date: Mon, 3 Feb 2025 01:06:07 +0100 Subject: [PATCH] actually counting milliseconds now --- cpp/src/stickfosh.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cpp/src/stickfosh.cpp b/cpp/src/stickfosh.cpp index f15ede7..615d41d 100644 --- a/cpp/src/stickfosh.cpp +++ b/cpp/src/stickfosh.cpp @@ -61,7 +61,9 @@ void perft(std::string pos) { auto start = std::chrono::steady_clock::now(); int moves = move_generation_test(b, depth, depth); auto end = std::chrono::steady_clock::now(); - auto elapsed = (end - start).count(); + auto elapsed = + std::chrono::duration_cast(end - start) + .count(); std::cout << "Results: " << moves << " "; if (moves == expected_n_moves)