-
-
Save rubidium42/968b839363e98e6d5a11843b59896c28 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/openttd.cpp b/src/openttd.cpp | |
index 31db6b0d6..9320ed4b1 100644 | |
--- a/src/openttd.cpp | |
+++ b/src/openttd.cpp | |
@@ -517,6 +517,16 @@ static const OptionData _options[] = { | |
*/ | |
int openttd_main(int argc, char *argv[]) | |
{ | |
+ for (int i = 0; i < 32; i++) { | |
+ std::chrono::high_resolution_clock::time_point chrono_start = std::chrono::high_resolution_clock::now(); | |
+ std::chrono::high_resolution_clock::time_point next; | |
+ do { | |
+ next = std::chrono::high_resolution_clock::now(); | |
+ } while (chrono_start == next); | |
+ | |
+ fmt::println("chrono resolution: {}", std::chrono::duration_cast<std::chrono::nanoseconds>(next - chrono_start).count()); | |
+ } | |
+ | |
std::string musicdriver; | |
std::string sounddriver; | |
std::string videodriver; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment